Explorar o código

Fixes #18271: Require only encryption OR authentication algorithm when creating an IPSec proposal via REST API

Jeremy Stretch hai 1 ano
pai
achega
b9abb3200c
Modificáronse 1 ficheiros con 4 adicións e 2 borrados
  1. 4 2
      netbox/vpn/api/serializers_/crypto.py

+ 4 - 2
netbox/vpn/api/serializers_/crypto.py

@@ -64,10 +64,12 @@ class IKEPolicySerializer(NetBoxModelSerializer):
 
 class IPSecProposalSerializer(NetBoxModelSerializer):
     encryption_algorithm = ChoiceField(
-        choices=EncryptionAlgorithmChoices
+        choices=EncryptionAlgorithmChoices,
+        required=False
     )
     authentication_algorithm = ChoiceField(
-        choices=AuthenticationAlgorithmChoices
+        choices=AuthenticationAlgorithmChoices,
+        required=False
     )
 
     class Meta: