neo3/neo_config/
constant.rs

1pub struct NeoConstants {}
2impl NeoConstants {
3	// Network Magic Numbers
4	pub const MAGIC_NUMBER_MAINNET: u32 = 860833102;
5	pub const MAGIC_NUMBER_TESTNET: u32 = 894710606;
6
7	// Accounts, Addresses, Keys
8	pub const MAX_PUBLIC_KEYS_PER_MULTI_SIG: u32 = 1024;
9	pub const HASH160_SIZE: u32 = 20;
10	pub const HASH256_SIZE: u32 = 32;
11	pub const PRIVATE_KEY_SIZE: u32 = 32;
12	pub const PUBLIC_KEY_SIZE_COMPRESSED: u32 = 33;
13	pub const SIGNATURE_SIZE: u32 = 64;
14	pub const VERIFICATION_SCRIPT_SIZE: u32 = 40;
15	pub const MAX_ITERATOR_ITEMS_DEFAULT: u32 = 100;
16
17	pub const MAX_SUBITEMS: u32 = 16;
18	pub const MAX_NESTING_DEPTH: u8 = 2;
19
20	// Transactions & Contracts
21	pub const CURRENT_TX_VERSION: u8 = 0;
22	pub const MAX_TRANSACTION_SIZE: u32 = 102400;
23	pub const MAX_TRANSACTION_ATTRIBUTES: u32 = 16;
24	pub const MAX_SIGNER_SUBITEMS: u32 = 16;
25	pub const MAX_MANIFEST_SIZE: u32 = 0xFFFF;
26
27	// pub const DEFAULT_SCRYPT_PARAMS: Params = Params::new(14, 8, 8, 32).unwrap();
28
29	pub const SEED_1: &'static str = "http://seed1.neo.org:10332";
30	pub const SEED_2: &'static str = "http://seed2.neo.org:10332";
31	pub const SEED_3: &'static str = "http://seed3.neo.org:10332";
32	pub const SEED_4: &'static str = "http://seed4.neo.org:10332";
33	pub const SEED_5: &'static str = "http://seed5.neo.org:10332";
34
35	pub const SCRYPT_N: usize = 16384;
36	pub const SCRYPT_R: u32 = 8;
37	pub const SCRYPT_P: u32 = 8;
38	pub const SCRYPT_LOG_N: u8 = 14;
39	pub const SCRYPT_DK_LEN: usize = 64;
40
41	pub const NEP_HEADER_1: u8 = 0x01;
42	pub const NEP_HEADER_2: u8 = 0x42;
43	pub const NEP_FLAG: u8 = 0xe0;
44
45	pub fn new() -> Self {
46		Self {}
47	}
48}