FIP: JSON Farcaster Signatures #208
Replies: 5 comments 3 replies
-
Is there something we should take care of to make this interoperable between languages? (I have the protobuf serialization issue in mind, is there a danger we will have a similar issue?) |
Beta Was this translation helpful? Give feedback.
-
So glad we're standardizing this |
Beta Was this translation helpful? Give feedback.
-
Do addresses need to be checksummed or is all lower case fine? |
Beta Was this translation helpful? Give feedback.
-
Note that JFS are not JWS. There are two main differences:
See JFS implementation below that documents in-depth signature validation for both app and custody keys: https://github.com/nounder/json-farcaster-signature/blob/master/jfs.ts |
Beta Was this translation helpful? Give feedback.
-
Where is the |
Beta Was this translation helpful? Give feedback.
-
FIP: Farcaster JSON Signatures
FIP: Farcaster JSON Signatures
Title: Farcaster JSON Signatures
Authors: @deodad
Problem
Farcaster identities don't have a standardized way to sign arbitrary payloads.
Specification
JSON Farcaster Signatures (JFS) provides a simple standard to compactly and efficiently sign JSON data. This specification is inspired by JWS but it is not a strict implementation of it.
A JFS is made up of three components:
To create a JFS:
For step 3, the signing input is as follows:
ASCII(BASE64URL(UTF8(Header)) || '.' || BASE64URL(Payload))
The entire JFS can then be compactly serialized as follows:
BASE64URL(header) + "." + BASE64URL(payload) + "." + BASE64URL(signature)
Alternatively the JFS can be serialized into a JSON format as follows:
To validate a JFS:
header
from the serialized representation and validate the following:signature
from the serialized representation and validate the following:Signing methods:
Custody Example
Signing
Validating
key
value specified in the header.Beta Was this translation helpful? Give feedback.
All reactions