todo's
[ga4php.git] / lib / lib.php
index 8967ffe..57a4cbf 100644 (file)
@@ -4,6 +4,9 @@
  * TODO's:
  * Implement TOTP fully
  * Error checking, lots of error checking
+ * have a way of encapsulating token data stright into a single field so it could be added
+ *    in some way to a preexisting app without modifying the DB as such... or by just adding
+ *    a single field to a user table...
  */
 
 class GoogleAuthenticator {
@@ -228,7 +231,7 @@ class GoogleAuthenticator {
                                $en = $tlid+20;
                                for($i=$st; $i<$en; $i++) {
                                        $stest = $this->oath_hotp($tkey, $i);
-                                       error_log("code: $code, $stest, $tkey, $tid");
+                                       //error_log("code: $code, $stest, $tkey, $tid");
                                        if($code == $stest) {
                                                $sql = "update tokens set token_lastid='$i' where token_id='$tid'";
                                                $this->dbConnector->query($sql);
@@ -243,10 +246,10 @@ class GoogleAuthenticator {
                                $t_lat = $t_now + 60;
                                $t_st = ((int)($t_ear/30));
                                $t_en = ((int)($t_lat/30));
-                               error_log("kmac: $t_now, $t_ear, $t_lat, $t_st, $t_en");
+                               //error_log("kmac: $t_now, $t_ear, $t_lat, $t_st, $t_en");
                                for($i=$t_st; $i<=$t_en; $i++) {
                                        $stest = $this->oath_hotp($tkey, $i);
-                                       error_log("code: $code, $stest, $tkey\n");
+                                       //error_log("code: $code, $stest, $tkey\n");
                                        if($code == $stest) {
                                                return true;
                                        }