From 59cecbc7e8f00ff7e6ee11a07bed15b14a0acc54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Depierrepont=20aka=20Toorop?= Date: Fri, 15 May 2015 07:49:31 +0200 Subject: [PATCH] export SigOptions --- dkim.go | 8 ++++---- dkimHeader.go | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/dkim.go b/dkim.go index d110deb..7c4ff6b 100644 --- a/dkim.go +++ b/dkim.go @@ -38,7 +38,7 @@ const ( ) // sigOptions represents signing options -type sigOptions struct { +type SigOptions struct { // DKIM version (default 1) Version uint @@ -84,8 +84,8 @@ type sigOptions struct { } // NewSigOption returns new sigoption with some defaults value -func NewSigOptions() sigOptions { - return sigOptions{ +func NewSigOptions() SigOptions { + return SigOptions{ Version: 1, Canonicalization: "simple/simple", Algo: "rsa-sha256", @@ -98,7 +98,7 @@ func NewSigOptions() sigOptions { } // Sign signs an email -func Sign(email *[]byte, options sigOptions) error { +func Sign(email *[]byte, options SigOptions) error { var privateKey *rsa.PrivateKey // PrivateKey diff --git a/dkimHeader.go b/dkimHeader.go index 133e1ae..ab7cefb 100644 --- a/dkimHeader.go +++ b/dkimHeader.go @@ -197,7 +197,7 @@ type dkimHeader struct { } // NewDkimHeaderBySigOptions return a new DkimHeader initioalized with sigOptions value -func newDkimHeaderBySigOptions(options sigOptions) *dkimHeader { +func newDkimHeaderBySigOptions(options SigOptions) *dkimHeader { h := new(dkimHeader) h.Version = "1" h.Algorithm = options.Algo