Encryption improve error messages (#2595)

Signed-off-by: Hugo JOUBERT <hugo.joubert@ippon.fr>
Signed-off-by: Klopklopi <76015884+Klopklopi@users.noreply.github.com>
Signed-off-by: Hugo JOUBERT <hugo.joubert4@gmail.com>
Signed-off-by: Hugo JOUBERT <hugojklop52@gmail.com>
Co-authored-by: Hugo JOUBERT <hugo.joubert@ippon.fr>
Co-authored-by: Hugo JOUBERT <hugo.joubert4@gmail.com>
Co-authored-by: Andrei Ciobanu <andreic9203@gmail.com>
This commit is contained in:
Klopklopi
2025-05-07 16:28:28 +02:00
committed by GitHub
parent 0d3d36778d
commit 08f71e93c5
6 changed files with 97 additions and 19 deletions

View File

@@ -168,6 +168,17 @@ func TestCompliance(t *testing.T) {
return nil
},
},
"encryption-key-len-fail-on-build": {
HCL: `method "aes_gcm" "foo" {
keys = {
encryption_key = []
decryption_key = [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16]
}
}`,
ValidHCL: true,
ValidBuild: false,
Validate: nil,
},
},
ConfigStructTestCases: map[string]compliancetest.ConfigStructTestCase[*Config, *aesgcm]{
"empty": {