The FDP team is no longer accepting new bugs in Bugzilla. Please report your issues under FDP project in Jira. Thanks.
Bug 1884646 - OVS IPsec using self-signed certificates on libreswan does not work
Summary: OVS IPsec using self-signed certificates on libreswan does not work
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux Fast Datapath
Classification: Red Hat
Component: openvswitch2.13
Version: RHEL 8.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: ---
Assignee: Mark Gray
QA Contact: qding
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-10-02 14:50 UTC by Mark Gray
Modified: 2021-05-20 19:30 UTC (History)
6 users (show)

Fixed In Version: openvswitch2.13-2.13.0-79.el8fdp
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-05-20 19:29:38 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2021:2083 0 None None None 2021-05-20 19:30:00 UTC

Description Mark Gray 2020-10-02 14:50:25 UTC
Description of problem:

OVS IPsec functionality does not work with libreswan when using self-signed certificates. 

When configuring OVS to use self-signed certificates for IPsec encryption, "ovs-pki" sets the CN of the cert to the name specified as part of the ovs-pki command: `ovs-pki req -u <name>`. However, when the "ovs-monitor-ipsec" daemon loads certificates and keys into libreswan, it prefixes the cert nickname with "ovs_cert" and "ovs_certkey" respectively. Which can be seen by running the command:

`$ sudo certutil -d sql:/etc/ipsec.d -L

Certificate Nickname                                         Trust Attributes
                                                             SSL,S/MIME,JAR/XPI

ovs_certkey_host_2                                           u,u,u
ovs_cert_host_1                                              P,P,P
`

The causes libreswan to fail when it tries to establish a tunnel with an error of the type:

pluto[1790412]: Failed to add connection "tun-1" with invalid "left" certificate
pluto[1790412]: failed to find certificate named 'host_2' in the NSS database

How reproducible:

Always

Steps to Reproduce:

Follow the tutorial at https://docs.openvswitch.org/en/latest/tutorials/ipsec/ using the section "2: Using self-signed certificate:"

Actual results:

Traffic is not encrypted.

Expected results:

Traffic is encrypted.

Comment 3 Timothy Redaelli 2021-03-16 13:07:44 UTC
openvswitch is openvswitch 2.9...
changing component to openvswitch2.13 (I also checked and it's already fixed on v2.15.0)

Comment 8 errata-xmlrpc 2021-05-20 19:29:38 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (openvswitch2.13 bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2021:2083


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