How long is a Google Authenticator export valid and can it be used/imported multiple times? - google-authenticator

Title says it all. Have to put in extra characters to make it a valid post.
Thanks.

The QR code exported by Google Authenticator should be valid forever and can be imported as many times as you wish because it uses TOTP technology.
You will notice the phone doesn't need to be connected to internet to generate the QR code this is because it combines the OTP (you entered the OTP when adding the 2FA) and a secret.

Related

How to generate a QR code from WeChat user id?

I want to be able to input a WeChat user id and somehow be able to generate the corresponding WeChat QR code on the screen.. is this possible and if so how do you do it?
Unfortunately, you can't.
3 years ago, you can generate QR code from URL: http://open.weixin.qq.com/qr/code/?username=<wechat_id>. However, this API is unavailable now. It seems Tencent disabled this interface due to security consideration -- this API can be easily abused to send spam invitation.
If you speak Chinese, please check https://www.zhihu.com/question/21384291 for discussion on this topic in history.
If you would like to create your own QR code for your WeChat profile, you must first download the current QR code of your profile in WeChat.
Go to your profile, go to “My QR Code” and select the three dots in the top right corner, select “Save Image”.
The QR code is now stored in your photo album.
Screenshot: How to get WeChat QR Code for your profile
Before you can create your own QR code, you must decode the URL to your profile from the downloaded QR code. To do so use the ZXing decoder.
Upload your QR code there and you will receive the URL that is behind the QR Code. Now you can use this URL to create a QR code for your profile.
In the following post you see detailed description how to create QR Codes for your profile or for official WeChat acccounts:
https://blog.qrd.by/2018/06/05/create-designer-wechat-qr-codes-for-official-accounts/
As it was written above, you can't create QR code by means of user ID, but you can use your QR code to generate a web-page containing a link to your WeChat profile using https://msng.link.
This can help to show links to your messengers in social network sites. This should take just a minute, I've made a video instruction for you here: https://www.youtube.com/watch?v=Db8eNHSuSXM

Telegram API - Password to Dots

I am trying to create a ChatBot where using Python I interact with Telegram API to get update of previous message and reply suitably. My user's message could be a password which cannot be displayed and need to converted into dots(*****). Is there such feature to convert PW to dots ? Any help would be appreciated.
Telegram doesn't support this at this time, but you can try to use inline keyboard contain 0-9 number instead of it.

Token image in Google Authenticator or FreeOTP

For a project, I implemented an OTP 2nd factor authentification. Everything is working fine, I am able to generate a QRcode for the encryption seed, read it on an Androïd smartphone and use the 6 digits generated code to authenticate in my app.
I read that v1.5 of FreeOTP is now supporting addition of an image to each service, quote:
On Android, we released a major release which brings many new features and UI refinements. The biggest of these is image support. Images can be selected for each token. Images can also be provisioned to the device via an undocumented OTP URI query parameter.
I see that some services did succeed in adding an image for their service (for example OVH), but cannot find the proper URI syntax to do so ...
To be more precise, I am not asking for the method to manually add an image to a token in the FreeOTP app, I'm looking for the correct URI to generate the QRCode that would ideally include a link to the image to be displayed. I'm pretty sure I never manually added an image for OVH.
The correct URI to generate the QR code with reference to the image you want to use in FreeOTP includes a querystring parameter pointing to its publicly available location:
...&image=http<s>://<image-path>
The image should be a .png. Fully qualify path and protocol.
Add this to the existing string already created for the QR code. You have to UrlEncode the whole string before generating the QR code.
For clarity the format of the data before urlencoding should be:
otpauth://totp/(<issuer>:)<accountnospaces>?secret=xxxxxxxxxx(&issuer=<issuer>)(&image=<imageuri>)
Brackets denote optional elements. For example:
otpauth://totp/Google:SampleName?MQ2TQNLEGMYTMOBXGY3Q&issuer=Google&image=http://google.com/image/logo.png
Then you urlencode it:
otpauth%3A%2F%2Ftotp%2FGoogle%3ASampleName%3FMQ2TQNLEGMYTMOBXGY3Q%26issuer%3DGoogle%26image%3Dhttp%3A%2F%2Fgoogle.com%2Fimage%2Flogo.png
Then you generate a QR code however you like. For example, Google Chart API:
https://chart.googleapis.com/chart?cht=qr&chs=400x400&chl=otpauth%3A%2F%2Ftotp%2FGoogle%3ASampleName%3FMQ2TQNLEGMYTMOBXGY3Q%26issuer%3DGoogle%26image%3Dhttp%3A%2F%2Fgoogle.com%2Fimage%2Flogo.png
While this feature is supported by FreeOTP, other apps do not. It's not part of the spec for TOTP, although it should be.

QR Codes conversion

I have a text to QR code converter. I want to use it to create QR codes like Website URL, YouTube Video, Google Maps Location, Telephone Number, Skype Call, SMS Message, Email Address, Email Message, Contact Details (VCARD), Event (VCALENDAR), Tlephone Number
Can you give me the codes to create it like I got to create Email-
MATMSG:
TO:xyz#abc.com;
SUB:I am sending this email using QR code;
BODY:I have stored all of your letters in QR codes.
[Add more here]
Thanks
[Your Name];;
You can check my QR code generator
Note that only some QR code readers will recognize those different types and it's not universal for various phones/devices. You are better off keeping it simple with text string/URL until all devices adhere to standard. Android seems to support the most types and the reference implementation is their Barcode Scanner which is also open sourced on google code (zxing).
http://code.google.com/p/zxing/
You can view their source for how they generate the different types... Then compare your output to theirs with this online generator:
http://zxing.appspot.com/generator

Is it possible to have a QR code go to a website AND send a SMS message with the same link?

My boss wants me to fashion a QR code so that when the user scans it, it displays a button that when clicked:
(1) Will take the user to our website.
(2) Will quietly send us a text message.
The purpose of #2 is to allow us to gather their phone number.
In addition to being a privacy violation, I'm pretty sure this (and any other means of achieving this), is technically impossible. Is that correct?
My understanding of QR codes is that they only contain text. That text may contain keywords which a good reader may parse and display buttons for. It seems the closest I can get to my employer's requirement is to use an SMSTO: link in the QR code, so that (given an appropriate reader) the user is prompted to send us an SMS, at which point we can get their number.
Can anyone think of another way of doing this?
(any other clarification also welcome)
It is technically impossible.
As you say, the best you can do is create an smsto: link.
What you can do is create a code with the instruction
"Scan the code to receive our website by SMS"
Then, create a code with
smsto:123456:website
This will send the keyword "website" to a phone number. You'll need to set up a phone number which can auto-respond with the URL you want. There are commercial services which do this (depending on where you are in the world). Or look at a service like FrontlineSMS which can send the texts on your behalf.

Resources