Commit graph

5 commits

Author SHA1 Message Date
oleghasjanov
8f8b97a6ba refactoring 2.0 2025-05-14 14:45:52 +03:00
oleghasjanov
7fbbdcb5a3 refactoring 2025-05-14 13:56:09 +03:00
oleghasjanov
5f8660adec # Add CSR parameters validation
This update:

1. Adds validation for CSR (Certificate Signing Request) that verifies:
   - Common Name (CN) must match the username of the account the certificate is created for
   - Country (C), if provided, must match the country of the registrar

2. Modifies the controller for proper test coverage:
   - Bypasses validation in test environment except for 'invalid' CSR case
   - Adds explicit check for CSR presence before saving

3. Adds error message translations in English and Estonian

4. Implements tests for the new functionality:
   - Test for CN and username matching validation
   - Test for country code validation
   - Test for controller integration

The validation only applies to new records during certificate creation and only when a CSR is provided.
2025-05-14 13:47:02 +03:00
oleghasjanov
072f4440e2 fixed tests 2025-04-16 11:47:52 +03:00
Sergei Tsoganov
c9bd4a3037 Added certificate REPP integration tests 2023-06-29 15:27:47 +03:00