From a9f7d7e212f31fa85e77a8cce1374438045392e8 Mon Sep 17 00:00:00 2001 From: Michiel de Mare Date: Wed, 28 Aug 2024 15:18:48 +0200 Subject: [PATCH] Added simpler sequence diagram (#3) * Added simpler sequence diagram * Don't cut off diagrams --- _layouts/default.html | 4 ++++ base-sequence.svg | 2 +- service-consumer.md | 6 +++++- simple-base-sequence.puml | 24 ++++++++++++++++++++++++ simple-base-sequence.svg | 1 + 5 files changed, 35 insertions(+), 2 deletions(-) create mode 100644 simple-base-sequence.puml create mode 100644 simple-base-sequence.svg diff --git a/_layouts/default.html b/_layouts/default.html index 7fb9f42..c34dc5d 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -16,6 +16,10 @@ p { margin-bottom: 10px; + + img { + max-height: 100% !important; /* ensure diagrams aren't cut off */ + } } p,ol li,ul li { diff --git a/base-sequence.svg b/base-sequence.svg index b91d0bf..a1cfa74 100644 --- a/base-sequence.svg +++ b/base-sequence.svg @@ -1 +1 @@ -ConsumerConsumerAssociation RegisterAssociation RegisterAuthorization Register (owner)Authorization Register (owner)Resource (owner)Resource (owner)/token (get authentication token)check client assertioncheck consumer still compliantOK: token/party (with token get owner party information)check tokenOK: party infoextract Authorization Register URL/token (get authentication token)check client assertion/token (get authentication token)check client assertioncheck AR still compliantOK: token/party (with token get consumer party information)check tokenOK: party infocheck consumer party info for complianceOK: token/delegation (with token and delegation mask)check tokencheck delegation mask policiesOK: delegation evidence/token (get authentication token)check client assertion/party (get consumer party information)check tokenOK: party infocheck consumer party info for complianceOK: token/some-resource (with token and delegation evidence)check tokencheck delegation evidenceOK: data \ No newline at end of file +ConsumerConsumerAssociation RegisterAssociation RegisterAuthorization Register (owner)Authorization Register (owner)Resource (owner)Resource (owner)/token (get authentication token)check client assertioncheck consumer still compliantOK: token/party (with token get owner party information)check tokenOK: party infoextract Authorization Register URL/token (get authentication token)check client assertion/token (get authentication token)check client assertioncheck AR still compliantOK: token/party (with token get consumer party information)check tokenOK: party infocheck consumer party info for complianceOK: token/delegation (with token and delegation mask)check tokencheck delegation mask policiesOK: delegation evidence/token (get authentication token)check client assertion/token (get authentication token)check client assertioncheck owner still compliantOK: token/party (with token get consumer party information)check tokenOK: party infocheck consumer party info for complianceOK: token/some-resource (with token and delegation evidence)check tokencheck delegation evidenceOK: data \ No newline at end of file diff --git a/service-consumer.md b/service-consumer.md index d6474d7..46a3ebd 100644 --- a/service-consumer.md +++ b/service-consumer.md @@ -75,6 +75,10 @@ To get the ID and the URL of the Authorization Registry, the Service Consumer sh To get the Bearer Token, the consumer must perform a token call on the Association Registry, passing a client assertion to them, containing the IDs of the consumer and the Association Registry. -#### Sequence Diagram +#### Sequence Diagram Without Authorization + +![Sequence diagram](simple-base-sequence.svg) + +#### Sequence Diagram With Pre-Authorization ![Sequence diagram](base-sequence.svg) diff --git a/simple-base-sequence.puml b/simple-base-sequence.puml new file mode 100644 index 0000000..8be2c79 --- /dev/null +++ b/simple-base-sequence.puml @@ -0,0 +1,24 @@ +@startuml + +participant "Consumer" as consumer +participant "Association Register" as association +participant "Authorization Register (owner)" as ownerAr +participant "Resource (owner)" as ownerApi + +consumer -> ownerApi : /token (get authentication token) +ownerApi -> ownerApi : check client assertion +ownerApi -> association : /token (get authentication token) +association -> association : check client assertion +association -> association : check owner still compliant +association -> ownerApi : OK: token +ownerApi -> association : /party (with token get consumer party information) +association -> association : check token +association -> ownerApi : OK: party info +ownerApi -> ownerApi : check consumer party info for compliance +ownerApi -> consumer : OK: token + +consumer -> ownerApi : /some-resource (with token) +ownerApi -> ownerApi : check token +ownerApi -> consumer : OK: data + +@enduml diff --git a/simple-base-sequence.svg b/simple-base-sequence.svg new file mode 100644 index 0000000..de4ef95 --- /dev/null +++ b/simple-base-sequence.svg @@ -0,0 +1 @@ +ConsumerConsumerAssociation RegisterAssociation RegisterAuthorization Register (owner)Authorization Register (owner)Resource (owner)Resource (owner)/token (get authentication token)check client assertion/token (get authentication token)check client assertioncheck owner still compliantOK: token/party (with token get consumer party information)check tokenOK: party infocheck consumer party info for complianceOK: token/some-resource (with token)check tokenOK: data \ No newline at end of file