mirror of
https://github.com/slackhq/nebula.git
synced 2026-07-02 03:20:29 +02:00
better check
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
package noiseutil
|
package noiseutil
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"crypto/fips140"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/flynn/noise"
|
"github.com/flynn/noise"
|
||||||
@@ -22,7 +23,7 @@ func TestNewCipherStateDispatch(t *testing.T) {
|
|||||||
encA, _ := buildCipherStates(t, CipherAESGCM)
|
encA, _ := buildCipherStates(t, CipherAESGCM)
|
||||||
encC, _ := buildCipherStates(t, noise.CipherChaChaPoly)
|
encC, _ := buildCipherStates(t, noise.CipherChaChaPoly)
|
||||||
|
|
||||||
if !EncryptLockNeeded {
|
if !fips140.Enabled() {
|
||||||
assert.IsType(t, &CipherStateAESGCM{}, NewCipherState(encA, CipherAESGCM))
|
assert.IsType(t, &CipherStateAESGCM{}, NewCipherState(encA, CipherAESGCM))
|
||||||
} else {
|
} else {
|
||||||
// fips140
|
// fips140
|
||||||
|
|||||||
Reference in New Issue
Block a user