Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data.X509.PrivateKey.PrivKey is not an instance of ASN1Object #55

Closed
derekelkins opened this issue Jun 26, 2015 · 3 comments
Closed

Data.X509.PrivateKey.PrivKey is not an instance of ASN1Object #55

derekelkins opened this issue Jun 26, 2015 · 3 comments

Comments

@derekelkins
Copy link
Contributor

In case there's another suggested way of doing it, my use-case is to produce in-memory RSA private keys in PEM format.

@aloiscochard
Copy link

I plan to tackle this one, I would love being able to generate RSA keys in .pem file in pure Haskell.

It seems to me that writing the dual of dsaFromASN1 and rsaFromASN1 should be enough to then declare ASN1 instances for PrivKey.

@duairc
Copy link

duairc commented Dec 14, 2017

I've written code that does this as part of an unrelated project here. If somebody wants to take that and make a pull request to upstream it that would be great. I know it's really something I should do myself, but it is what it is.

BTW, that project is licensed MPL-2.0, while this is BSD3. However if somebody wants to upstream the Data.X509.IO module, I'll license that module as BSD3 for that purpose.

chris-martin added a commit to chris-martin/hs-certificate that referenced this issue Apr 6, 2018
The original author of this code is Shane O'Brien <[email protected]>,
who has kindly offered to release it under a BSD3 license for our use
here.
haskell-tls#55 (comment)

I have merely copied this from
https://github.com/duairc/snaplet-saml/blob/dd89116f8f0b3d755d2feea73f2c40beb78c409c/src/Data/X509/IO.hs
with minor modifications.
chris-martin added a commit to chris-martin/hs-certificate that referenced this issue Apr 6, 2018
The original author of this code is Shane O'Brien <[email protected]>,
who has kindly offered to release it under a BSD3 license for our use
here.
haskell-tls#55 (comment)

I have merely copied this from
https://github.com/duairc/snaplet-saml/blob/dd89116f8f0b3d755d2feea73f2c40beb78c409c/src/Data/X509/IO.hs
with minor modifications.
chris-martin added a commit to chris-martin/hs-certificate that referenced this issue Apr 6, 2018
The original author of this code is Shane O'Brien <[email protected]>,
who has kindly offered to release it under a BSD3 license for our use
here.
haskell-tls#55 (comment)

I have merely copied this from
https://github.com/duairc/snaplet-saml/blob/dd89116f8f0b3d755d2feea73f2c40beb78c409c/src/Data/X509/IO.hs
with minor modifications.
@chris-martin
Copy link
Contributor

I've submitted #98 which pulls in @duairc's implementations of ASN1Object for PrivKey.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants