Skip to content

Commit 59ff472

Browse files
cuishuanggopherbot
authored andcommitted
all: fix some comments
Change-Id: I11030ee466c8cac6855ce4fe2cf72e0b8d7029f8 Reviewed-on: https://go-review.googlesource.com/c/crypto/+/463796 Auto-Submit: Ian Lance Taylor <[email protected]> Reviewed-by: Michael Knyszek <[email protected]> Run-TryBot: Ian Lance Taylor <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]>
1 parent 3d872d0 commit 59ff472

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

acme/rfc8555.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ func (c *Client) updateRegRFC(ctx context.Context, a *Account) (*Account, error)
117117
return responseAccount(res)
118118
}
119119

120-
// getGegRFC is equivalent to c.GetReg but for CAs implementing RFC 8555.
120+
// getRegRFC is equivalent to c.GetReg but for CAs implementing RFC 8555.
121121
// It expects c.Discover to have already been called.
122122
func (c *Client) getRegRFC(ctx context.Context) (*Account, error) {
123123
req := json.RawMessage(`{"onlyReturnExisting": true}`)

cryptobyte/asn1.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,7 @@ func (s *String) ReadASN1BitString(out *encoding_asn1.BitString) bool {
559559
return true
560560
}
561561

562-
// ReadASN1BitString decodes an ASN.1 BIT STRING into out and advances. It is
562+
// ReadASN1BitStringAsBytes decodes an ASN.1 BIT STRING into out and advances. It is
563563
// an error if the BIT STRING is not a whole number of bytes. It reports
564564
// whether the read was successful.
565565
func (s *String) ReadASN1BitStringAsBytes(out *[]byte) bool {

curve25519/internal/field/fe_generic.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ func feSquareGeneric(v, a *Element) {
245245
v.carryPropagate()
246246
}
247247

248-
// carryPropagate brings the limbs below 52 bits by applying the reduction
248+
// carryPropagateGeneric brings the limbs below 52 bits by applying the reduction
249249
// identity (a * 2²⁵⁵ + b = a * 19 + b) to the l4 carry. TODO inline
250250
func (v *Element) carryPropagateGeneric() *Element {
251251
c0 := v.l0 >> 51

openpgp/keys.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ type Key struct {
6161
type KeyRing interface {
6262
// KeysById returns the set of keys that have the given key id.
6363
KeysById(id uint64) []Key
64-
// KeysByIdAndUsage returns the set of keys with the given id
64+
// KeysByIdUsage returns the set of keys with the given id
6565
// that also meet the key usage given by requiredUsage.
6666
// The requiredUsage is expressed as the bitwise-OR of
6767
// packet.KeyFlag* values.
@@ -183,7 +183,7 @@ func (el EntityList) KeysById(id uint64) (keys []Key) {
183183
return
184184
}
185185

186-
// KeysByIdAndUsage returns the set of keys with the given id that also meet
186+
// KeysByIdUsage returns the set of keys with the given id that also meet
187187
// the key usage given by requiredUsage. The requiredUsage is expressed as
188188
// the bitwise-OR of packet.KeyFlag* values.
189189
func (el EntityList) KeysByIdUsage(id uint64, requiredUsage byte) (keys []Key) {

ssh/knownhosts/knownhosts.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ func keyEq(a, b ssh.PublicKey) bool {
142142
return bytes.Equal(a.Marshal(), b.Marshal())
143143
}
144144

145-
// IsAuthorityForHost can be used as a callback in ssh.CertChecker
145+
// IsHostAuthority can be used as a callback in ssh.CertChecker
146146
func (db *hostKeyDB) IsHostAuthority(remote ssh.PublicKey, address string) bool {
147147
h, p, err := net.SplitHostPort(address)
148148
if err != nil {

0 commit comments

Comments
 (0)