Constants
This commit is contained in:
parent
632aa2245c
commit
f356a070cc
|
@ -26,15 +26,15 @@ API documentation is available [here](https://bitchan.github.io/bitmessage/docs/
|
|||
- [ ] AES-256-CBC
|
||||
- [ ] HMAC-SHA-256
|
||||
- [ ] Common structures
|
||||
- [ ] message
|
||||
- [x] message
|
||||
- [x] var_int
|
||||
- [x] var_str
|
||||
- [x] var_int_list
|
||||
- [ ] net_addr
|
||||
- [ ] inv_vect
|
||||
- [ ] encrypted
|
||||
- [ ] encoding
|
||||
- [ ] bitfield
|
||||
- [x] message encodings
|
||||
- [ ] service features
|
||||
- [ ] pubkey features
|
||||
- [ ] Message types
|
||||
- [ ] version
|
||||
- [ ] verack
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
require("object.assign").shim();
|
||||
var assert = require("assert");
|
||||
var bufferEqual = require("buffer-equal");
|
||||
var bmcrypto = require("./crypto");
|
||||
|
@ -249,3 +250,19 @@ exports.var_int_list = {
|
|||
return Buffer.concat([var_int.encode(list.length), listBuf]);
|
||||
},
|
||||
};
|
||||
|
||||
exports.messageEncodings = Object.create(var_int);
|
||||
Object.assign(exports.messageEncodings, {
|
||||
IGNORE: 0,
|
||||
TRIVIAL: 1,
|
||||
SIMPLE: 2,
|
||||
});
|
||||
|
||||
exports.serviceFeatures = {
|
||||
NODE_NETWORK: 1,
|
||||
};
|
||||
|
||||
exports.pubkeyFeatures = {
|
||||
INCLUDE_DESTINATION: 30,
|
||||
DOES_ACK: 31,
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue
Block a user