MCPcopy Create free account

hub / github.com/cloudflare/roughtime / functions

Functions80 in github.com/cloudflare/roughtime

↓ 17 callersFunctionmakeTag
makeTag converts a four character string into a Roughtime tag value.
protocol/protocol.go:47
↓ 13 callersFunctionParseRequest
ParseRequest resolves the supported versions indicated by the client and parses the values required to produce a response.
protocol/protocol.go:497
↓ 13 callersFunctionerrDecode
(info string)
protocol/error.go:61
↓ 12 callersFunctionCreateRequest
CreateRequest creates a Roughtime request given an entropy source and the contents of a previous reply for chaining. If this request is the first of a
protocol/protocol.go:308
↓ 12 callersMethodNow
Now returns the time provided by a Roughtime response.
client/client.go:173
↓ 12 callersMethodString
()
client/client.go:177
↓ 8 callersMethodError
()
protocol/error.go:39
↓ 8 callersFunctioncreateServerIdentity
(t *testing.T)
protocol/protocol_test.go:97
↓ 7 callersFunctionCreateReplies
CreateReplies signs, using privateKey, a batch of nonces along with the given time and radius. It returns one reply for each nonce using that signatur
protocol/protocol.go:563
↓ 7 callersFunctionVerifyReply
VerifyReply parses the Roughtime reply in replyBytes, authenticates it using publicKey and verifies that nonce is included in it. It returns the inclu
protocol/protocol.go:815
↓ 6 callersFunctionDecode
Decode parses the output of encode back into a map of tags to bytestrings.
protocol/protocol.go:144
↓ 6 callersFunctionEncode
Encode converts a map of tags to bytestrings into an encoded message. The number of elements in msg and the sum of the lengths of all the bytestrings
protocol/protocol.go:87
↓ 6 callersFunctiongetFixedLength
(msg map[uint32][]byte, tag uint32, name string, length int)
protocol/protocol.go:771
↓ 5 callersFunctionSetLogger
SetLogger sets the logger used to log the output of Do and DoFromFile. If l == nil, then no output will be logged.
client/client.go:52
↓ 4 callersFunctionLoadConfig
LoadConfig reads and parses a JSON-encoded string from configFile.
client/client.go:240
↓ 4 callersFunctionNewCertificate
NewCertificate returns a signed certificate, using rootPrivateKey, delegating authority for the given timestamp to onlinePrivateKey.
protocol/protocol.go:697
↓ 4 callersFunctionSelectCertificateForRequest
Select a certificate suitable for responding to the request.
protocol/protocol.go:676
↓ 4 callersMethodString
()
protocol/version.go:56
↓ 4 callersFunctiongetValue
(msg map[uint32][]byte, tag uint32, name string)
protocol/protocol.go:763
↓ 4 callersFunctionnonceSize
nonceSize returns the nonce length.
protocol/protocol.go:227
↓ 3 callersFunctionCalculateChainNonce
CalculateChainNonce fills the `nonce` buffer with the nonce used in the next request in a chain given a reply and a blinding factor. The length of the
protocol/protocol.go:237
↓ 3 callersMethodError
Error returns the error resulting from the query, if any.
client/client.go:262
↓ 3 callersFunctionMedianDeltaWithRadiusThresh
MedianDeltaWithRadiusThresh computes the median difference between t0 and the time reported by each server, rejecting responses whose uncertainty radi
client/client.go:306
↓ 3 callersFunctionResponseVersionFromSupported
ResponseVersionFromSupported selects a version to use from the list of versions supported by the clients. Returns an error if the input slice is zero-
protocol/version.go:101
↓ 3 callersFunctionadvertisedVersionsFromPreference
advertisedVersionsFromPreference derives the list of versions advertised in its request by a client with the given preferences. If len(versionPrefere
protocol/version.go:79
↓ 3 callersFunctiongetUint64
(msg map[uint32][]byte, tag uint32, name string)
protocol/protocol.go:790
↓ 3 callersFunctionhashNode
hashNode hashes two child elements of the Merkle tree to produce an interior node.
protocol/protocol.go:395
↓ 2 callersFunctionDo
Do requests Roughtime from a sequence of servers in order. If the request fails, then the error is recorded. The nonce of each request is computed fro
client/client.go:269
↓ 2 callersFunctionDoFromFile
DoFromFile loads a sequence of server configurations from configFile and requests Roughtime from them in order.
client/client.go:290
↓ 2 callersFunctionGet
Get sends a request to a server and verifies the response. It makes at most as many attempts as specified, waiting for the given amount of time for ea
client/client.go:97
↓ 2 callersMethodRead
(b []byte)
protocol/internal/testing/testing.go:46
↓ 2 callersMethodVerify
Verify returns true if the chain is valid. A chain is valid if for each link in the chain, (1) the signature in the server's response is valid, and (2
client/client.go:374
↓ 2 callersFunctiondecodeFramed
decodeFramed determines if the requester is a legacy client (Google-Roughtime) or supports the IETF version. In the later case, it removes the IETF me
protocol/protocol.go:266
↓ 2 callersFunctionencodeFramed
encodeFramed adds IETF message framing to a message.
protocol/protocol.go:251
↓ 2 callersFunctionerrUnsupportedVersion
(vers []Version)
protocol/error.go:68
↓ 2 callersFunctiongetUint32
(msg map[uint32][]byte, tag uint32, name string)
protocol/protocol.go:782
↓ 2 callersFunctiongetVersionPreferenceForServer
getVersionPreferenceForServer resolves the client's version preference based on the server's configuration.
client/client.go:67
↓ 2 callersFunctionhandleSRVTag
(advertisedPreference []Version)
protocol/protocol.go:293
↓ 2 callersFunctionhashLeaf
hashLeaf hashes an nonce to form the leaf of the Merkle tree.
protocol/protocol.go:386
↓ 2 callersFunctionserverUDPAddr
serverUDPAddr attempts to resolve the UDP address specified by the server configution.
client/client.go:227
↓ 1 callersMethodBytesForVersion
BytesForVersion returns a serialized certificate compatible with the given version. Legacy clients (Google-Roughtime) expect a non-standard encoding o
protocol/protocol.go:666
↓ 1 callersFunctionNewTestRand
NewTestRand returns an instance of TestRand.
protocol/internal/testing/testing.go:55
↓ 1 callersFunctionParseConfig
ParseConfig loads parses a JSON-encoded Roughtime-server configuration, skipping those servers that the client doesn't support. It returns the sequenc
client/client.go:190
↓ 1 callersMethodPath
Path returns elements from t needed to prove, given the root, that the leaf at the given index is in the tree.
protocol/protocol.go:467
↓ 1 callersMethodRoot
Root returns the root value of t.
protocol/protocol.go:456
↓ 1 callersFunctionensureDir
(dirName string)
protocol/internal/cmd/gen_test_vectors.go:67
↓ 1 callersFunctionfileNmameFor
(ver protocol.Version)
protocol/internal/cmd/gen_test_vectors.go:86
↓ 1 callersFunctiongetSubmessage
(msg map[uint32][]byte, tag uint32, name string)
protocol/protocol.go:798
↓ 1 callersFunctionhandleRequest
(requestBytes []byte, cert *protocol.Certificate, onlineSK ed25519.PrivateKey)
cmd/testserver/main.go:106
↓ 1 callersMethodisSupported
()
protocol/version.go:47
↓ 1 callersFunctionmessageOverhead
messageOverhead returns the number of bytes needed for Encode to encode the given number of tags.
protocol/protocol.go:218
↓ 1 callersFunctionnewTree
newTree creates a Merkle tree given one or more nonces.
protocol/protocol.go:404
FunctionFuzzParseRequest
(f *testing.F)
protocol/protocol_test.go:571
FunctionFuzzVerifyReply
(f *testing.F)
protocol/protocol_test.go:611
MethodLen
()
protocol/protocol.go:80
MethodLess
(i, j int)
protocol/protocol.go:81
MethodLevels
Levels returns the number of levels in t.
protocol/protocol.go:461
FunctionNewChain
NewChain returns a Roughtime chain comprised of the successful queries in a sequence of results.
client/client.go:353
MethodSwap
(i, j int)
protocol/protocol.go:82
FunctionTestChaining
(t *testing.T)
protocol/protocol_test.go:294
FunctionTestCreateReplyForIncorrectCertificate
(t *testing.T)
protocol/protocol_test.go:550
FunctionTestEmptyVersionPreference
Test that if no version preference is specified, then the client defaults to IETF-Roughtime.
protocol/protocol_test.go:432
FunctionTestEncodeDecode
(t *testing.T)
protocol/protocol_test.go:74
FunctionTestIETFTags
Test that tag constants match values in the tag registry (draft-ietf-ntp-roughtime-08, Section 12.3)
protocol/protocol_test.go:381
FunctionTestMain
(t *testing.T)
internal/ecosystem_json_go_builder/main_test.go:30
FunctionTestRequestSize
(t *testing.T)
protocol/protocol_test.go:82
FunctionTestRoundtrip
(t *testing.T)
protocol/protocol_test.go:221
FunctionTestRunTestVectors
(t *testing.T)
protocol/protocol_test.go:115
FunctionTestSelectCertificateForRequest
(t *testing.T)
protocol/protocol_test.go:453
FunctionTestServerIgnoresUnrecognizedVersions
(t *testing.T)
protocol/protocol_test.go:409
Functioninit
()
client/client.go:60
Functioninit
()
protocol/internal/cmd/gen_test_vectors.go:48
Functionmain
()
protocol/internal/cmd/gen_test_vectors.go:99
Functionmain
()
recipes/alerter.go:28
Functionmain
()
recipes/tls.go:20
Functionmain
()
internal/ecosystem_json_go_builder/main.go:35
Functionmain
()
cmd/testserver/main.go:35
Functionmain
()
cmd/keygen/keygen.go:12
Functionmain
()
cmd/getroughtime/main.go:36
FunctiontestEncodeDecodeRoundtrip
(msg map[uint32][]byte)
protocol/protocol_test.go:46