Skip to content
This repository was archived by the owner on Dec 19, 2025. It is now read-only.

Comments

Implement RFC 9540#47

Merged
nothingmuch merged 1 commit intopayjoin:mainfrom
nothingmuch:rfc-9540
Mar 14, 2025
Merged

Implement RFC 9540#47
nothingmuch merged 1 commit intopayjoin:mainfrom
nothingmuch:rfc-9540

Conversation

@nothingmuch
Copy link
Collaborator

@nothingmuch nothingmuch commented Feb 5, 2025

Note: This is a breaking change, and requires directory support for RFC 9540 as well.

This change modifies the relay to assume that both the the OHTTP gateway
and the ohttp keys reside at /.well-known/ohttp-gateway, with POST
requests implementing the OHTTP gateway functionality and GET requests
fetching the OHTTP keys.

Extends #46, but does not strictly depend on it.

Depends on #57

@nothingmuch
Copy link
Collaborator Author

Opened as draft because of the breaking nature of this change, and in case #46 is rejected in which case this should be rebased to not depend on it.

Copy link
Collaborator

@DanGould DanGould left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do I understand correctly that if #46 is merged as well as this PR, the changes will not break our practical use of this relay implementation in the wild that we're aware of?

Or is your preference not to support both /ohttp-keys AND this change?

@nothingmuch
Copy link
Collaborator Author

Do I understand correctly that if #46 is merged as well as this PR, the changes will not break our practical use of this relay implementation in the wild that we're aware of?

#46 should be fine to merge for the stated reason.

However, this PR will break unless the payjoin-directory is also updated (2nd commit of payjoin/rust-payjoin#530 which I will shortly make into its own separate PR).

Or is your preference not to support both /ohttp-keys AND this change?

Actually I think we should support both at least for some transition period as it's just 2 lines in the code, and because the ohttp-keys endpoint is depended on not just by the ohttp-relay but also payjoin receivers. I did remove support for it in payjoin/rust-payjoin#530, but only for testing purposes.

@DanGould DanGould marked this pull request as ready for review February 21, 2025 22:19
@DanGould DanGould marked this pull request as draft February 21, 2025 22:19
Copy link
Collaborator

@DanGould DanGould left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK 7f07cf8

This requires a change to payjoin-directory to use this gateway uri order to work. Our payjoin-directory change must be backwards compatible, and then once we're convinced ohttp-relays have updated we can roll out a payjoin-directory that removes the backwards compatibility.

@nothingmuch nothingmuch force-pushed the rfc-9540 branch 4 times, most recently from 3f22f93 to d52c0cb Compare March 9, 2025 17:08
DanGould added a commit to payjoin/rust-payjoin that referenced this pull request Mar 11, 2025
A backwards compatible change to support RFC 9540.

The directory accepts requests at `/.well-known/ohttp-gateway`. The
receiver also fetches OHTTP keys from the new RFC 9540 endpoint, instead
of `/ohttp-keys`.

Unblocks payjoin/ohttp-relay#47.
@DanGould DanGould removed the blocked label Mar 11, 2025
RFC 9540 specifies a standard location (/.well-known/ohttp-gateway) for
the OHTTP gateway, where the keys can be fetched with a GET request and
OHTTP requests to the target resource can be POSTed.
@nothingmuch nothingmuch marked this pull request as ready for review March 14, 2025 23:08
Copy link
Collaborator

@DanGould DanGould left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 34c62a9

@nothingmuch nothingmuch merged commit 0842b51 into payjoin:main Mar 14, 2025
5 checks passed
@nothingmuch nothingmuch deleted the rfc-9540 branch March 15, 2025 02:26
node-smithxby72w added a commit to node-smithxby72w/rust-payjoin that referenced this pull request Sep 28, 2025
A backwards compatible change to support RFC 9540.

The directory accepts requests at `/.well-known/ohttp-gateway`. The
receiver also fetches OHTTP keys from the new RFC 9540 endpoint, instead
of `/ohttp-keys`.

Unblocks payjoin/ohttp-relay#47.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants