MCPcopy Create free account
hub / github.com/XTLS/Go / curveForCurveID

Function curveForCurveID

key_schedule.go:139–150  ·  view source on GitHub ↗
(id CurveID)

Source from the content-addressed store, hash-verified

137}
138
139func curveForCurveID(id CurveID) (elliptic.Curve, bool) {
140 switch id {
141 case CurveP256:
142 return elliptic.P256(), true
143 case CurveP384:
144 return elliptic.P384(), true
145 case CurveP521:
146 return elliptic.P521(), true
147 default:
148 return nil, false
149 }
150}
151
152type nistParameters struct {
153 privateKey []byte

Callers 8

makeClientHelloMethod · 0.85
processClientHelloMethod · 0.85
generateECDHEParametersFunction · 0.85
PublicKeyMethod · 0.85
SharedKeyMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…