Bug 1142669 - EAP-TLS and OCSP validation causing segmentation fault + patch
Summary: EAP-TLS and OCSP validation causing segmentation fault + patch
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: freeradius
Version: 6.5
Hardware: All
OS: Linux
Target Milestone: rc
: ---
Assignee: Nikolai Kondrashov
QA Contact: Jaroslav Aster
Depends On:
TreeView+ depends on / blocked
Reported: 2014-09-17 07:55 UTC by Michal Bruncko
Modified: 2015-07-22 06:16 UTC (History)
5 users (show)

Fixed In Version: freeradius-2.2.6-1.el6
Doc Type: Bug Fix
Doc Text:
During the Online Certificate Status Protocol (OCSP) validation, radiusd terminated unexpectedly with a segmentation fault after attempting to access the next update field that was not provided by the OCSP responder. Now, radiusd does not crash in this situation and instead continues to complete the OCSP validation.
Clone Of:
Last Closed: 2015-07-22 06:16:53 UTC

Attachments (Terms of Use)
fixing patch (723 bytes, patch)
2014-09-17 07:55 UTC, Michal Bruncko
no flags Details | Diff

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1287 normal SHIPPED_LIVE Moderate: freeradius security, bug fix, and enhancement update 2015-07-20 17:48:53 UTC

Description Michal Bruncko 2014-09-17 07:55:14 UTC
Created attachment 938373 [details]
fixing patch

Description of problem:
- within EAP-TLS authentication, and 
- if OCSP validation is enabled, and
- OCSP responder does not set the next update field
freeradius crashed with segmentation fault

- this issue is already registered under https://bugzilla.redhat.com/show_bug.cgi?id=890569 for older RHEL release.
- bug is still present in current version of freeradius

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

How reproducible:

Additional info:
radiusd debug output:

[wifi-devices] Request found, released from the list
[wifi-devices] EAP/tls
[wifi-devices] processing type tls
[tls] Authenticate
[tls] processing EAP-TLS
[tls] eaptls_verify returned 7
[tls] Done initial handshake
[tls] <<< TLS 1.0 Handshake [length 0352], Certificate
[tls] chain-depth=2,
[tls] error=0
[tls] --> User-Name = tablet2.example.com
[tls] --> BUF-Name = Example organization Root CA
[tls] --> subject = /CN=Example organization Root CA/O=Example organization/C=SK
[tls] --> issuer  = /CN=Example organization Root CA/O=Example organization/C=SK
[tls] --> verify return:1
[tls] chain-depth=1,
[tls] error=0
[tls] --> User-Name = tablet2.example.com
[tls] --> BUF-Name = Example organization - Devices CA
[tls] --> subject = /CN=Example organization - Devices CA
[tls] --> issuer  = /CN=Example organization Root CA/O=Example organization/C=SK
[tls] --> verify return:1
[tls] --> Starting OCSP Request
[ocsp] --> Responder URL = http://ocsp.example.com:80/ejbca/publicweb/status/ocsp
[ocsp] --> Response status: successful
        This Update: Sep 16 17:45:06 2014 GMT
Segmentation fault

Comment 1 Michal Bruncko 2014-09-17 07:56:31 UTC
Comment on attachment 938373 [details]
fixing patch

affected part extracted from commit https://github.com/FreeRADIUS/freeradius-server/commit/dc53285b1d660737717d88da14edf73813cabd0f

Comment 3 Nikolai Kondrashov 2014-09-17 08:09:57 UTC
Thank you very much for the report and the patch, Michal. I'll see if we can get it into RHEL6.6.

Comment 4 Nikolai Kondrashov 2014-09-17 11:37:57 UTC
Unfortunately, we're too late for RHEL6.6, so this fix will have to go into RHEL6.7. If you still would like to have this fixed in RHEL6.6 please contact support.

Comment 5 Michal Bruncko 2014-09-17 13:29:29 UTC
not problem at all. even if it could be included in RHEL6.7 it will be fine. just wanted to confirm that with patch above SIGSEGV not occur withing OCSP verification and radiusd is stable.

Comment 13 errata-xmlrpc 2015-07-22 06:16:53 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, and where to find the updated
files, follow the link below.

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


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