Files
docker-cli/components/cli/vendor/github.com/theupdateframework/notary/fips.go
Justin Cormack ac4eb0950b Update Notary vendor to 0.6.1
Minor update.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
Upstream-commit: 8812c54a4d
Component: cli
2018-04-11 14:10:52 +01:00

15 lines
355 B
Go

package notary
import (
"crypto"
// Need to import md5 so can test availability.
_ "crypto/md5"
)
// FIPSEnabled returns true if running in FIPS mode.
// If compiled in FIPS mode the md5 hash function is never available
// even when imported. This seems to be the best test we have for it.
func FIPSEnabled() bool {
return !crypto.MD5.Available()
}