konstantinullrich / crypton

A simple Dart library for asymmetric encryption and digital signatures
https://pub.dev/packages/crypton
MIT License
33 stars 12 forks source link

Make a way to pull keypair from PEM files #5

Closed AKushWarrior closed 4 years ago

AKushWarrior commented 4 years ago

You should have a way to use external keypairs so people are not limited to auto-generation.

konstantinullrich commented 4 years ago

I'll see what I can do. Because I also want to support Web

AKushWarrior commented 4 years ago

The "File" class is still supported on web.

If this is easier, you can have users pass a PEM String (the result of reading a file) and use that.

If you want to piggyback some code (so to speak), the deprecated RsaCrypt class in steel_crypt has methods for this.

konstantinullrich commented 4 years ago

@AKushWarrior please take a look at my latest commit on this issues feature branch

AKushWarrior commented 4 years ago

Looks good to me. On mobile, so I can't run tests, but it should work.