MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / parse

Function parse

modules/crypt/ssl/ssl_handshake.js:218–224  ·  view source on GitHub ↗
(s)

Source from the content-addressed store, hash-verified

216 helloProtocol: {
217 random: {
218 parse(s) {
219 let t = s.readChars(4);
220 return {
221 qmt_unix_time: t,
222 random_bytes: s.readChunk(28)
223 };
224 },
225 serialize() {
226 let qmt_unix_time = ((new Date()).getTime() / 1000) | 0; // in sec
227 let a = new Uint8Array(RNG.get(32));

Callers 2

DebugBehavior.jsFile · 0.50

Calls 2

readCharsMethod · 0.80
readChunkMethod · 0.80

Tested by

no test coverage detected