Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Syntax Error: UPDATE new License when encrypted #2

Closed
schnipdip opened this issue Aug 25, 2020 · 1 comment
Closed

Syntax Error: UPDATE new License when encrypted #2

schnipdip opened this issue Aug 25, 2020 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@schnipdip
Copy link
Owner

file:

raisensu.py

code:

sql_update = "UPDATE ASSETS SET {0} = '{1}' WHERE ID = {2}".format(updateColumn, key_object.encrypt(setValue), updateIndex)

issue:
when updating the license column, a syntax error is thrown.

@schnipdip schnipdip added the bug Something isn't working label Aug 25, 2020
@schnipdip schnipdip self-assigned this Aug 25, 2020
@schnipdip
Copy link
Owner Author

Fix:

Pass the variable as a string to encrypt it and then encode it to decrypt it.

Added line in file:
encryption.py

if type(encrypted_message) == str:
   encrypted_message = encrypted_message.encode()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant