Skip to content

Commit

Permalink
nip46: we have no business checking the pubkey of the sign_event result.
Browse files Browse the repository at this point in the history
  • Loading branch information
fiatjaf committed Oct 26, 2024
1 parent de7bbfc commit a72e471
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nip46.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ export class BunkerSigner {
async signEvent(event: UnsignedEvent): Promise<VerifiedEvent> {
let resp = await this.sendRequest('sign_event', [JSON.stringify(event)])
let signed: NostrEvent = JSON.parse(resp)
if (signed.pubkey === this.bp.pubkey && verifyEvent(signed)) {
if (verifyEvent(signed)) {
return signed
} else {
throw new Error(`event returned from bunker is improperly signed: ${JSON.stringify(signed)}`)
Expand Down

0 comments on commit a72e471

Please sign in to comment.