Skip to content

Commit

Permalink
chore: fix some function names in comment
Browse files Browse the repository at this point in the history
Signed-off-by: toofooboo <[email protected]>
  • Loading branch information
toofooboo authored and adecaro committed Dec 20, 2024
1 parent a681166 commit 9986ac6
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion platform/fabric/core/generic/msp/x509/ecdsa.go
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ func PemDecodeKey(keyBytes []byte) (interface{}, error) {
return key, nil
}

// IsLow checks that s is a low-S
// IsLowS checks that s is a low-S
func IsLowS(k *ecdsa.PublicKey, s *big.Int) (bool, error) {
halfOrder, ok := curveHalfOrders[k.Curve]
if !ok {
Expand Down
2 changes: 1 addition & 1 deletion platform/view/services/grpc/connection.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func (cs *CredentialSupport) SetClientCertificate(cert tls.Certificate) {
cs.mutex.Unlock()
}

// getClientCertificate returns the client certificate of the CredentialSupport
// GetClientCertificate returns the client certificate of the CredentialSupport
func (cs *CredentialSupport) GetClientCertificate() tls.Certificate {
cs.mutex.RLock()
defer cs.mutex.RUnlock()
Expand Down
2 changes: 1 addition & 1 deletion platform/view/services/grpc/creds.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func (t *TLSConfig) SetClientCAs(certPool *x509.CertPool) {
t.config.ClientCAs = certPool
}

// ClientHandShake is not implemented for `serverCreds`.
// ClientHandshake is not implemented for `serverCreds`.
func (sc *serverCreds) ClientHandshake(context.Context,
string, net.Conn) (net.Conn, credentials.AuthInfo, error) {
return nil, nil, ErrClientHandshakeNotImplemented
Expand Down
6 changes: 3 additions & 3 deletions platform/view/services/grpc/tlsgen/ca.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ type CA interface {
// CertBytes returns the certificate of the CA in PEM encoding
CertBytes() []byte

// newCertKeyPair returns a certificate and private key pair and nil,
// NewClientCertKeyPair returns a certificate and private key pair and nil,
// or nil, error in case of failure
// The certificate is signed by the CA and is used for TLS client authentication
NewClientCertKeyPair() (*CertKeyPair, error)
Expand Down Expand Up @@ -60,14 +60,14 @@ func (c *ca) CertBytes() []byte {
return c.caCert.Cert
}

// newClientCertKeyPair returns a certificate and private key pair and nil,
// NewClientCertKeyPair returns a certificate and private key pair and nil,
// or nil, error in case of failure
// The certificate is signed by the CA and is used as a client TLS certificate
func (c *ca) NewClientCertKeyPair() (*CertKeyPair, error) {
return newCertKeyPair(false, false, "", c.caCert.Signer, c.caCert.TLSCert)
}

// newServerCertKeyPair returns a certificate and private key pair and nil,
// NewServerCertKeyPair returns a certificate and private key pair and nil,
// or nil, error in case of failure
// The certificate is signed by the CA and is used as a server TLS certificate
func (c *ca) NewServerCertKeyPair(host string) (*CertKeyPair, error) {
Expand Down

0 comments on commit 9986ac6

Please sign in to comment.