Skip to content

Conversation

@OlegPhenomenon
Copy link
Contributor

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.

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.
@OlegPhenomenon OlegPhenomenon requested review from maricavor and vohmar and removed request for vohmar May 14, 2025 12:06
@vohmar vohmar assigned ratM1n and unassigned vohmar Jun 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants