mrtnetwork / blockchain_utils

Comprehensive Crypto & Blockchain Toolkit: Pure Dart, Cross-Platform, Encoding, Cryptography, Addresses, Mnemonics, & More
BSD 3-Clause "New" or "Revised" License
18 stars 9 forks source link

Credits Issue #2

Closed justkawal closed 9 months ago

justkawal commented 9 months ago

It's awesome to see all important blockchain related functionalities at one place.

But it would also be awesome, if you could just give credits to the main repo's where you have copied/pulled the codes from. They do the hard work to code, migrate, test and port from different languages and make it available in dart.

It's just about showing appreciation in open source community. I hope you take it as a friendly advice.

Thanks.

mrtnetwork commented 9 months ago

It's awesome to see all important blockchain related functionalities at one place.

But it would also be awesome, if you could just give credits to the main repo's where you have copied/pulled the codes from. They do the hard work to code, migrate, test and port from different languages and make it available in dart.

It's just about showing appreciation in open source community. I hope you take it as a friendly advice.

Thanks.

Thank you for sharing your thoughts.

I've developed this product by merging two Python-based products and have made an effort to include copyright notices in most files. If there's a specific file that requires additional copyright information, please inform me, and I'll promptly add the necessary text. On the homepage, I'm currently working on incorporating acknowledgment for these products. And finally, I have not used any Dart products for this product

Once again, I appreciate your feedback.

justkawal commented 9 months ago

Oh, Awesome acknowledgement sounds good. I hope you take it as a healthy discussion haha...

https://github.com/mrtnetwork/blockchain_utils/blob/main/lib/crypto/crypto/schnorrkel/strobe/strobe.dart nearly matches with: https://github.com/justkawal/strobe/blob/main/lib/src/strobe.dart

Also the sr25519 code too.

justkawal commented 9 months ago

Anyways.... we're all developers same as you trying to bring something good to community, in one way or another....

Haha... Loved your work here.... to bring all the imp code under one hood....

mrtnetwork commented 9 months ago

Oh, Awesome acknowledgement sounds good. I hope you take it as a healthy discussion haha...

https://github.com/mrtnetwork/blockchain_utils/blob/main/lib/crypto/crypto/schnorrkel/strobe/strobe.dart nearly matches with: https://github.com/justkawal/strobe/blob/main/lib/src/strobe.dart

Also the sr25519 code too.

this code seems to draw inspiration from Go and Schnorrkel (Rust). I noticed similarities between your code and these two packages; perhaps we share similar sources of inspiration :)

mrtnetwork commented 9 months ago

Anyways.... we're all developers same as you trying to bring something good to community, in one way or another....

Haha... Loved your work here.... to bring all the imp code under one hood....

Please take a moment to review the commit history; my code dates back to 4 months ago, while I observed that yours is from 2 months ago.

Feel free to download version 1.0.3 (released 4 months ago) of this package from the pub and verify the publication date for additional context.

justkawal commented 9 months ago

Anyways, Do you think you could help me out in one thing?

Does blockchain_utils support this at the moment?

I was trying to implement this: https://github.com/polkadot-js/wasm/blob/1f58821cd4739eaeaa5dfde9c89d92b0206f56cc/packages/wasm-crypto/src/rs/secp256k1.rs#L18


#[wasm_bindgen]
pub fn ext_secp_pub_expand(pubkey: &[u8]) -> Vec<u8> {
    match PublicKey::from_slice(&pubkey) {
        Ok(p) => p
            .serialize_uncompressed()
            .to_vec(),
        _ => panic!("Invalid pubkey provided.")
    }
}
`
justkawal commented 9 months ago

Something similar to uncompressing the PublicKey for secp256k1.

mrtnetwork commented 9 months ago

Something similar to uncompressing the PublicKey for secp256k1.

While I don't have the complete code in view, it appears to aim at validating the public key associated with the curve secp2561k, determining its truth value, and converting it to uncompressed format. The blockchain_utils tool can assist with this process.

ProjectiveECCPoint.fromBytes(curve: Curves.curveSecp256k1, data: " pub key bytes").toBytes(EncodeType.uncompressed);
justkawal commented 9 months ago

Will look into it rightaway, Thank aye...

justkawal commented 9 months ago

And for compressing?

mrtnetwork commented 9 months ago

And for compressing?

jus switch betweenEncodeType enum for other encoding types