Questions tagged [signature]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
3
votes
1answer
25 views

Do miners undergo a sunken cost of attempting to verify an invalid transaction signature?

In the case of an 'invalid' transaction whereby the state transition of the execution is deemed to conflict in some way and reverts, the transaction itself is actually valid; gas is consumed, tx ...
0
votes
0answers
15 views

How does ecrecover get compiled?

How does ecrecover() in solidity work? Looking at ethervm.io there doesn't seem to be an opcode for ecrecover? To what bytes is a ecrecover() call compiled?
0
votes
0answers
13 views

Does the EVM have an opcode to check private key signatures?

I have plain and simple desire. I want my dapp users to be able to generate some data payload, sign it with their private key, and send it using any external channel (eg JSON between apps) to a ...
1
vote
2answers
54 views

Multi-signature contract with offline signing

Is it possible to create a multi-signature contract that would not require a transaction for every signature (since this is quite expensive for a higher number of transactions)? Is it possible to ...
0
votes
1answer
32 views

ethers.js wrong signature

From the same private key in ethers.js and secp256k1 I get the same eth address. But if I sign a message I get a different (wrong) signature in ethers.js. What is wrong with my code? import { ...
0
votes
1answer
15 views

EcRecover signed message does not match PublicAddress

I am trying to create a C# webservice back end API that handles the code logic found in Step #5 here: https://www.toptal.com/ethereum/one-click-login-flows-a-metamask-tutorial Their code looks like ...
0
votes
1answer
16 views

Do smart contract transactions get signed?

When you send a transaction to a smart contract by using the contract.methods.methodName().send() is it signed by the sender? If not how can I link the sender to that transaction call
1
vote
1answer
40 views

Recovered address not matching signer address (using ethers)

Below is a simple signature verification flow I wrote, along with a test case with Buidler (all mainly to learn how to verify signatures in a Solidity smart contract). The problem is that the address ...
2
votes
1answer
29 views

Create signed message without JSON RPC node in PHP

I am trying to recreate effect of web3's eth.accounts.sign in PHP and I struggle to find good resources how to do it properly. I have seen this (found it thanks to this thread) and based on what I ...
2
votes
0answers
16 views

Why does clef not implement ethereum's JSON-RPC

Assuming that the RPC standard still matches what is to be found today on the ethereum wiki, I was rather surprised to learn that the method calls provided by clef do not match the signer methods in ...
0
votes
2answers
32 views

Offline creation of signed contract transactions with web3js v1.2.11

I'm attempting to sign a contract transaction offline using web3js v1.2.11. signingAddr = //my eth address signingPk = //my private key // docs: The options object for the contract instance. from, ...
0
votes
0answers
14 views

Signing text with special UTF8 characters browser vs node web3js

I am attempting to get consistent signatures / recovery for text containing special characters. For example, the bitcoin symbol U+20BF, ₿ Junk address and private key: ...
0
votes
1answer
25 views

Signing a request with a signature gives the wrong from address

I am using ethers to get a signed request. I have a signature for the address 0x518171C334AD3adc1cF990A884D67963201B675F. It is, ...
0
votes
1answer
25 views

What is the equivalent of “buildTransaction” of web3Py in web3JS?

I'm using Node to interact with my smart contract. I understand that I need to first sign my transaction before sending it. In one of the StackExchange answers I see that it can be done using ...
1
vote
1answer
26 views

Does the term “Ethereum ECDSA signature” have a consistent meaning?

If you were writing some instructions and one of them was: Provide the Ethereum ECDSA signature of the file using the person's Ethereum address. Would the above instruction have a consistent meaning ...
2
votes
1answer
45 views

Signing a message to sell NFT/token - what happens if you transfer the NFT later?

If you sign a message with intent to list an NFT/token for sale - how does that work if you transfer the item later? For example on an NFT marketplace - you list your NFT for sale by signing a message....
0
votes
2answers
45 views

Signature test failed at Truffle js

I'm trying to test validAddress function from my contract ValidationUser, using truffle and test with JS. I checked the V value from the signature and its 27,28 so it is not the problem. Also, I have ...
3
votes
1answer
37 views

Ethereum Signing using HSM

I tried signing a Message using the SHA256withECDSA algorithm . It gives a different signed(r,s) output everytime. When i try to recover the address using the ecrevover method .it gives me a different ...
0
votes
1answer
37 views

signing transaction in web3 is not returning msgHash

I am trying to write provble_transfer where owner can pay gas fee for the transaction. Below is the code for signing transaction to my test contact. let rawTransaction = { 'from': ...
1
vote
1answer
48 views

Signing a raw transaction, wrong R and S values

I am trying to sign a raw transaction in javascript without relying on dependencies like web3, ethereumjs, etc. I am following the python tutorial found here, and porting to JS as I go: https://...
0
votes
1answer
35 views

Is it best practice to check signature malleability in ecrecover

I am wondering if it is considered best practice to guard against signature malleability to check against the half curve order like this or if this is totally unnecessary. uint256 constant ...
1
vote
1answer
36 views

Verifying Signatures from other ECC Curves with ecRecover

My Question is, can I verify a ECDSA Signature from a different ECC Curve like scep128r1 or secp256k1 with the ecRecover function? If not, are there any good Library's which have implemented this ...
2
votes
0answers
38 views

When is a “shard block” cross-linked into a “finalized beacon block”?

In Ethereum 2.0, a shard block for being finalized needs to be linked into a finalized beacon block. Under which conditions a "shard block" cross-linked into a "finalized beacon block"? Having 2/3 of ...
0
votes
0answers
83 views

ethereumjs-tx : sign transaction using unlocked account

Web3js has the following method : web3.eth.signTransaction(transactionObject, address [, callback]) to sign a transaction using an unlocked account. Can we sign a transaction in a similar way, ...
0
votes
1answer
31 views

How to sign transactions while Geth does not provide private key?

I've lunched Geth for the first time and created some accounts on it. While creating accounts, I entered a password for each, and a key file is generated which contains encrypted private key belonging ...
1
vote
3answers
105 views

Get method signature from contract rather than manually constructing

Is there a way to get a method signature from the contract object (using Web3.py) rather than manually constructing it? I don't see a function in there that accomplishes this. It seems like ...
2
votes
2answers
66 views

How to decode a transaction to verify its signature in Javascript?

I noticed that it's possible to sign a transaction with a wrong private key. I took the following example found at https://github.com/ethereumjs/ethereumjs-tx const EthereumTx = require('ethereumjs-...
2
votes
1answer
49 views

What if a malicious validator denies to sign a new block in a shard committee in Ethereum 2.0?

In Ethereum 2.0 (Sharding Blockchain), a new block requires to be signed by all the validators as members of a committee, where blockchain has been sharded in smaller parts for supporting parallel ...
1
vote
0answers
37 views

address recovery from signature

Sorry for the long question, I tried to keep it as standalone as possible. For my master thesis I'm analyzing historical data coming from price oracles contract events. In particular, the MakerDAO ...
1
vote
0answers
15 views

web3.eth.personal.sign is not a function error when deployed on heroku

I am building dApp with react as my front-end frame work, i encountered this error when I deployed on Heroku, sign function doesn't work and it displays that error, specifically TypeError: A.t2.sign....
0
votes
0answers
16 views

How to pay Gas for client? [duplicate]

I'm building a DApp for donations and I do not want my donator ( or donatee) to pay for Gas. Thus I'm looking for a solution wherein gas is to be deducted from my wallet (third party) and not from ...
2
votes
0answers
26 views

Signatures real use case? [closed]

I'm new to this Ethereum community and I've been reading about signatures processes in Ethereum and smart contracts processes and always end up finding a general use-case where someone signs a "hello ...
1
vote
1answer
32 views

Understanding Transaction in Bitcoin [closed]

I read a lecture about Bitcoin Blockchain. As shown in the slide below, a user Alice sends a transaction to BoB. Alice should 1-) Hash(Hash of the transaction of the coin || Bob Public Key || Alice ...
1
vote
1answer
49 views

Signing message with private key and verifying signer in smart contract

I have a smart contract that provides a message to sign and then validates the signer of the message. Something like: mapping(address => uint) public userNonce; function getSigner(bytes32 ...
2
votes
1answer
52 views

What's the magic numbers meaning of 27 or 28 in VRS ( use to ecrover the sender) ? why not 0 or 1?

What's the magic numbers meaning of 27 or 28 in VRS ( use to ecrover the sender) ? why not 0 or 1? Ecrecover need 0 or 1, but transaction RLP is 27 or 28. Before ecrecover, sub 27 to get 0 or 1. Why ...
0
votes
0answers
40 views

Signature not matching the sig obtained from MyEtherWallet

I am serializing the unsigned txn in C, then I found Keccak-256 hash and I signed it with the privatekey. However, the resulting signature is not the same as in MyEtherWallet for the same values(...
1
vote
1answer
272 views

Metamask Signing gives different signature than web3.js

I have successfully been using metamask to sign EIP712 data. I am currently trying to write truffle tests and need to replicate the signing process outside the browser. The issue I am facing is that ...
2
votes
0answers
70 views

EIP-712 typed signature for arrays

I'm trying to generate a typed signature for an array in JavaScript based on EIP-712 and using eth-sig-util. My problem is that I need to sign an array. It says in the specification to use Type[] or ...
0
votes
2answers
41 views

Recovering of typed signature fails because it's too long

I have a typed signature generated by EIP712 V3. It is 132 characters long. I'm trying to recover it using recoverTypedSignature from eth-sig-util. This fails saying: index.js:1 Error: Invalid ...
0
votes
0answers
17 views

How to recover a signature on the server side?

I need to verify the signer of a signature in my node server. const fortmaticApiKey = 'pk_live_...'; const checkPersonalSignature = async (data, signature, signer) => { try { const { get } =...
1
vote
1answer
59 views

Different address make same signature for one message

Is it possible two different wallets (address) make the same signature for one message? I have one message: '...
1
vote
0answers
23 views

Recover public key from message and signature [duplicate]

I try to recover a public key (not an address) from a message and a signature. I have the following message: def offer_hash(msg, nonce): types = ['bytes', 'bytes', '...
0
votes
2answers
98 views

Own private key of smart contract to sign a line of text

For my project it is necessary for smart contract to sign a message (for example, EC-signature) I have not found a way to generate a pair of public and private keys inside the contract so that the ...
1
vote
1answer
40 views

Knowing the message, can a signature be derived from an address or pubkey?

tl;dr if I were to sign an Ethereum message, eg. web3.eth.personal.sign("Bitcoin", "SOME-ETH-ADDRESS"), would it be reasonably safe to use a 32-byte hash of the signature as the private key for a ...
0
votes
1answer
67 views

Simple Question on ecrecover

I think that I can verify a hash of a message using my signature within a Solidity contract, something like this: contract ecrecover { function testRecovery(bytes32 hash, bytes signature) returns ...
0
votes
2answers
407 views

Sign message with web3 and verify with openzeppelin-solidity ECDSA.sol

I'm trying to get a little example working with ECDSA.sol here: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/cryptography/ECDSA.sol This contract: Generate a random(...
0
votes
1answer
48 views

DDEX Api Question for Python… Signing ETH Transactions?

Having an issue with signing a message for the DDEX api... I'm trying to do it in python, and for some reason my signature is off by two characters. Here's my code using the private key and UTC ...
1
vote
1answer
97 views

How Can I Sign A Transaction Server-Side?

I have a server-side Node.js app that sends a transaction to an Ethereum smart contract like so: const transaction = await contract.methods .method_name([params]).send({ from: [...
1
vote
1answer
38 views

Risk of Messages Not Having a Signature

As per my understanding transactions are signed before sending to Ethereum. Else, no transfer of Ether will happen. However, messages sent to Smart Contracts (SC) aren't signed (e.g., using methods....
2
votes
1answer
116 views

ecrecover in c++

can anyone spot what I am doing wrong? I am trying to recover the public address from data signed by web3.personal.sign in Metamask and with this code the public address comes out wrong. Hash and hex/...

1
2 3 4 5 6