Google Auth app and system generated codes are different
rnkhouse opened this issue · 2 comments
rnkhouse commented
I entered secret in google authenticator app. It generates random code in every few seconds. But, when I match with my code it's different.
$this->load->library('GoogleAuthenticator');
$oneCode = $this->googleauthenticator->getCode($secret);
$oneCode
is different than I see in google app.
PHPGangsta commented
Most often it's a time problem, so the clock is not synchronized between the mobile phone and the server. Please check if both systems have the same time, then they should generate the same code (with the same secret used).
zxyaust commented
that is a problem indid. When the secret is long(maybe morethan 16length),The code is different from google app.