The Samba-Bugzilla – Attachment 5505 Details for
Bug 7253
Samba login-cache problem on Sparc Architecture
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Proposed patch
0001-s3-Fix-bug-7253.patch (text/plain), 1.55 KB, created by
Volker Lendecke
on 2010-03-16 15:11:21 UTC
(
hide
)
Description:
Proposed patch
Filename:
MIME Type:
Creator:
Volker Lendecke
Created:
2010-03-16 15:11:21 UTC
Size:
1.55 KB
patch
obsolete
>From e3a56d2d28b06d1e0b576248496e2032d6b5e2d0 Mon Sep 17 00:00:00 2001 >From: Volker Lendecke <vl@samba.org> >Date: Tue, 16 Mar 2010 21:03:34 +0100 >Subject: [PATCH] s3: Fix bug 7253 > >acct_ctrl is 32 bit in LOGIN_CACHE, but "w" as a format specifier for >tdb_unpack only writes 16 bits. Okay on x86, not okay on Solaris. > >Thanks to Vladimir.Marek@Sun.COM! > >Volker >--- > source3/passdb/login_cache.c | 9 ++++++++- > 1 files changed, 8 insertions(+), 1 deletions(-) > >diff --git a/source3/passdb/login_cache.c b/source3/passdb/login_cache.c >index 5630372..5adb24c 100644 >--- a/source3/passdb/login_cache.c >+++ b/source3/passdb/login_cache.c >@@ -69,6 +69,7 @@ LOGIN_CACHE * login_cache_read(struct samu *sampass) > TDB_DATA databuf; > LOGIN_CACHE *entry; > uint32_t entry_timestamp = 0, bad_password_time = 0; >+ uint16_t acct_ctrl; > > if (!login_cache_init()) > return NULL; >@@ -97,7 +98,7 @@ LOGIN_CACHE * login_cache_read(struct samu *sampass) > > if (tdb_unpack (databuf.dptr, databuf.dsize, SAM_CACHE_FORMAT, > &entry_timestamp, >- &entry->acct_ctrl, >+ &acct_ctrl, > &entry->bad_password_count, > &bad_password_time) == -1) { > DEBUG(7, ("No cache entry found\n")); >@@ -106,6 +107,12 @@ LOGIN_CACHE * login_cache_read(struct samu *sampass) > return NULL; > } > >+ /* >+ * Deal with 32-bit acct_ctrl. In the tdb we only store 16-bit >+ * ("w" in SAM_CACHE_FORMAT). Fixes bug 7253. >+ */ >+ entry->acct_ctrl = acct_ctrl; >+ > /* Deal with possible 64-bit time_t. */ > entry->entry_timestamp = (time_t)entry_timestamp; > entry->bad_password_time = (time_t)bad_password_time; >-- >1.6.0.4 >
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 Raw
Flags:
obnox
:
review+
Actions:
View
Attachments on
bug 7253
: 5505