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

Function encrypt not supported #4025

Closed
jackysp opened this issue Aug 4, 2017 · 5 comments
Closed

Function encrypt not supported #4025

jackysp opened this issue Aug 4, 2017 · 5 comments
Assignees

Comments

@jackysp
Copy link
Member

jackysp commented Aug 4, 2017

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?
    If possible, provide a recipe for reproducing the error.
select length(encrypt('foo', 'ff')) <> 0;
  1. What did you expect to see?
length(encrypt('foo', 'ff')) <> 0
1
  1. What did you see instead?
ERROR 1305 (42000) at line 1: FUNCTION ENCRYPT does not exist
  1. What version of TiDB are you using (tidb-server -V)?
@jackysp jackysp changed the title Function encrypt not supported Function encrypt not supported Aug 4, 2017
@winkyao winkyao self-assigned this Aug 4, 2017
@winkyao
Copy link
Contributor

winkyao commented Aug 8, 2017

Note
The ENCRYPT() function is deprecated as of MySQL 5.7.6, will be removed in a future MySQL release, and should no longer be used. Consider using AES_ENCRYPT() instead.

See https://dev.mysql.com/doc/refman/5.7/en/encryption-functions.html#function_encrypt

@winkyao
Copy link
Contributor

winkyao commented Aug 15, 2017

resolved the issue will use cgo, will make TiDB rely on specific platform, so the better way is port crypt function in golang, but the function is deprecated and will be removed in a future of MySQL, so it isn't a high priority issue now.

@morgo
Copy link
Contributor

morgo commented May 30, 2018

A followup to @winkyao's comment: this function was removed from MySQL 8.0.3.

@morgo
Copy link
Contributor

morgo commented Feb 13, 2019

This function was removed from MySQL 8.0 to prevent users from using weak crypto. I am going to close this issue for now, but we can re-consider if it becomes a blocking issue for someone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants