bitcoinj / secp256k1-jdk

Java library providing Bitcoin-related Elliptic Curve Cryptography
Apache License 2.0
9 stars 3 forks source link

Remove dependency on JDK 17 HexFormat #85

Closed msgilligan closed 2 months ago

msgilligan commented 2 months ago

Add ByteArray, ByteUtils, and HexFormat classes to do it.

msgilligan commented 2 months ago

It's a bit unfortunate that this PR duplicates a couple of classes from base.internal. But I guess since it's internal, secp can't use it?

I think the duplication is ok, for now. But I envision the following strategy:

  1. Port secp-api and secp-bouncy the rest of the way back to JDK 8
  2. In the bitcoinj release that is refactored to use secp-api, have base depend on secp-api and remove the duplication then.
msgilligan commented 2 months ago

There are definitely a few things in here that need cleanup, but I'm going to merge and we can fix them later.