Skip to content

Commit

Permalink
Initial expected policy will not be part of mapping, can be "re-mapped"
Browse files Browse the repository at this point in the history
  • Loading branch information
IngelaAndin committed Oct 30, 2023
1 parent 32fdc14 commit 192eaa0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/public_key/src/pubkey_cert.erl
Original file line number Diff line number Diff line change
Expand Up @@ -1064,10 +1064,10 @@ handle_policy_mapping_ext(#'PolicyMappings_SEQOF'{
MapPolicy =
fun(#{valid_policy := ValidPolicy, expected_policy_set := Set} = Node)
when ValidPolicy == IssuerPolicy ->
case Set == [ValidPolicy] of
true ->
case Set of %% If inital policy should be mapped over, but can map to itself
[ValidPolicy] when SubjectPolicy =/= ValidPolicy ->
Node#{expected_policy_set => [SubjectPolicy]};
false ->
_ ->
Node#{expected_policy_set => Set ++ [SubjectPolicy]}
end;
(Node) ->
Expand Down

0 comments on commit 192eaa0

Please sign in to comment.