aboutsummaryrefslogtreecommitdiffstats
path: root/core/rawdb/schema.go
diff options
context:
space:
mode:
Diffstat (limited to 'core/rawdb/schema.go')
-rw-r--r--core/rawdb/schema.go12
1 files changed, 11 insertions, 1 deletions
diff --git a/core/rawdb/schema.go b/core/rawdb/schema.go
index 9a820a578..87a56c0ba 100644
--- a/core/rawdb/schema.go
+++ b/core/rawdb/schema.go
@@ -53,7 +53,9 @@ var (
txLookupPrefix = []byte("l") // txLookupPrefix + hash -> transaction/receipt lookup metadata
bloomBitsPrefix = []byte("B") // bloomBitsPrefix + bit (uint16 big endian) + section (uint64 big endian) + hash -> bloom bits
- coreBlockPrefix = []byte("D")
+ coreBlockPrefix = []byte("D")
+ coreDKGPrivateKeyPrefix = []byte("DPK")
+ coreCompactionChainTipKey = []byte("CoreChainTip")
preimagePrefix = []byte("secure-key-") // preimagePrefix + hash -> preimage
configPrefix = []byte("ethereum-config-") // config prefix for the db
@@ -120,6 +122,14 @@ func coreBlockKey(hash common.Hash) []byte {
return append(coreBlockPrefix, hash.Bytes()...)
}
+// coreDKGPrivateKeyKey = coreDKGPrivateKeyPrefix + round
+func coreDKGPrivateKeyKey(round uint64) []byte {
+ ret := make([]byte, len(coreDKGPrivateKeyPrefix)+8)
+ copy(ret, coreDKGPrivateKeyPrefix)
+ binary.LittleEndian.PutUint64(ret[len(coreDKGPrivateKeyPrefix):], round)
+ return ret
+}
+
// bloomBitsKey = bloomBitsPrefix + bit (uint16 big endian) + section (uint64 big endian) + hash
func bloomBitsKey(bit uint, section uint64, hash common.Hash) []byte {
key := append(append(bloomBitsPrefix, make([]byte, 10)...), hash.Bytes()...)