Hey! Did anyone tried to use <https://github.com/a...
# ios
p
Hey! Did anyone tried to use https://github.com/apple/swift-certificates inside KMP?
f
Hi, as a pure Swift library, it’s not possible to directly use from Kotlin. Use spmForKmp to implement it with a custom bridge.
🙌 1
o
Sorry for off top, but what is your use case for it in KMP context? :) Asking for https://github.com/whyoleg/cryptography-kotlin/issues/18 kodee floating
p
I tried to use cryptography-kotlin but as far i know I cannot create self signed certificate with it. Thanks why I am looking for native approach with apple framework or something else. I found this library but it's very hard to use. Documentation is not there but I am trying to use it right now. https://github.com/a-sit-plus/signum @François Thanks for that link. I will check it later. @Oleg Yukhnevich For the context. I am making library that will communicate with MQTT server and for that I need to generate self signer certificate. At least that is the requirement.
I am new to KMP so maybe I am doing something wrong 🙂
o
Cc @Bernd Prünster regarding Signum :)
Thanks! Good to know! Could you please add a comment with your use-case in the issue, so that I will keep it in mind? :)
p
Sure thing! I will do it right now 🙂
kodee loving 1
o
Nice, thanks!
b
@Patryk Drozd do file an issue, if documentation is lacking! (thanks @Oleg Yukhnevich for tagging me). There is sample code to create a CSR and sign it to get a certificate: https://a-sit-plus.github.io/signum/examples/#issuing-binding-certificates
kodee floating 1
While I am naturally biased as the PO of Signum, I feel parsing could not be easier: https://a-sit-plus.github.io/signum/#asn1-parsing-and-encoding. I do agree that creating a self-signed certificate is missing as one of the most basic examples!
p
Thanks @Bernd Prünster for your answer. I will check those links right away!