-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Altinn.Common.PEP and use await Verify() instead of custom code (
#918) * Use await Verify() instead of custom code * Update Altinn.Common.PEP and Storage.Interfaces
- Loading branch information
Showing
13 changed files
with
358 additions
and
433 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
113 changes: 113 additions & 0 deletions
113
...equest_generates_multidecisionrequest_with_all_actions_current_task_elemtnId.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
{ | ||
Request: { | ||
ReturnPolicyIdList: false, | ||
CombinedDecision: false, | ||
Resource: [ | ||
{ | ||
Id: r1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:altinn:task, | ||
Value: Task_1, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:instance-id, | ||
Value: 1337/1dd16477-187b-463c-8adf-592c7fa78459, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
}, | ||
{ | ||
AttributeId: urn:altinn:partyid, | ||
Value: 1337, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:org, | ||
Value: tdd, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:app, | ||
Value: test-app, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
} | ||
] | ||
} | ||
], | ||
Action: [ | ||
{ | ||
Id: a1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:oasis:names:tc:xacml:1.0:action:action-id, | ||
Value: sign, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
} | ||
] | ||
}, | ||
{ | ||
Id: a2, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:oasis:names:tc:xacml:1.0:action:action-id, | ||
Value: reject, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
} | ||
] | ||
} | ||
], | ||
AccessSubject: [ | ||
{ | ||
Id: s1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:altinn:authlevel, | ||
Value: 3, | ||
Issuer: LOCAL AUTHORITY, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:partyid, | ||
Value: 1337, | ||
Issuer: LOCAL AUTHORITY, | ||
DataType: string, | ||
IncludeInResult: false | ||
} | ||
] | ||
} | ||
], | ||
MultiRequests: { | ||
RequestReference: [ | ||
{ | ||
ReferenceId: [ | ||
s1, | ||
a1, | ||
r1 | ||
] | ||
}, | ||
{ | ||
ReferenceId: [ | ||
s1, | ||
a2, | ||
r1 | ||
] | ||
} | ||
] | ||
} | ||
} | ||
} |
113 changes: 113 additions & 0 deletions
113
...ultiDecisionRequest_generates_multidecisionrequest_with_all_actions_endevent.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
{ | ||
Request: { | ||
ReturnPolicyIdList: false, | ||
CombinedDecision: false, | ||
Resource: [ | ||
{ | ||
Id: r1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:altinn:end-event, | ||
Value: EndEvent_1, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:instance-id, | ||
Value: 1337/1dd16477-187b-463c-8adf-592c7fa78459, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
}, | ||
{ | ||
AttributeId: urn:altinn:partyid, | ||
Value: 1337, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:org, | ||
Value: tdd, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:app, | ||
Value: test-app, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
} | ||
] | ||
} | ||
], | ||
Action: [ | ||
{ | ||
Id: a1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:oasis:names:tc:xacml:1.0:action:action-id, | ||
Value: sign, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
} | ||
] | ||
}, | ||
{ | ||
Id: a2, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:oasis:names:tc:xacml:1.0:action:action-id, | ||
Value: reject, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
} | ||
] | ||
} | ||
], | ||
AccessSubject: [ | ||
{ | ||
Id: s1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:altinn:authlevel, | ||
Value: 3, | ||
Issuer: LOCAL AUTHORITY, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:partyid, | ||
Value: 1337, | ||
Issuer: LOCAL AUTHORITY, | ||
DataType: string, | ||
IncludeInResult: false | ||
} | ||
] | ||
} | ||
], | ||
MultiRequests: { | ||
RequestReference: [ | ||
{ | ||
ReferenceId: [ | ||
s1, | ||
a1, | ||
r1 | ||
] | ||
}, | ||
{ | ||
ReferenceId: [ | ||
s1, | ||
a2, | ||
r1 | ||
] | ||
} | ||
] | ||
} | ||
} | ||
} |
113 changes: 113 additions & 0 deletions
113
...uest_generates_multidecisionrequest_with_all_actions_instanceId_is_GUID_only.verified.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
{ | ||
Request: { | ||
ReturnPolicyIdList: false, | ||
CombinedDecision: false, | ||
Resource: [ | ||
{ | ||
Id: r1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:altinn:task, | ||
Value: Task_1, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:instance-id, | ||
Value: 1337/1dd16477-187b-463c-8adf-592c7fa78459, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
}, | ||
{ | ||
AttributeId: urn:altinn:partyid, | ||
Value: 1337, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:org, | ||
Value: tdd, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:app, | ||
Value: test-app, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: false | ||
} | ||
] | ||
} | ||
], | ||
Action: [ | ||
{ | ||
Id: a1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:oasis:names:tc:xacml:1.0:action:action-id, | ||
Value: sign, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
} | ||
] | ||
}, | ||
{ | ||
Id: a2, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:oasis:names:tc:xacml:1.0:action:action-id, | ||
Value: reject, | ||
Issuer: Altinn, | ||
DataType: string, | ||
IncludeInResult: true | ||
} | ||
] | ||
} | ||
], | ||
AccessSubject: [ | ||
{ | ||
Id: s1, | ||
Attribute: [ | ||
{ | ||
AttributeId: urn:altinn:authlevel, | ||
Value: 3, | ||
Issuer: LOCAL AUTHORITY, | ||
DataType: string, | ||
IncludeInResult: false | ||
}, | ||
{ | ||
AttributeId: urn:altinn:partyid, | ||
Value: 1337, | ||
Issuer: LOCAL AUTHORITY, | ||
DataType: string, | ||
IncludeInResult: false | ||
} | ||
] | ||
} | ||
], | ||
MultiRequests: { | ||
RequestReference: [ | ||
{ | ||
ReferenceId: [ | ||
s1, | ||
a1, | ||
r1 | ||
] | ||
}, | ||
{ | ||
ReferenceId: [ | ||
s1, | ||
a2, | ||
r1 | ||
] | ||
} | ||
] | ||
} | ||
} | ||
} |
Oops, something went wrong.