File: const.go

package info (click to toggle)
golang-github-go-crypt-crypt 0.4.7-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 516 kB
  • sloc: makefile: 4
file content (57 lines) | stat: -rw-r--r-- 1,753 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
package pbkdf2

import (
	"math"
)

const (
	// EncodingFmt is the encoding format for this algorithm.
	EncodingFmt = "$%s$%d$%s$%s"

	// AlgName is the name for this algorithm.
	AlgName = "pbkdf2"

	// AlgIdentifier is the identifier used in encoded digests for this algorithm.
	AlgIdentifier = AlgName

	// AlgIdentifierSHA1 is the identifier used in encoded SHA1 variants of this algorithm.
	AlgIdentifierSHA1 = "pbkdf2-sha1"

	// AlgIdentifierSHA224 is the identifier used in encoded SHA224 variants of this algorithm.
	AlgIdentifierSHA224 = "pbkdf2-sha224"

	// AlgIdentifierSHA256 is the identifier used in encoded SHA256 variants of this algorithm.
	AlgIdentifierSHA256 = "pbkdf2-sha256"

	// AlgIdentifierSHA384 is the identifier used in encoded SHA384 variants of this algorithm.
	AlgIdentifierSHA384 = "pbkdf2-sha384"

	// AlgIdentifierSHA512 is the identifier used in encoded SHA512 variants of this algorithm.
	AlgIdentifierSHA512 = "pbkdf2-sha512"

	// KeyLengthMax is the maximum tag size accepted.
	KeyLengthMax = math.MaxInt32

	// SaltLengthMin is the minimum salt size accepted.
	SaltLengthMin = 8

	// SaltLengthMax is the maximum salt size accepted.
	SaltLengthMax = math.MaxInt32

	// IterationsMin is the minimum iterations accepted.
	IterationsMin = 100000

	// IterationsMax is the maximum iterations accepted.
	IterationsMax = math.MaxInt32

	// IterationsDefaultSHA1 is the default iterations for algorithms SHA1 and SHA224.
	IterationsDefaultSHA1 = 720000

	// IterationsDefaultSHA256 is the default iterations for algorithms SHA256 and SHA384.
	IterationsDefaultSHA256 = 310000

	// IterationsDefaultSHA512 is the default iterations for algorithms SHA512.
	IterationsDefaultSHA512 = 120000

	variantDefault = VariantSHA256
)