Last active
May 4, 2017 04:10
-
-
Save gatherKnowledge/e6ae9034bd2e4f4cd02e20b942c3f0b0 to your computer and use it in GitHub Desktop.
Google - Authentication
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//* POINT | |
//throght the url(included the secret number), Your server and user's smart phone became a sync | |
public static String getQRBarcodeURL(String user, String host, String secret) { | |
String format = "http://chart.apis.google.com/chart?cht=qr&chs=300x300&chl=otpauth://totp/%s@%s%%3Fsecret%%3D%s&chld=H|0"; | |
return String.format(format, user, host, secret); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment