The branch, master has been updated
       via  941bb9b docs: Rename man ntlm_auth.
       via  29f90ec s3: Use dbwrap_parse_record in fetch_share_mode_unlocked
      from  cb0064d BUG 9436: Fix leaking sockets of SMB connections to a DC.

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 941bb9bb6dfd1c2dfd01696b2169e0782158ad6d
Author: Karolin Seeger <[email protected]>
Date:   Wed Nov 28 12:46:31 2012 +0100

    docs: Rename man ntlm_auth.
    
    Rename man ntlm_auth to ntlm_auth4.
    
    Karolin
    
    Reviewed-by: Andreas Schneider <[email protected]>
    
    Autobuild-User(master): Andreas Schneider <[email protected]>
    Autobuild-Date(master): Wed Nov 28 20:41:48 CET 2012 on sn-devel-104

commit 29f90ecf53c8cebe955d5bb6762c6fe6de008ff0
Author: Volker Lendecke <[email protected]>
Date:   Tue Nov 27 15:40:06 2012 +0100

    s3: Use dbwrap_parse_record in fetch_share_mode_unlocked
    
    Reviewed-by: Andreas Schneider <[email protected]>

-----------------------------------------------------------------------

Summary of changes:
 source3/locking/share_mode_lock.c                  |   27 ++++----
 .../man/{ntlm_auth.1.xml => ntlm_auth4.1.xml}      |   74 ++++++++++----------
 source4/utils/wscript_build                        |    2 +-
 3 files changed, 52 insertions(+), 51 deletions(-)
 rename source4/utils/man/{ntlm_auth.1.xml => ntlm_auth4.1.xml} (80%)


Changeset truncated at 500 lines:

diff --git a/source3/locking/share_mode_lock.c 
b/source3/locking/share_mode_lock.c
index a82c44e..4f26099 100644
--- a/source3/locking/share_mode_lock.c
+++ b/source3/locking/share_mode_lock.c
@@ -389,6 +389,15 @@ fail:
        return NULL;
 }
 
