Questions tagged [itsdangerous]

itsdangerous is a part of the pallets project. It contains helpers to pass data to untrusted environments and to get it back safe and sound. Data is cryptographically signed to ensure that a token has not been tampered with.

See also

Related Tags

24 questions
0
votes
0 answers

Flask JWT token authentication error while username/password authentication works fine

I am trying to implement JWT token authentication for my Flask Rest project. When I authenticate using username and password I get generated token: http --auth test:testpass POST http://localhost:5000/api/v1/account/token HTTP/1.1 200…
ussrback
  • 491
  • 2
  • 8
  • 22
0
votes
1 answer

How to create a hyperlink with python and itsdangerous

I am new to Python and Flask, and am getting close to finishing my first project, but I have a question I have run in to. I am sending an email to people who have subscribed to a blog and am wanting to add a link to allow them to unsubscribe if the…
Dustin916
  • 1
  • 1
0
votes
2 answers

TypeError: unsupported operand type(s) for +: 'int' and 'bytes'

I have a table in sqlite called User and I want to check for token so that I can reset password. I get the error found in the title. here is the code: from datetime import datetime from itsdangerous import Serializer as Serializer from flaskblog…
Daniel
  • 63
  • 7
0
votes
1 answer

itsdangerous package Serializer doesn't work on host

I use itsdangerous to create a reset password link as follows: s = Serializer("mysecret") token = s.dumps(uname) and send the link with toekn to the user In load I have: @blueprint.route('/resetpass/') def resetpass(token): s…
Ahmad
  • 8,811
  • 11
  • 76
  • 141
0
votes
1 answer

TypeError: argument of type 'Mail' is not iterable

i am working on this email confirmation app using Flask. for this i am using flask_mail(obviously) but i am getting this error: TypeError: argument of type 'Mail' is not iterable @app.route('/email', methods=['GET', 'POST']) def send_mail(): …
vatsalay
  • 469
  • 1
  • 9
  • 21
0
votes
0 answers

TypeError: loads() got an unexpected keyword argument 'max'

i am using itsdangerous for generating token's for email confirmation and i want it to be expire after some time but i am getting this error: "TypeError: loads() got an unexpected keyword argument 'max_age' " Here's the…
vatsalay
  • 469
  • 1
  • 9
  • 21
0
votes
1 answer

Use JWT-Extended to produce JSON Web Signatures for user confirmation

I am building a RESTful API for an upcoming project. This needs some kind of user account verification. I implemented a token based confirmation procedure previously using itsdangerous. But I wonder wether I can accomplish the same by using…
Leonleon1
  • 165
  • 2
  • 8
0
votes
2 answers

the "dumps" method of itsdangerous throws a TypeError

I am following the guide of 『Flask Web Development』. I want to use itsdangerous to generate a token, but some problems occured. Here is my code: def generate_confirmation_token(self, expiration=3600): s =…
zaihui
  • 53
  • 1
  • 9
-1
votes
3 answers

Mail Not Sent In Gmail Account Using Flask-Mail

I am trying to add a functionality of resetting user password by sending email to a Gmail account. I have been following CoreySchafer YouTube Tutorial and Miguel Grinberg Tutorial to achieve this. The overall idea is user will be prompted with a…
1
2