Internet-Draft | The 'taler' URI scheme | January 2024 |
Grothoff & Dold | Expires 10 July 2024 | [Page] |
This document defines the 'taler' Uniform Resource Identifier (URI) scheme for triggering interactions with a GNU Taler wallet.¶
This URI scheme allows applications to trigger interactions with the GNU Taler wallet, such as withdrawing money, making payments, receiving refunds and restoring a wallet from a backup. Applications may receive such URIs in many ways (including via NFC, QR codes, Web links or messaging applications), or might generate them internally to interact with a wallet. By having a Taler wallet handle the respective URIs, applications can integrate Taler payments without having to support the Taler protocol directly. Furthermore, by passing control to a Taler wallet process, the wallet's database with its financial data might be better protected from application failures.¶
This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.¶
Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/.¶
Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."¶
This Internet-Draft will expire on 10 July 2024.¶
Copyright (c) 2024 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.¶
This document defines the 'taler' Uniform Resource Identifier (URI) [RFC3986] scheme for triggering interactions with GNU Taler wallets.¶
A 'taler' URI always instructs a GNU Taler wallet to perform a particular operation. A 'taler' URI consists of an action and optional parameters.¶
The interpretation of the optional parameters depends on the action.¶
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.¶
This document uses the Augmented Backus-Naur Form (ABNF) of [RFC5234].¶
taler-URI = ("taler://" / "TALER://" / "taler+http://" / "TALER+HTTP://" ) action path-abempty [ "?" opts ] action = ALPHA *( ALPHA / DIGIT / "-" / "." ) opts = opt *( "&" opt ) opt = opt-name "=" opt-value opt-name = ALPHA *( ALPHA / DIGIT / "-" / "." / ":" ) opt-value = *pchar¶
'path-abempty' is defined in [RFC3986] in Section 3.3. 'pchar' is defined in [RFC3986], Appendix A.¶
The action of a Taler URI identifies the operation requested from the Taler wallet. Actions are not case-sensitive. The actions are defined in the "Taler URI Actions" sub-registry, see Section 8. The path component of the URI typically provides a network address needed to locate additional information or services relevant to the requested operation. Paths are case-sensitive, but may contain case-insensitive portions, such as domain names. The query component of the URI provides immediate additional parameters or options for the operation. The query is case-sensitive. The default operation of applications that invoke a URI with the taler scheme MUST be to launch a Taler wallet (if available). If no taler URI handler is available, an application SHOULD show a QR code with the contents of the URI. If multiple Taler wallets are registered, the user SHOULD be able to choose which application to launch. This allows users with multiple wallets (each possibly with its own money) to choose which wallet to perform the operation with. An application SHOULD allow dereferencing a "taler://" URI even if the action of that URI is not registered in the "Taler URI Actions" sub-registry. Wallets seeing a "taler://" URI MUST use HTTP over TLS when talking to the respective network service. Wallets seeing a "taler+http://" URI MUST use HTTP without TLS when talking to the respective network service. Wallets SHOULD support "taler+http://"-URIs only when run in developer or debug mode.¶
taler://pay/example.com/2022.268-03G33PTAY2C6T/\ 00f68430-363a-46b7-8e33-241a0e49c430?c=KKBWMSTF4AZSP8XS0FFNE9KM5M taler://pay-push/bank.example.com/\ 3BBW6N8PVDYBRT0DERT8YYARQGFYHVQFG3WVAN1D58FRP5JG3M4G TALER://PAY-PULL/BANK.EXAMPLE.COM/\ WB361HXN7BZ9ND1B9YP1Y20NB4H5WS0RNM4K8AFZ5Q2VRW577BPG¶
A registry of Taler URI Actions is described in Section 8. The registration policy for this registry is "Expert Review", as described in [RFC8126]. When requesting new entries, careful consideration of the following criteria is strongly advised:¶
The description clearly defines the semantics of the action and optional parameters if applicable.¶
The name states the unique name for the action that must be part of the URI.¶
The syntax defines the format of the action-specific part of the URI.¶
Relevant references are provided if they are available.¶
The chosen name is appropriate for the operation, and avoids potential to confuse users.¶
A libre software reference implementation is available.¶
Documents that support requests for new registry entries should provide the following information for each entry:¶
Description: A description of the action, including the semantics of the path in the URI if applicable.¶
Name: The name of the Taler URI action (case insensitive ASCII string, restricted to alphanumeric characters, dots and dashes)¶
Syntax: summary of the syntax of the URI as a one-liner.¶
Example: At least one example URI to illustrate the action.¶
Contact: The contact information of a person to contact for further information¶
References: Optionally, references describing the action (such as an RFC) and target-specific options.¶
This document populates the registry with $COUNT entries as follows (see also Section 8).¶
The action "withdraw" is used to trigger a bank-integrated withdrawal operation. This means that the user has been interacting with some online banking App and wants to instruct the bank to transfer money from the user's bank account into a the GNU Taler wallet. The wallet now needs to allow the user to select the GNU Taler exchange, and then ultimately provide the bank with its reserve public key and await the completion of the wire transfer.¶
The specific arguments of a "withdraw" action are:¶
bank_host: hostname of the bank (optionally including a port number)¶
bank_prefix_path: list of path components that identifies the path prefix of the bank integration API base URL¶
withdrawal_uid: the unique ID of the withdrawal operation¶
ext (optional): when set to "1", the wallet does not show a confirmation link to the user. Useful when the withdrawal is initiated from an account that is not controlled by the same user as the user of the wallet.¶
Payments are requested with the "pay" action. The parameters are a hierarchical identifier for the requested payment, and must include a hostname, order ID and session ID (which may be an empty string). Additionally, a claim token and a prefix path to be used as part of the HTTP REST API request to the hostname may be specified.¶
The specific arguments of a "pay" action are:¶
merchant_host: hostname of the GNU Taler REST service of merchant (may optionally include a port number)¶
merchant_prefix_path: list of path components that identifies the path prefix of the merchant base URL¶
order_id: the order ID that the customer is asked to pay for¶
session_id: the session ID under which the payment takes place¶
ct: a high-entropy order "ClaimToken"¶
A "refund" action instructs the wallet to download information about an available refund. Wallet SHOULD consult the user about the refund and then obtain the refund for an already paid order.¶
The specific arguments of a "refund" action are:¶
A pay-push URI instructs the wallet to ask the user about accepting a P2P payment. The wallet should download, decrypt and display the underlying contract and accept the offered money if the user agrees to the contract.¶
The specific arguments of a "pay-push" action are:¶
A pay-pull URI instructs the wallet about a request made to the user to pay an invoice (or to simply send money to another wallet). The wallet should download, decrypt and display the underlying contract and ask the user if they agree to pay the invoice.¶
The specific arguments of a "pay-pull" action are:¶
A "pay-template" action instructs the wallet to ask its user to manually complete an order template and submit the information to the merchant to obtain a "pay" request. Wallets MUST fetch meta data about the template from the merchant to determine which information to request from the user.¶
Wallets MAY support users entering all possible fields of a contract if allowed by the template. Fields that MUST be supported at this time are the "amount" and the "summary". The wallet MUST validate that the amount entered by the user is well-formed. For the amount, it is possible that the template restricts the currency in which case the wallet MUST only allow the user to enter an amount in that currency. If the amount entered by the user exceeds the wallet balance, the wallet SHOULD NOT allow the user to submit the action.¶
The specific arguments of a "pay-template" action is:¶
A "restore" action instructs the wallet to restore a wallet backup and merge it into its current state.¶
The specific arguments of a "restore" action are:¶
sync_rootkey: Root sync key of the wallet, used to derive the symmetric key to encrypt the backup with individual providers.¶
sync_provider_list: Comma-separated list of provider http or https URLs. If no scheme part is specified, https is assumed. Each URL is URI-encoded for all characters except "A-Z a-z 0-9 - _ . ! ~ * ' ( )" (matching the HTML5 encodeURIComponent).¶
An "dev-experiment" action instructs the wallet to simulate a particular error scenario. This action can be used to test the user interface. Wallets that are not in developer mode should not run the specified action and instead inform the user that "dev-experiment" actions are only supported in developer mode.¶
The specific arguments of a "dev-experiment" action are:¶
name: specifies the specific type of dev experiment¶
An "add-exchange" action instructs the wallet to add an exchange to its list of exchanges, download its meta data ("/config"), check that it is compatible with the wallet, and if it is a new exchange, ask the user to agree to the terms of service of the exchange. If the user agrees to the terms, the currency of the exchange should be added to the list of currencies.¶
The specific arguments of an "add-exchange" action are:¶
A "withdraw-exchange" action instructs the wallet to display a prompt to the user, asking the user to confirm/decline withdrawing from the exchange. The amount to be withdraw MAY be specified in the URI with the "amount" parameter and this SHOULD be used as suggested input for the withdraw. The user MUST accept the ToS and select the correct amount before starting the withdrawal.¶
The specific arguments of a "withdraw-exchange" action are:¶
exchange_host: hostname of the exchange (possibly including a port number)¶
exchange_prefix_path (optional): list of path components that identifies the path prefix of the exchange base URL¶
exchange_pub (optional): the public key of the exchange¶
amount_value (optional): default value to use for the withdrawal amount, currency included¶
Name: withdraw-exchange¶
Syntax: taler://withdraw-exchange/{exchange_host}{/exchange_prefix_path*}/{exchange_pub}{?a=amount_value]}¶
Example: taler://withdraw-exchange/exchange.example.com/ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789ABCDEFGHIJKLMNOP?a=KUDOS:10¶
Example: taler://withdraw-exchange/exchanges.example.com/exchange1/¶
Contact: N/A¶
References: [this.I-D]¶
A "withdrawal-transfer-result" action instructs the wallet to display the status of a withdrawal to the user. Typically used to transfer control between a banking app/website and a Taler wallet. Optionally, the URI can also specify an update to the status of the transfer to the exchange for the withdrawal as a hint for the wallet. The wallet must only use this value to show further hints to the user.¶
The specific arguments of a "withdraw-exchange" action are:¶
Interactive applications handling the taler URI scheme MUST NOT initiate any unsafe payment operations prior review and confirmation from the user, and MUST take measures to prevent clickjacking [HMW12].¶
The authentication/authorization mechanisms and transport security services used to process a payment encoded in a taler URI are handled by the application and are not in scope of this document.¶
IANA maintains a registry called the "Uniform Resource Identifier (URI) Schemes" registry.¶
IANA maintains the "Uniform Resource Identifier (URI) Schemes" registry that contains an entry for the 'taler' URI scheme. IANA is requested to update that entry to reference this document when published as an RFC.¶
This document specifies a list of Taler URI Actions. It is possible that future work will need to specify additional actions. The GNUnet Assigned Numbers Authority (GANA) [GANA] operates the "taler-uri-actions" registry to track the following information for each payment target type:¶
Name: The name of the action (case insensitive ASCII string, restricted to alphanumeric characters, dots and dashes)¶
Contact: The contact information of a person to contact for further information¶
References: Optionally, references describing the payment target type (such as an RFC) and target-specific options, or references describing the payment system underlying the payment target type.¶
The entries that have been made for the "taler-uri-actions" defined in this document are as follows:¶
Name | Contact | Reference ----------------------------+-------------------------+---------- pay | N/A | [This.I-D] withdraw | N/A | [This.I-D] refund | N/A | [This.I-D] pay-pull | N/A | [This.I-D] pay-push | N/A | [This.I-D] pay-template | N/A | [This.I-D] restore | N/A | [This.I-D] dev-experiment | N/A | [This.I-D] add-exchange | N/A | [This.I-D] withdraw-exchange | N/A | [This.I-D] withdrawal-transfer-result | N/A | [This-I.D.]¶