all: fix typos

Change-Id: I62cbcfcd0be5f6a74d93b85b24ff7607533bb239
GitHub-Last-Rev: 9967869e706e9fe7d13964bb32b30a44ba640869
GitHub-Pull-Request: golang/crypto#64
Reviewed-on: https://go-review.googlesource.com/c/145240
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
Igor Zhilianin
2018-10-29 02:12:03 +00:00
committed by Brad Fitzpatrick
parent e84da03127
commit 45a5f77698
10 changed files with 10 additions and 10 deletions
+1 -1
View File
@@ -29,7 +29,7 @@ type XOF interface {
} }
// OutputLengthUnknown can be used as the size argument to NewXOF to indicate // OutputLengthUnknown can be used as the size argument to NewXOF to indicate
// the the length of the output is not known in advance. // the length of the output is not known in advance.
const OutputLengthUnknown = 0 const OutputLengthUnknown = 0
// magicUnknownOutputLength is a magic value for the output size that indicates // magicUnknownOutputLength is a magic value for the output size that indicates
+1 -1
View File
@@ -29,7 +29,7 @@ type XOF interface {
} }
// OutputLengthUnknown can be used as the size argument to NewXOF to indicate // OutputLengthUnknown can be used as the size argument to NewXOF to indicate
// the the length of the output is not known in advance. // the length of the output is not known in advance.
const OutputLengthUnknown = 0 const OutputLengthUnknown = 0
// magicUnknownOutputLength is a magic value for the output size that indicates // magicUnknownOutputLength is a magic value for the output size that indicates
+1 -1
View File
@@ -51,7 +51,7 @@ func NewFixedBuilder(buffer []byte) *Builder {
} }
// Bytes returns the bytes written by the builder or an error if one has // Bytes returns the bytes written by the builder or an error if one has
// occurred during during building. // occurred during building.
func (b *Builder) Bytes() ([]byte, error) { func (b *Builder) Bytes() ([]byte, error) {
if b.err != nil { if b.err != nil {
return nil, b.err return nil, b.err
+1 -1
View File
@@ -63,7 +63,7 @@ func (r ResponseStatus) String() string {
} }
// ResponseError is an error that may be returned by ParseResponse to indicate // ResponseError is an error that may be returned by ParseResponse to indicate
// that the response itself is an error, not just that its indicating that a // that the response itself is an error, not just that it's indicating that a
// certificate is revoked, unknown, etc. // certificate is revoked, unknown, etc.
type ResponseError struct { type ResponseError struct {
Status ResponseStatus Status ResponseStatus
+1 -1
View File
@@ -80,7 +80,7 @@ func (uat *UserAttribute) Serialize(w io.Writer) (err error) {
// ImageData returns zero or more byte slices, each containing // ImageData returns zero or more byte slices, each containing
// JPEG File Interchange Format (JFIF), for each photo in the // JPEG File Interchange Format (JFIF), for each photo in the
// the user attribute packet. // user attribute packet.
func (uat *UserAttribute) ImageData() (imageData [][]byte) { func (uat *UserAttribute) ImageData() (imageData [][]byte) {
for _, sp := range uat.Contents { for _, sp := range uat.Contents {
if sp.SubType == UserAttrImageSubpacket && len(sp.Contents) > 16 { if sp.SubType == UserAttrImageSubpacket && len(sp.Contents) > 16 {
+1 -1
View File
@@ -5,7 +5,7 @@
// Package ripemd160 implements the RIPEMD-160 hash algorithm. // Package ripemd160 implements the RIPEMD-160 hash algorithm.
package ripemd160 // import "golang.org/x/crypto/ripemd160" package ripemd160 // import "golang.org/x/crypto/ripemd160"
// RIPEMD-160 is designed by by Hans Dobbertin, Antoon Bosselaers, and Bart // RIPEMD-160 is designed by Hans Dobbertin, Antoon Bosselaers, and Bart
// Preneel with specifications available at: // Preneel with specifications available at:
// http://homes.esat.kuleuven.be/~cosicart/pdf/AB-9601/AB-9601.pdf. // http://homes.esat.kuleuven.be/~cosicart/pdf/AB-9601/AB-9601.pdf.
+1 -1
View File
@@ -29,7 +29,7 @@ func blockXOR(dst, src []uint32, n int) {
} }
// salsaXOR applies Salsa20/8 to the XOR of 16 numbers from tmp and in, // salsaXOR applies Salsa20/8 to the XOR of 16 numbers from tmp and in,
// and puts the result into both both tmp and out. // and puts the result into both tmp and out.
func salsaXOR(tmp *[16]uint32, in, out []uint32) { func salsaXOR(tmp *[16]uint32, in, out []uint32) {
w0 := tmp[0] ^ in[0] w0 := tmp[0] ^ in[0]
w1 := tmp[1] ^ in[1] w1 := tmp[1] ^ in[1]
+1 -1
View File
@@ -43,7 +43,7 @@
// is then "full" and the permutation is applied to "empty" it. This process is // is then "full" and the permutation is applied to "empty" it. This process is
// repeated until all the input has been "absorbed". The input is then padded. // repeated until all the input has been "absorbed". The input is then padded.
// The digest is "squeezed" from the sponge in the same way, except that output // The digest is "squeezed" from the sponge in the same way, except that output
// output is copied out instead of input being XORed in. // is copied out instead of input being XORed in.
// //
// A sponge is parameterized by its generic security strength, which is equal // A sponge is parameterized by its generic security strength, which is equal
// to half its capacity; capacity + rate is equal to the permutation's width. // to half its capacity; capacity + rate is equal to the permutation's width.
+1 -1
View File
@@ -185,7 +185,7 @@ func Dial(network, addr string, config *ClientConfig) (*Client, error) {
// keys. A HostKeyCallback must return nil if the host key is OK, or // keys. A HostKeyCallback must return nil if the host key is OK, or
// an error to reject it. It receives the hostname as passed to Dial // an error to reject it. It receives the hostname as passed to Dial
// or NewClientConn. The remote address is the RemoteAddr of the // or NewClientConn. The remote address is the RemoteAddr of the
// net.Conn underlying the the SSH connection. // net.Conn underlying the SSH connection.
type HostKeyCallback func(hostname string, remote net.Addr, key PublicKey) error type HostKeyCallback func(hostname string, remote net.Addr, key PublicKey) error
// BannerCallback is the function type used for treat the banner sent by // BannerCallback is the function type used for treat the banner sent by
+1 -1
View File
@@ -20,7 +20,7 @@ func muxPair() (*mux, *mux) {
return s, c return s, c
} }
// Returns both ends of a channel, and the mux for the the 2nd // Returns both ends of a channel, and the mux for the 2nd
// channel. // channel.
func channelPair(t *testing.T) (*channel, *channel, *mux) { func channelPair(t *testing.T) (*channel, *channel, *mux) {
c, s := muxPair() c, s := muxPair()