Skip to content

Commit

Permalink
Remove dupword true positives and disable dupword
Browse files Browse the repository at this point in the history
  • Loading branch information
aidantwoods-1p committed Jul 19, 2023
1 parent b7540a7 commit 82dbb11
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ linters:
# too noisy
- cyclop
- depguard
# dupword is somewhat useful, but tagging false positives is not a good use of anyone's time
- dupword
- exhaustivestruct
- funlen
- gochecknoglobals
Expand Down
4 changes: 2 additions & 2 deletions example_sharedkey_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ func Example() {
// Some time later, we actually want to authenticate with this stuff
// Client and server may talk. Depending on what the client has locally,
// The client may need to be told its salt, and the SRP group to use
// But here we will assume that that the client knows this, and already has
// But here we will assume that the client knows this, and already has
// computed x.

client := srp.NewClientStd(srp.KnownGroups[group], x)
Expand Down Expand Up @@ -129,7 +129,7 @@ func Example() {
log.Fatal(err)
}

// client tests tests that the server sent a good proof
// client tests that the server sent a good proof
if !client.GoodServerProof(salt, username, serverProof) {
// Client must bail and not send a its own proof back to the server
log.Fatal("bad proof from server")
Expand Down
2 changes: 1 addition & 1 deletion group.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ type Group struct {
ExponentSize int // RFC 3526 §8
}

// N returns the modulus of the the group.
// N returns the modulus of the group.
func (g *Group) N() *big.Int {
return g.n
}
Expand Down
4 changes: 2 additions & 2 deletions srp.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ while proving to each other that they each know their long term secrets (x is th
secret and v is the server's secret). Although the key that you arrive at is 32 bytes, its
strength is a function of the group size used.
Creating the SRP object with with NewSRPServer()/NewSRPClient() takes care of generating your ephemeral
Creating the SRP object with NewSRPServer()/NewSRPClient() takes care of generating your ephemeral
secret (a or b depending on whether you are a client or server), your public
ephemeral key (A or B depending on whether you are a client or server),
the multiplier k. (There is a setter for k if you wish to use a different scheme
Expand Down Expand Up @@ -101,7 +101,7 @@ NewSRPServer sets up an SRP object for a server.
Recall that group is the Diffie-Hellman group to be used,
v is your long term secret and k is the set multiplier.
Pass in a a nil k if you want it to be generated for you.
Pass in a nil k if you want it to be generated for you.
Note that you need the same k on both server and client.
*/
func NewSRPServer(group *Group, v, k *big.Int) *SRP {
Expand Down

0 comments on commit 82dbb11

Please sign in to comment.