@@ -3,28 +3,67 @@ title: Cryptography
33weight : 7
44---
55
6- The Pactus blockchain employs various advanced cryptographic algorithms, including hashing and signature schemes,
7- to protect user data and transactions.
6+ The Pactus blockchain uses various cryptographic algorithms, including hashing and digital signature schemes,
7+ to protect user data and secure transactions.
88
99## Hashing Algorithm
1010
11- Pactus uses a hashing algorithm called [ Blake2b] ( https://www.blake2.net/ ) .
12- This algorithm is known for being a fast and secure way of creating unique digital fingerprints of data.
11+ Pactus uses the [ Blake2b] ( https://www.blake2.net/ ) hashing algorithm .
12+ Blake2b is a fast and secure cryptographic hash function that produces unique digital fingerprints of data.
1313
14- ## Digital Signature
14+ ## Signature Schemes
1515
16- To ensure secure transactions, Pactus uses a signature scheme called
17- [ BLS] ( https://datatracker.ietf.org/doc/draft-irtf-cfrg-bls-signature/ ) (Boneh–Lynn–Shacham)
18- threshold signature for cryptographic signing and verification.
16+ Pactus supports several signature schemes for different purposes.
1917
20- ### Signature Aggregation
18+ ### BLS Signatures
2119
22- One of the advantages of BLS signatures is signature aggregation. BLS individual signatures can be
23- combined into one single aggregated signature, so that the overall size does not grow beyond one
24- signature.
20+ [ BLS] ( https://datatracker.ietf.org/doc/draft-irtf-cfrg-bls-signature/ ) (Boneh–Lynn–Shacham) is the primary signature scheme
21+ used by validators and BLS-based accounts.
22+ BLS is a threshold signature scheme with two notable properties:
2523
26- ### Non-Malleability
24+ #### Signature Aggregation
2725
28- BLS signatures have an important property called non-malleability,
29- which means that it is impossible to generate two valid signatures for the same message.
30- In other words, each message has a unique signature, and signatures cannot be altered without invalidating the signature.
26+ BLS signatures can be aggregated — multiple individual signatures can be combined into a single signature
27+ without increasing the overall size. This is useful for consensus where many validators sign the same message.
28+
29+ #### Non-Malleability
30+
31+ BLS signatures are non-malleable: it is impossible to produce two different valid signatures for the same message.
32+ Each message has exactly one valid signature.
33+
34+ ### Ed25519 Signatures
35+
36+ [ Ed25519] ( https://www.rfc-editor.org/rfc/rfc8032.txt ) is supported for account addresses
37+ (see [ PIP-52] ( https://pips.pactus.org/PIPs/pip-52 ) ).
38+ Ed25519 provides strong security, compact keys, and fast performance.
39+ Ed25519 account addresses start with ` pc1r... ` .
40+
41+ ### secp256k1 Signatures
42+
43+ [ secp256k1] ( https://www.secg.org/sec2-v2.pdf ) (ECDSA) is supported for account addresses
44+ (see [ PIP-53] ( https://pips.pactus.org/PIPs/pip-53 ) ).
45+ This is the same curve used by Bitcoin, enabling compatibility with existing wallet tools.
46+ secp256k1 account addresses start with ` pc1y... ` .
47+
48+ ## Address Types
49+
50+ Addresses in Pactus include a type that indicates their intended usage
51+ (see [ PIP-8] ( https://pips.pactus.org/PIPs/pip-8 ) ):
52+
53+ | ** Type** | ** Usage** | ** Address Prefix** | ** Derivation Path** |
54+ | -------- | ----------------- | ------------------ | ------------------------------- |
55+ | 1 | Validator | ` pc1p... ` | ` m/12381'/21888'/1'/index ` |
56+ | 2 | BLS Account | ` pc1z... ` | ` m/12381'/21888'/2'/index ` |
57+ | 3 | Ed25519 Account | ` pc1r... ` | ` m/44'/21888'/3'/index' ` |
58+ | 4 | secp256k1 Account | ` pc1y... ` | ` m/44'/21888'/4'/index' ` |
59+
60+ ## HD Key Derivation
61+
62+ Pactus supports Hierarchical Deterministic (HD) key derivation for wallets.
63+ This allows a single master seed to generate a tree of keys in a predictable way.
64+
65+ BLS HD derivation follows [ PIP-11] ( https://pips.pactus.org/PIPs/pip-11 ) ,
66+ which defines a standard for BLS12-381 HD key chains based on
67+ [ BIP-0032] ( https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki ) .
68+ Ed25519 and secp256k1 HD derivation follow
69+ [ SLIP-10] ( https://github.com/satoshilabs/slips/blob/master/slip-0010.md ) .
0 commit comments