Implementing a mini-application in Flask that permits the management of user registration and login
€50-100 EUR
Kapalı
İlan edilme: 8 yıldan fazla önce
€50-100 EUR
Teslimde ödenir
Implementing a mini-application in Flask that permits the management of user registration and login.
Flask-SQLAlchemy is used internally. Below is the definition of a user:
class User ([login to view URL]):
__tablename__ = 'user'
id = [login to view URL] ([login to view URL], primary_key = True)
email = [login to view URL]([login to view URL](255), nullable = False, unique = True)
password = [login to view URL]([login to view URL] (255), nullable = False)
active = [login to view URL]([login to view URL] ())
As regards the forms, Flask-WTF plugin will be used. The login form can for example look like:
from flask_wtf import Form
from wtforms import StringField, PasswordField
from [login to view URL] import DataRequired, Email
class LoginForm(Form):
'''
User LoginForm implementation
'''
email = StringField('name', validators=[DataRequired(), Email])
password = PasswordField("Password", validators=[DataRequired()])
The objective is to implement the following use case:
1) User registration:
- The user fills out a form ([login to view URL])
- In view, we verify that fields are properly filled and send an email to the user that contains a validation link.
The user's password must be encrypted (Using proven cryptographic standards) ⇒ No storage of unencrypted passwords.
- The view must define a message (flash) containing information of success or errors (e.g. account created, existing email, ...). The message will be displayed by the template.
The account is only validated when the user has clicked on the confirmation link that he received by email. The mail setup must be present.
2) User login:
- From a form, a user must be able to login. The account must be blocked for an hour if the user used a wrong password three times. The values (1 hour and 3 *) must be configured.
In addition, a decorator is to be defined (e.g. login_required) which will indicate whether a view is accessible to a user or not.
Work demanded:
The code provided should be compatible with python3.4 and can be quickly integrated into an existing Flask application, which already contains templates and [login to view URL] login.html.
The html code thus needs to be minimal. Furthermore, it will use twitter bootstrap and its internal containerized system.
Moreover, since it will be used in production soon, it needs to be robust in terms of security and performance. The minimum files to be supplied are:
- [login to view URL]: user registration
- [login to view URL]: user login
- [login to view URL]: Master (main) file containing:
register_view()
login_view()
and any other python code necessary;
- [login to view URL]: application configuration
- Explanatory documentary for the integration.
Deadline: Saturday, August 8, 2015
In case you have any questions, just let me know.
Hello,
I am python developer mostly working with Flask and Bottle.PY. I already have production code that does what you want around similar Model. I can make a simple demo for you in a matter of minutes if you are intrested. If you like what I have to offer, I can give you well commented maintainable code with unit tests and pep8 complaint. As you are going to integrate this to an existing application, I would like to know if it already uses any Session mechanism like Beaker ? Hope we can work together on this project. Feel free to shoot any queries at me.
* Never mind my reviews, I had given control of my freelance account to friend who was out of work, he really earned me a reputation.
Good Day
Nahar
I am new to Freelancer, but I think I can complete your project cleanly and efficiently.
I have worked as a software engineer at a social gaming company and interned at a search engine.
I have worked with flask in the past where I implemented pretty much what you're asking for in this project.
Milestone 1: Registration with Hashed Password
Validate registration form, flash messages
Hash the plain password with PBKDF2 and store this
Milestone 2: Email Confirmation
Setup some SMTP server to send emails (depending on your size a simple Google account might be fine)
Validation link to activate accounts
Do you have an email template you want to use?
Milestone 3: Login Users
Flask-Login extension
Restrict views with decorator
Timeout for bad login (I can do this with session data, anything more complicated probably can't be done at this price)
Not sure what your project's security requirements are, but if want it secure in production, you'll need to have https.