Repository navigation
feat: host a signed Network Descriptor and JWKS from quick-start [OpenAgriNet/network-adapter#74] - #82
feat: host a signed Network Descriptor and JWKS from quick-start [OpenAgriNet/network-adapter#74]#82tdprajwal wants to merge 4 commits into
Conversation
dbd9721 to
2fbcd4b
Compare
0fd8192 to
de61c44
Compare
ameersohel45
left a comment
There was a problem hiding this comment.
1. Key id mismatch (blocking)
setup.py:542 signs with the entry's osid, but the adapter looks up the key's own osid (sunbirdRegistry.go:548). Once validateSign is on, every call fails with key_id_mismatch. Quick-start doesn't show it because validateSign is off there. Can we agree on one id before merging?
2. Schema URL pattern
On an already-seeded registry, old rows still have raw.githubusercontent URLs, so the new pattern will refuse any update to them. Can the pattern accept both forms?
^https://(raw\.githubusercontent\.com/OpenAgriNet/network-specs/[A-Za-z0-9_-]+|openagrinet\.github\.io/network-specs)/schema/[A-Za-z0-9]+/v[0-9]+\.[0-9]+/[A-Za-z0-9_-]+\.yaml$
ameersohel45
left a comment
There was a problem hiding this comment.
make host-descriptor doesn't host anything
It only writes the descriptor, JWKS and schema-packs files into .well-known/. Serving them still needs NPM recreated for the new mount and well-known.conf pasted in by hand. Can we either make the command do what its name says, or rename it to something like make prepare-desc-jwks-schemaPack?
1f3a29f to
2905f8d
Compare
2905f8d to
96830d4
Compare
|
Thanks @ameersohel45 , all three addressed:
|
What
make host-descriptorgenerates the signed Network Descriptor, JWKS andschema-packs.json from the network's registry entry and serves them through NPM.
Also fixes a Keycloak restart loop after an interrupted boot.
Why
Another network needs these to find and verify us before admitting us.
Testing
Tested on two local networks: the peer verifies over HTTPS, and tampered
documents are refused. Calls signed with the UUID keyId are accepted;
osid-signed calls are refused.
Closes OpenAgriNet/network-adapter#74