28-seclevel.conf.in 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. # -*- mode: perl; -*-
  2. # Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
  3. #
  4. # Licensed under the Apache License 2.0 (the "License"). You may not use
  5. # this file except in compliance with the License. You can obtain a copy
  6. # in the file LICENSE in the source distribution or at
  7. # https://www.openssl.org/source/license.html
  8. ## SSL test configurations
  9. package ssltests;
  10. use OpenSSL::Test::Utils;
  11. our @tests = (
  12. {
  13. name => "SECLEVEL 3 with default key",
  14. server => { "CipherString" => "DEFAULT:\@SECLEVEL=3" },
  15. client => { },
  16. test => { "ExpectedResult" => "ServerFail" },
  17. },
  18. );
  19. our @tests_ec = (
  20. {
  21. name => "SECLEVEL 3 with ED448 key",
  22. server => { "CipherString" => "DEFAULT:\@SECLEVEL=3",
  23. "Certificate" => test_pem("server-ed448-cert.pem"),
  24. "PrivateKey" => test_pem("server-ed448-key.pem") },
  25. client => { },
  26. test => { "ExpectedResult" => "Success" },
  27. },
  28. {
  29. name => "SECLEVEL 3 with P-384 key, X25519 ECDHE",
  30. server => { "CipherString" => "DEFAULT:\@SECLEVEL=3",
  31. "Certificate" => test_pem("p384-server-cert.pem"),
  32. "PrivateKey" => test_pem("p384-server-key.pem"),
  33. "Groups" => "X25519" },
  34. client => { "CipherString" => "ECDHE:\@SECLEVEL=3",
  35. "VerifyCAFile" => test_pem("p384-root.pem") },
  36. test => { "ExpectedResult" => "Success" },
  37. },
  38. );
  39. our @tests_tls1_2 = (
  40. {
  41. name => "SECLEVEL 3 with ED448 key, TLSv1.2",
  42. server => { "CipherString" => "DEFAULT:\@SECLEVEL=3",
  43. "Certificate" => test_pem("server-ed448-cert.pem"),
  44. "PrivateKey" => test_pem("server-ed448-key.pem"),
  45. "MaxProtocol" => "TLSv1.2" },
  46. client => { },
  47. test => { "ExpectedResult" => "Success" },
  48. },
  49. );
  50. push @tests, @tests_ec unless disabled("ec");
  51. push @tests, @tests_tls1_2 unless disabled("tls1_2") || disabled("ec");