+static void fetch_share_mode_unlocked_parser(
+       TDB_DATA key, TDB_DATA data, void *private_data)
+{
+       struct share_mode_lock *lck = talloc_get_type_abort(
+               private_data, struct share_mode_lock);
+
+       lck->data = parse_share_modes(lck, data);
+}
+
 /*******************************************************************
  Get a share_mode_lock without locking the database or reference
  counting. Used by smbstatus to display existing share modes.
@@ -400,25 +409,17 @@ struct share_mode_lock 
*fetch_share_mode_unlocked(TALLOC_CTX *mem_ctx,
        struct share_mode_lock *lck;
        struct file_id tmp;
        TDB_DATA key = locking_key(&id, &tmp);
-       TDB_DATA data;
        NTSTATUS status;
 
-       status = dbwrap_fetch(lock_db, talloc_tos(), key, &data);
-       if (!NT_STATUS_IS_OK(status)) {
-               DEBUG(3, ("Could not fetch share entry\n"));
-               return NULL;
-       }
-       if (data.dptr == NULL) {
-               return NULL;
-       }
        lck = talloc(mem_ctx, struct share_mode_lock);
        if (lck == NULL) {
-               TALLOC_FREE(data.dptr);
+               DEBUG(0, ("talloc failed\n"));
                return NULL;
        }
-       lck->data = parse_share_modes(lck, data);
-       TALLOC_FREE(data.dptr);
-       if (lck->data == NULL) {
+       status = dbwrap_parse_record(
+               lock_db, key, fetch_share_mode_unlocked_parser, lck);
+       if (!NT_STATUS_IS_OK(status) ||
+           (lck->data == NULL)) {
                TALLOC_FREE(lck);
                return NULL;
        }
diff --git a/source4/utils/man/ntlm_auth.1.xml 
b/source4/utils/man/ntlm_auth4.1.xml
similarity index 80%
rename from source4/utils/man/ntlm_auth.1.xml
rename to source4/utils/man/ntlm_auth4.1.xml
index 09a8961..da187d7 100644
--- a/source4/utils/man/ntlm_auth.1.xml
+++ b/source4/utils/man/ntlm_auth4.1.xml
@@ -3,19 +3,19 @@
 <refentry id="ntlm-auth.1">
 
 <refmeta>
-       <refentrytitle>ntlm_auth</refentrytitle>
+       <refentrytitle>ntlm_auth4</refentrytitle>
        <manvolnum>1</manvolnum>
 </refmeta>
 
 
 <refnamediv>
-       <refname>ntlm_auth</refname>
+       <refname>ntlm_auth4</refname>
        <refpurpose>tool to allow external access to Winbind's NTLM 
authentication function</refpurpose>
 </refnamediv>
 
 <refsynopsisdiv>
        <cmdsynopsis>
-               <command>ntlm_auth</command>
+               <command>ntlm_auth4</command>
                <arg choice="opt">-d debuglevel</arg>
                <arg choice="opt">-l logdir</arg>
                <arg choice="opt">-s &lt;smb config file&gt;</arg>
@@ -28,10 +28,10 @@
        <para>This tool is part of the 
<citerefentry><refentrytitle>samba</refentrytitle>
        <manvolnum>7</manvolnum></citerefentry> suite.</para>
 
-       <para><command>ntlm_auth</command> is a helper utility that 
authenticates 
+       <para><command>ntlm_auth4</command> is a helper utility that 
authenticates
        users using NT/LM authentication. It returns 0 if the users is 
authenticated
-       successfully and 1 if access was denied. ntlm_auth uses winbind to 
access 
-       the user and authentication data for a domain.  This utility 
+       successfully and 1 if access was denied. ntlm_auth4 uses winbind to 
access
+       the user and authentication data for a domain.  This utility
        is only indended to be used by other programs (currently squid).
        </para>
 </refsect1>
@@ -44,7 +44,7 @@
     <manvolnum>8</manvolnum></citerefentry> daemon must be operational
     for many of these commands to function.</para>
 
-    <para>Some of these commands also require access to the directory 
+    <para>Some of these commands also require access to the directory
     <filename>winbindd_privileged</filename> in
     <filename>$LOCKDIR</filename>.  This should be done either by running
     this command as root or providing group access
@@ -62,7 +62,7 @@
        <term>--helper-protocol=PROTO</term>
        <listitem><para>
        Operate as a stdio-based helper.  Valid helper protocols are:
-        </para> 
+        </para>
         <variablelist>
              <varlistentry>
                <term>squid-2.4-basic</term>
@@ -81,9 +81,9 @@
              <varlistentry>
                <term>squid-2.5-ntlmssp</term>
                <listitem><para>
-                Server-side helper for use with Squid 2.5's NTLMSSP 
+                Server-side helper for use with Squid 2.5's NTLMSSP
                authentication. </para>
-                 <para>Requires access to the directory 
+                 <para>Requires access to the directory
                 <filename>winbindd_privileged</filename> in
                <filename>$LOCKDIR</filename>.  The protocol used is
                described here: <ulink
@@ -95,7 +95,7 @@
                <term>ntlmssp-client-1</term>
                <listitem><para>
                 Cleint-side helper for use with arbitary external
-               programs that may wish to use Samba's NTLMSSP 
+               programs that may wish to use Samba's NTLMSSP
                authentication knowlege. </para>
                  <para>This helper is a client, and as such may be run by any
                user.  The protocol used is
@@ -113,13 +113,13 @@
                subtle differences that are undocumented outside the
                source at this stage.
                 </para>
-                 <para>Requires access to the directory 
+                 <para>Requires access to the directory
                 <filename>winbindd_privileged</filename> in
-               <filename>$LOCKDIR</filename>.   
+               <filename>$LOCKDIR</filename>.
                </para>
                 </listitem>
                </varlistentry>
-                 
+
                <varlistentry>
                                <term>gss-spnego-client</term>
                <listitem><para>
@@ -132,15 +132,15 @@
        </variablelist>
        </listitem>
       </varlistentry>
-      
+
       <varlistentry>
        <term>--username=USERNAME</term>
        <listitem><para>
        Specify username of user to authenticate
        </para></listitem>
-       
+
       </varlistentry>
-      
+
       <varlistentry>
        <term>--domain=DOMAIN</term>
        <listitem><para>
@@ -173,7 +173,7 @@
 
        <varlistentry>
        <term>--password=PASSWORD</term>
-       <listitem><para>User's plaintext password</para><para>If 
+       <listitem><para>User's plaintext password</para><para>If
        not specified on the command line, this is prompted for when
        required.  </para></listitem>
        </varlistentry>
@@ -195,10 +195,10 @@
        or prompts for one.</para>
         </listitem>
         </varlistentry>
-       
+
        <varlistentry>
            <term>--require-membership-of={SID|Name}</term>
-           <listitem><para>Require that a user be a member of specified 
+           <listitem><para>Require that a user be a member of specified
            group (either name or SID) for authentication to succeed.</para>
            </listitem>
        </varlistentry>
@@ -209,36 +209,36 @@
 <refsect1>
        <title>EXAMPLE SETUP</title>
 
-        <para>To setup ntlm_auth for use by squid 2.5, with both basic and
+        <para>To setup ntlm_auth4 for use by squid 2.5, with both basic and
        NTLMSSP authentication, the following
        should be placed in the <filename>squid.conf</filename> file.
 <programlisting>
-auth_param ntlm program ntlm_auth --helper-protocol=squid-2.5-ntlmssp
-auth_param basic program ntlm_auth --helper-protocol=squid-2.5-basic
+auth_param ntlm program ntlm_auth4 --helper-protocol=squid-2.5-ntlmssp
+auth_param basic program ntlm_auth4 --helper-protocol=squid-2.5-basic
 auth_param basic children 5
 auth_param basic realm Squid proxy-caching web server
 auth_param basic credentialsttl 2 hours
 </programlisting></para>
 
-<note><para>This example assumes that ntlm_auth has been installed into your
+<note><para>This example assumes that ntlm_auth4 has been installed into your
       path, and that the group permissions on
       <filename>winbindd_privileged</filename> are as described 
above.</para></note>
 
-       <para>To setup ntlm_auth for use by squid 2.5 with group limitation in 
addition to the above
+       <para>To setup ntlm_auth4 for use by squid 2.5 with group limitation in 
addition to the above
        example, the following should be added to the 
<filename>squid.conf</filename> file.
 <programlisting>
-auth_param ntlm program ntlm_auth --helper-protocol=squid-2.5-ntlmssp 
--require-membership-of='WORKGROUP\Domain Users'
-auth_param basic program ntlm_auth --helper-protocol=squid-2.5-basic 
--require-membership-of='WORKGROUP\Domain Users'
+auth_param ntlm program ntlm_auth4 --helper-protocol=squid-2.5-ntlmssp 
--require-membership-of='WORKGROUP\Domain Users'
+auth_param basic program ntlm_auth4 --helper-protocol=squid-2.5-basic 
--require-membership-of='WORKGROUP\Domain Users'
 </programlisting></para>
-       
+
 </refsect1>
 
 <refsect1>
        <title>TROUBLESHOOTING</title>
-       
+
        <para>If you're experiencing problems with authenticating Internet 
Explorer running
-       under MS Windows 9X or Millenium Edition against ntlm_auth's NTLMSSP 
authentication
-       helper (--helper-protocol=squid-2.5-ntlmssp), then please read 
+       under MS Windows 9X or Millenium Edition against ntlm_auth4's NTLMSSP 
authentication
+       helper (--helper-protocol=squid-2.5-ntlmssp), then please read
        <ulink 
url="http://support.microsoft.com/support/kb/articles/Q239/8/69.ASP";>
        the Microsoft Knowledge Base article #239869 and follow instructions 
described there</ulink>.
        </para>
@@ -247,19 +247,19 @@ auth_param basic program ntlm_auth 
--helper-protocol=squid-2.5-basic --require-m
 <refsect1>
        <title>VERSION</title>
 
-       <para>This man page is correct for version 3.0 of the Samba 
+       <para>This man page is correct for version 3.0 of the Samba
        suite.</para>
 </refsect1>
 
 <refsect1>
        <title>AUTHOR</title>
-       
-       <para>The original Samba software and related utilities 
+
+       <para>The original Samba software and related utilities
        were created by Andrew Tridgell. Samba is now developed
-       by the Samba Team as an Open Source project similar 
+       by the Samba Team as an Open Source project similar
        to the way the Linux kernel is developed.</para>
-       
-       <para>The ntlm_auth manpage was written by Jelmer Vernooij and
+
+       <para>The ntlm_auth4 manpage was written by Jelmer Vernooij and
        Andrew Bartlett.</para>
 </refsect1>
 
diff --git a/source4/utils/wscript_build b/source4/utils/wscript_build
index 3b21eda..a5217b3 100644
--- a/source4/utils/wscript_build
+++ b/source4/utils/wscript_build
@@ -2,7 +2,7 @@
 
 bld.SAMBA_BINARY('ntlm_auth4',
                  source='ntlm_auth.c',
-                 manpages='man/ntlm_auth.1',
+                 manpages='man/ntlm_auth4.1',
                  deps='''samba-hostconfig samba-util popt
                  POPT_SAMBA POPT_CREDENTIALS gensec LIBCLI_RESOLVE
                  auth4 NTLMSSP_COMMON MESSAGING events service''',


-- 
Samba Shared Repository

Reply via email to