Bug 1012405 - problems with md5 hashes
Summary: problems with md5 hashes
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: freeradius
Version: 6.4
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: rc
: ---
Assignee: Nikolai Kondrashov
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-26 12:18 UTC by Andy Clark
Modified: 2018-12-03 20:03 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-12-12 14:50:35 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Andy Clark 2013-09-26 12:18:14 UTC
Description of problem:
I have i problem with MD5 hashes on my RHEL 6.4 server.
Some of hashes, which i have created cannot match. 


Version-Release number of selected component (if applicable):
# cat /etc/redhat-release 
Red Hat Enterprise Linux Workstation release 6.4 (Santiago)
# uname -a
Linux nms-axn 2.6.32-358.6.2.el6.x86_64 #1 SMP Tue May 14 15:48:21 EDT 2013 x86_64 x86_64 x86_64 GNU/Linux
# rpm -qa | grep freeradius
freeradius-utils-2.1.12-4.el6_3.x86_64
freeradius-2.1.12-4.el6_3.x86_64
#


How reproducible:
create couple md5hash for some test account and try it with radtest utility 

Steps to Reproduce:
1. create md5 hash:
# echo "XZ4uaMt6" | md5sum | cut -f1 -d' '
3e9a59f0546a3c378beb0998f5873251
#
2. create user in the configuration file:
testuser           MD5-Password := "3e9a59f0546a3c378beb0998f5873251"
                   Service-Type = "Authenticate-Only",
                   Login-LAT-Group = "config"

3. restart radius server:
# service radiusd restart
Stopping radiusd:                                          [  OK  ]
Starting radiusd:                                          [  OK  ]
#

4. try our password
# radtest -t pap -x testuser XZ4uaMt6 10.0.9.30:1812 0 7RljN1k4
Sending Access-Request of id 87 to 10.0.9.30 port 1812
	User-Name = "testuser"
	User-Password = "XZ4uaMt6"
	NAS-IP-Address = 10.0.9.30
	NAS-Port = 0
	Message-Authenticator = 0x00000000000000000000000000000000
rad_recv: Access-Reject packet from host 10.0.9.30 port 1812, id=87, length=20
#

5. change our password:
# echo "test1234" | md5sum | cut -f1 -d' '
eddc02b200ae8a15a7e6b44ac05bf5f1
#

6. redefine password for our "testuser" account 
testuser	   MD5-Password := "eddc02b200ae8a15a7e6b44ac05bf5f1"
                   Service-Type = "Authenticate-Only",
                   Login-LAT-Group = "config"

7. restart radius service:
# service radiusd restart
Stopping radiusd:                                          [  OK  ]
Starting radiusd:                                          [  OK  ]
#

8. let's  try to do another attempt:
# radtest -t pap -x testuser test1234 10.0.9.30:1812 0 7RljN1k4
Sending Access-Request of id 251 to 10.0.9.30 port 1812
	User-Name = "testuser"
	User-Password = "test1234"
	NAS-IP-Address = 10.0.9.30
	NAS-Port = 0
	Message-Authenticator = 0x00000000000000000000000000000000
rad_recv: Access-Accept packet from host 10.0.9.30 port 1812, id=251, length=34
	Service-Type = Authenticate-Only
	Login-LAT-Group = 0x636f6e666967
#

Actual results:
Sometimes hashes don't match.

Expected results:
Hashes must has always match.

Additional info:

Comment 2 RHEL Program Management 2013-10-13 23:06:54 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unable to address this
request at this time.

Red Hat invites you to ask your support representative to
propose this request, if appropriate, in the next release of
Red Hat Enterprise Linux.

Comment 3 Dmitri Pal 2014-12-12 14:50:35 UTC
Does not seem to be an actual bug. It more like a wrong expectation of how things work.

Comment 4 Andy Clark 2014-12-12 15:54:39 UTC
It is not a wrong expectations. In case mentioned before
echo command should be called with -n option.


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