Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Commit

Permalink
go fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
emersion committed Mar 12, 2019
1 parent a5db695 commit 969552d
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions canonical.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import (
type Canonicalization string

const (
CanonicalizationSimple Canonicalization = "simple"
CanonicalizationRelaxed = "relaxed"
CanonicalizationSimple Canonicalization = "simple"
CanonicalizationRelaxed = "relaxed"
)

type canonicalizer interface {
Expand Down
2 changes: 1 addition & 1 deletion dkim_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ GMot/L2x0IYyMLAz6oLWh2hm7zwtb0CgOrPo1ke44hFYnfc=
const testEd25519PrivateKeyBase64 = "nWGxne/9WmC6hEr0kuwsxERJxWl7MmkZcDusAxyuf2A="

var (
testPrivateKey *rsa.PrivateKey
testPrivateKey *rsa.PrivateKey
testEd25519PrivateKey ed25519.PrivateKey
)

Expand Down
4 changes: 2 additions & 2 deletions query.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,8 @@ func parsePublicKey(s string) (*queryResult, error) {
}
// RFC 8301 section 3.2: verifiers MUST NOT consider signatures using
// RSA keys of less than 1024 bits as valid signatures.
if rsaPub.Size() * 8 < 1024 {
return nil, permFailError(fmt.Sprintf("key is too short: want 1024 bits, has %v bits", rsaPub.Size() * 8))
if rsaPub.Size()*8 < 1024 {
return nil, permFailError(fmt.Sprintf("key is too short: want 1024 bits, has %v bits", rsaPub.Size()*8))
}
res.Verifier = rsaVerifier{rsaPub}
res.KeyAlgo = "rsa"
Expand Down
2 changes: 1 addition & 1 deletion query_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func init() {

func queryTest(domain, selector string) (*queryResult, error) {
record := selector + "._domainkey." + domain
switch record {
switch record {
case "brisbane._domainkey.example.com", "brisbane._domainkey.example.org", "test._domainkey.football.example.com":
return parsePublicKey(dnsPublicKey)
case "brisbane._domainkey.football.example.com":
Expand Down

0 comments on commit 969552d

Please sign in to comment.