Refactor setup
This commit is contained in:
parent
94b317f135
commit
0456595f68
25 changed files with 37 additions and 33 deletions
|
|
@ -1,25 +0,0 @@
|
|||
package internal
|
||||
|
||||
import (
|
||||
"gitlab.com/ProtonMail/go-pm-crypto/constants"
|
||||
"regexp"
|
||||
)
|
||||
|
||||
func TrimNewlines(input string) string {
|
||||
var re = regexp.MustCompile(`(?m)[ \t]*$`)
|
||||
return re.ReplaceAllString(input, "")
|
||||
}
|
||||
|
||||
// Amount of seconds that a signature may be created after the verify time
|
||||
// Consistent with the 2 day slack allowed in the ProtonMail Email Parser
|
||||
const CreationTimeOffset = int64(60 * 60 * 24 * 2)
|
||||
|
||||
const (
|
||||
ARMOR_HEADER_VERSION = "Pmcrypto Golang 0.0.1 (" + constants.VERSION + ")"
|
||||
ARMOR_HEADER_COMMENT = "https://protonmail.com"
|
||||
)
|
||||
|
||||
var ArmorHeaders = map[string]string{
|
||||
"Version": ARMOR_HEADER_VERSION,
|
||||
"Comment": ARMOR_HEADER_COMMENT,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue