Skip to main content

Application security authenticater

Project description

UCONRA

An application security hasher, tokenization and SMTP creator

uconra is a simple application Authentication security password hasher and basic tokenization and smtp creator for basic python, flask or django applications

Installation

'''python

pip install uconra

'''

Different usages for different use cases.

Usage for password hashing and email validation

'''python

from uconra.register import Register

pass_word = 'enter_your_password'
user_email = 'cody@gmail.com'

email = str(register.userEmail(user_email))

password = register.userPassword(pass_word)

print(password)

'''

Usage for creating basic j_wt token

'''python

from uconra.j_wt import JWT

token = JWT()

login_token = token.generate_jwt_token('cody@gmail.com', key='3uiojjkskdpeisjdjfl')

print(f"encoded jwt token : {login_token}")

decode_login_token = token.decode_jwt_token(login_token)

print(decode_login_token['email'])

print(f"decoded jwt token : {decode_login_token}")

'''

smtp basic usage setup

'''python

from uconra.smtp_mail import SMTP_Mail

confirm_message = MailMessage()
"""
app_pw = 'hjdj j3l2 guess whaid'
myMail = 'cody@gmail.com'
mail_server = 'smtp.gmail.com:587'
ehlo = 'Gmail'
message = 'Here goes your message'
user = 'user@gmail.com'
OTP = 1324
"""

sendMail = SMTP_Mail(
appKey=app_pw, userMail=email,
senderMail=myMail, serverEhlo=ehlo,
smtpServer=mail_server,
subject='TEST SUBJECT', userName=username,
message=confirm_message.confirm_message(token=login_token, otp=OTP),
                )

sendMail.sendMail()

'''

Mail message for the above smtp usage

'''python

from uconra.email_message import MailMessage

message = MailMessage()

print(message.confirm_message(token=7890))

'''

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

uconra-1.0.4.tar.gz (9.2 kB view hashes)

Uploaded Source

Built Distribution

uconra-1.0.4-py3-none-any.whl (9.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page