RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 841511 - Diffie-Hellman Groups DH24 Implementation Issue
Summary: Diffie-Hellman Groups DH24 Implementation Issue
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: openswan
Version: 6.3
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Paul Wouters
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-07-19 09:10 UTC by Ondrej Moriš
Modified: 2015-11-30 17:03 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-22 19:44:25 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Ondrej Moriš 2012-07-19 09:10:48 UTC
Description of problem:

When ike is set to use DH22 (eg. 3des-sha1-dh22) or DH23, on both
sides of the connection I see "calc_dh_shared(): time elapsed
(OAKLEY_GROUP_DH22)" and "calc_dh_shared(): time elapsed
(OAKLEY_GROUP_DH23)", respectively.

On the other hand whenever I set ike to use DH24, I correctly see
"calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24)" on both initiator
and responder, but there is also incorrect "calc_dh_shared(): time
elapsed (OAKLEY_GROUP_DH23)" in the responder log... which is really
confusing for me (nevertheless, connection works fine). I am attaching
responder's pluto.log (with ALL debug).

Configuration is as follows:

[initiator]
conn test
 authby=secret
 type=transport
 left=<INITIATOR>
 right=<RESPONDER>
 phase2=esp
 ike=3des-sha1-dh24
 auto=add

[responder]
conn test
 authby=secret
 type=transport
 left=<INITIATOR>
 right=<RESPONDER>
 phase2=esp
 ike=3des-sha1-dh24
 auto=add

Version-Release number of selected component (if applicable):

openswan-2.6.32-18.el6_3

How reproducible:

100%

Steps to Reproduce:

1. Set aforementioned configuration for initiator and responder.
2. Initiator: ipsec auto --up test 
3. See responder's /var/log/pluto.log.
  
Actual results:

...
calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH23)
...
calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24)
...

Expected results:

...
calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24)
...

Additional info:

This might be connected to Bug 584987 or Bug 568355.

Comment 1 Avesh Agarwal 2012-07-24 19:02:17 UTC
I tested this between 2 openswan VMs using various combination of dh22/23/24 and 3des/aes  and sha1/sha2 but did not notice any such issues in the log files. Could you please attach the logs or give access to the mchines your are using.

Comment 2 RHEL Program Management 2012-09-07 05:22:57 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 Paul Wouters 2014-03-25 00:06:34 UTC
It's definitely not a problem in openswan-2.6.32-27.3 or libreswan upstream git

build@bofh:~/libreswan/testing/pluto/algo-pluto-11/OUTPUT (master *)$ grep calc west.pluto.log
| main inR1_outI2: calculated ke+nonce, sending I2
| calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24): 820 usec
| main inR2_outI3: calculated DH, sending R1
| quick outI1: calculated ke+nonce, sending I1
| calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24): 745 usec
| quick inI1_outR1: calculated ke+nonce, calculating DH

grep calc_dh_shared /tmp/pluto.log
build@bofh:~/libreswan/testing/pluto/algo-pluto-11/OUTPUT (master *)$ grep calc east.pluto.log 
| main inI2_outR2: calculated ke+nonce, sending R2
| main inI2_outR2: starting async DH calculation (group=24)
| calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24): 855 usec
| main inI2_outR2: calculated DH finished
| quick inI1_outR1: calculated ke+nonce, calculating DH
| calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24): 729 usec
| quick inI1_outR1: calculated DH, sending R1

I tried with both specifying ike= and esp= and with only specifying ike=

Comment 4 Paul Wouters 2014-06-22 19:44:25 UTC
I can no longer reproduce this in 2.6.32-28:

 grep calc_dh_shared /tmp/pluto.log 
| calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24): 2043 usec
| calc_dh_shared(): time elapsed (OAKLEY_GROUP_DH24): 1132 usec

(note you see two because the modp group negotiated with phase1 is re-used for phase2)


this must have been fixed between 2.6.32-18 and 2.6.32-28, although I don't see anything obvious when grepping through all the patches.

It was also already working fine in 2.6.32-25, so I'm closing this with current-release.


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