diff --git a/blip-0051.md b/blip-0051.md index c0dd5c0..ccb6a8c 100644 --- a/blip-0051.md +++ b/blip-0051.md @@ -241,11 +241,12 @@ The client MUST check if [option_support_large_channel](https://bitcoinops.org/e **Errors** -| Code | Message | Data | Description | -| ---- | ------- | ----------- | ---- | -| -32602 | Invalid params | {"property": %invalid_property%, "message": %human_message% } | Invalid method parameter(s). | -| 001 | Client rejected | {"message": %human_message% } | [LSPS0.client_rejected_error][] | -| 100 | Option mismatch | {"property": %option_mismatch_property%, "message": %human_message% } | The order doesnt match the options defined in `lsps1.get_info.options`. | +| Code | Message | Data | Description | +| ------ | --------------------------- | ------------------------------------------------------------------------ | ----------------------------------------------------------------------- | +| -32602 | Invalid params | {"property": %invalid_property%, "message": %human_message% } | Invalid method parameter(s). | +| 001 | Client rejected | {"message": %human_message% } | [LSPS0.client_rejected_error][] | +| 100 | Option mismatch | {"property": %option_mismatch_property%, "message": %human_message% } | The order doesnt match the options defined in `lsps1.get_info.options`. | +| 102 | Unrecognized or stale token | {} | The provided token was unrecognized or stale. | - LSP MUST validate the order against the options defined in `lsps1.get_info.options`. LSP MUST return an `100` error in case of a mismatch. @@ -256,7 +257,7 @@ The client MUST check if [option_support_large_channel](https://bitcoinops.org/e - `%invalid_property%` MUST be one of the fields in the request body. MUST use `.` to separate nested fields. - Example: `{ "property": "announce_channel", "message": "Not a boolean" }`. -- LSP MUST validate the `token` field and return an error if the token is invalid. +- LSP MUST validate the `token` field and return a `102` error if the token is invalid. > **Rationale `token` validation** The client should be informed if the token is invalid. Ignoring the invalid token and creating an order without the potentially discount or other side effect is not good UX. Ignoring the invalid token will also NOT prevent anybody bruteforcing the token because the client will still detect if the LSP has given a discount.