truffle-box / react-auth-box

Truffle, Webpack, React, Redux boilerplate with routing and authentication via a smart contract.
https://truffle-box.github.io/
MIT License
176 stars 66 forks source link

Authentication not working #2

Open DSandman opened 7 years ago

DSandman commented 7 years ago

Authentication, signing up doesn't seem to work for me. This might be the issue: https://github.com/truffle-box/truffle-box-auth/blob/master/contracts/Authentication.sol#L27

I believe signup and update shouldn't have the payable modifier.

apackin commented 7 years ago

It's working for me locally - are you receiving errors anywhere? It seems like the payable modifier is added so that these functions wont error if devs add code expecting payment in the future. That shouldn't cause issues when executing without payment.

OnlyOneJMJQ commented 7 years ago

@DSandman Are there any errors in the console? When clicking sign up does it redirect anywhere? Last question: Are you using MetaMask in Chrome? Thanks!

tmashuang commented 7 years ago

Look like I am having a similar issue. Running testrpc, Metamask, React-Auth-Box. I am unable login after the notification pop up to approve the transaction. The notification spins a constant loading spinner but says it approved in the Metamask Tx history. Contracts were published on TestRPC, but Metamask isn't able to interact with it. Afterward, error in the console says Wallet 0x92e7... does not have an account! Will look into it more on the Metamask side.

2624789 commented 7 years ago

I'm running React-auth-box + Geth (Ropsten) + Metamask and signup and login works, but redirection is not working.

ghost commented 6 years ago

Change var userName = web3.toUtf8(result) in LoginButtonActtion.js to var userName = web3.utils.toUtf8(result)