Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 943208 Details for
Bug 1147659
cyrus-sasl client library (client.c) is not thread safe
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
git patch file for cyrus-sasl-2.1.26
0001-Bug-1147659-cyrus-sasl-client-library-client.c-is-no.patch (text/plain), 1.76 KB, created by
Noriko Hosoi
on 2014-10-01 22:08:20 UTC
(
hide
)
Description:
git patch file for cyrus-sasl-2.1.26
Filename:
MIME Type:
Creator:
Noriko Hosoi
Created:
2014-10-01 22:08:20 UTC
Size:
1.76 KB
patch
obsolete
>From 3d48a475054911856b736ca2720b82f529dd68cf Mon Sep 17 00:00:00 2001 >From: Noriko Hosoi <nhosoi@redhat.com> >Date: Wed, 1 Oct 2014 14:20:27 -0700 >Subject: [PATCH] Bug 1147659 - cyrus-sasl client library (client.c) is not > thread safe > >Description: client_dispose (lib/clinet.c) which closes a connection >of a sasl client frees mech_list if the head of the list differs >from the head of the global cmechlist->mech_list. But there was a >possibility that the list appears in the middle of the global mech >list. By freeing the mech, it crashed a multi-threaded sasl client. > >This patch checks each mech if it is in the global mech list or not. >Only if it is not, the mech is freed. >--- > lib/client.c | 27 +++++++++++++++++++++++++++ > 1 file changed, 27 insertions(+) > >diff --git a/lib/client.c b/lib/client.c >index 31fe346..3f76483 100644 >--- a/lib/client.c >+++ b/lib/client.c >@@ -324,6 +324,26 @@ int sasl_client_init(const sasl_callback_t *callbacks) > return ret; > } > >+/* >+ * If mech is in cmechlist->mech_list, return 1 >+ * Otherwise, return 0 >+ */ >+static int mech_is_in_cmechlist(cmechanism_t *mech) >+{ >+ cmechanism_t *m = cmechlist->mech_list; >+ if (NULL == mech) { >+ return 0; >+ } >+ >+ while (m && mech) { >+ if (m == mech) { >+ return 1; >+ } >+ m = m->next; >+ } >+ return 0; >+} >+ > static void client_dispose(sasl_conn_t *pconn) > { > sasl_client_conn_t *c_conn=(sasl_client_conn_t *) pconn; >@@ -352,6 +372,13 @@ static void client_dispose(sasl_conn_t *pconn) > while (m) { > prevm = m; > m = m->next; >+ if (mech_is_in_cmechlist(prevm)) { >+ /* >+ * If prevm exists in the global mech_list cmechlist->mech_list, >+ * we should not free it as well as the rest of the list. >+ */ >+ break; >+ } > sasl_FREE(prevm); > } > } >-- >1.9.3 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 1147659
: 943208