Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Promptless message signing #588

Open
broody opened this issue Aug 16, 2024 · 2 comments
Open

Promptless message signing #588

broody opened this issue Aug 16, 2024 · 2 comments
Assignees

Comments

@broody
Copy link
Contributor

broody commented Aug 16, 2024

When signing a typed message, webauthn is used so a prompt is displayed. We can enable a way to sign the message with the session key instead and avoid the prompt.

@rsodre
Copy link

rsodre commented Aug 16, 2024

this is an example of a message we sign every time players make a move, to generate a salt.
maybe the controller could auto-sign by domain name, if we add it to policies?

{
    "primaryType": "Message",
    "domain": {
        "revision": "1",
        "name": "Underware",
        "chainId": "WP_PISTOLS_STAGING",
        "version": "0.1.0"
    },
    "types": {
        "StarknetDomain": [
            {
                "name": "revision",
                "type": "shortstring"
            },
            {
                "name": "name",
                "type": "shortstring"
            },
            {
                "name": "chainId",
                "type": "shortstring"
            },
            {
                "name": "version",
                "type": "shortstring"
            }
        ],
        "Message": [
            {
                "name": "duelId",
                "type": "felt"
            },
            {
                "name": "roundNumber",
                "type": "felt"
            },
            {
                "name": "duelistId",
                "type": "felt"
            }
        ]
    },
    "message": {
        "duelId": "0x15c9fea7d74ee59",
        "roundNumber": "0x1",
        "duelistId": "0xb"
    }
}
Screenshot 2024-08-14 at 16 52 12

@rsodre
Copy link

rsodre commented Sep 12, 2024

bump!

Signing typed data is very useful, and essential for us to create a deterministic local secret for each player

Using touch id on a Macbook is easy, but players using other auth methods will be pissed about doing it all the time.

@broody broody self-assigned this Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants