wstrange / asn1lib

Dart ASN1 Encoder / Decoder
BSD 2-Clause "Simplified" License
30 stars 30 forks source link

Consider Migrating use of BigInteger to dart sdk BigInt #22

Closed wstrange closed 6 years ago

stevenroose commented 6 years ago

That would be great. I think I can do that if I find an hour somewhere. Will also try to see if the lib complies with strong mode and other Dart v2 stuffs. Even though the Dart v2 tooling still confuses me..

wstrange commented 6 years ago

I made a bunch of quick and dirty dart 2 fixes and bumped the version to 0.4.3. I didn't tackle any BigInt conversion.

There is one test that is failing in bigint_test.dart. I had to comment it out (see line 167) to get it to pass. If you have an hour or so to look at it that would be awesome.

stevenroose commented 6 years ago

FWIW, we would have the same issue as PointyCastle: https://github.com/dart-lang/sdk/issues/32803.

For PointyCastle, I implemented (very inefficient) placeholders for those two functions, hoping the Dart team implements them soon.

wstrange commented 6 years ago

I added those BigInt utility functions to asn1util, but didn't get any further than that. See branch https://github.com/wstrange/asn1lib/tree/bigint