Closed haarts closed 7 months ago
Sending the password twice should work. I haven't figured out yet why the first try fails.
Odd. But that sounds like a workaround.
Naively I tried just sending the password twice by adding:
client
.check_password(password_token.clone(), password.trim())
.await?;
That doesn't work as it throws an error: SRP_ID_INVALID
. Some Googling taught me that this is related to Secure Remote Password as used by Telegram. I guess that the password_token
can't be cloned like that and that I need a new one for the second request.
I do observe that Telegram now thinks I have successfully logged in. But due to the error no state is persisted and thus I need to log in again when I run the example again.
Bad password should've been fixed by #230.
I'm trying to run the 'dialogs' example with
cargo run --example dialogs
. Everything works up until I enter my 2FA password, then the console outputs this (even the hint works! Cool):Obviously, I checked my 2FA by using it in the Telegram app and that works as expected, so I'm sure my password is correct. I also printed the captured password back to the console, and that looks A-OK.
What else can I try?