Bug 23180 - encrypt() function not working
Summary: encrypt() function not working
Status: CLOSED DUPLICATE of bug 22649
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: mysql   
(Show other bugs)
Version: 7.0
Hardware: i386
OS: Linux
high
high
Target Milestone: ---
Assignee: Patrick Macdonald
QA Contact: David Lawrence
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2001-01-02 21:38 UTC by Hao Li
Modified: 2005-10-31 22:00 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2001-01-02 22:30:12 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description Hao Li 2001-01-02 21:38:30 UTC
encrypt() always gives "NULL" on Red Hat 7.0:

[hli@lexus] ~ $ mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 98 to server version: 3.23.29-gamma-log

Type 'help;' or '\h' for help. Type '\c' to clear the buffer

mysql> select encrypt("hello");
+------------------+
| encrypt("hello") |
+------------------+
| NULL             |
+------------------+
1 row in set (0.00 sec)

mysql> select encrypt("hello",1234);
+-----------------------+
| encrypt("hello",1234) |
+-----------------------+
| NULL                  |
+-----------------------+
1 row in set (0.00 sec)



I am using Red Hat 7.0's updated mysql-3.23.29-1 and glibc-2.2-9.
According to
http://www.mysql.com/documentation/mysql/commented/manual.php?section=Miscellaneous_functions
"If crypt() is not available on your system, ENCRYPT() always returns
NULL.". So I suspect that this is glibc's problem.

Before I upgraded to RH70 I was running mysql-3.22.32 with glibc-2.1.3
(both compiled myself), and encrypt definitely worked. Now with glibc-2.2
even if I pull out the same /usb/bin/mysql executable from mysql-3.22.32
encrypt gives NULL.

I noticed this problem because after the upgrade to RH70 my bugzilla broke.
The authenticate doesn't work any more and I traced it down to the
encrypt() which always give NULL.

Any help would be greatly appreciated since it is impossible for me to
downgrade glibc, unless I bring up a new box with RH62.

Comment 1 Hao Li 2001-01-02 21:58:33 UTC
Sorry I gave some incorrect information. Indeed as previous bug report on the
same issue encrypt() works in mysql-3.22.32.

And switching to PostgreSQL is not always a viable solution for everyone. For
example bugzilla users don't have this option since bugzilla is tied to mysql,
and Red Hat is unfortunately one of them.

BTW I apologize for having posted the duplicate bug report. Somehow my first
search for similar bugs didn't turn up anything.


Comment 2 Ian Prowell 2001-01-02 22:30:09 UTC
I setup a RedHat 7.0 system from scratch and had bugzilla functioning, but this
morning I updated the packages that have been updated since Dec 13, 2000 and the
problem described started.  It seems like one of the recent updates broke
encrypt() in mysql.

Comment 3 Trond Eivind Glomsrxd 2001-01-03 10:51:12 UTC

*** This bug has been marked as a duplicate of 22649 ***


Note You need to log in before you can comment on or make changes to this bug.