Jeremy Allison | 1 Aug 2008 01:43
Picon
Favicon

Re: smbcontrol ping command

On Wed, Jul 30, 2008 at 05:46:15PM -0700, Herb Lewis wrote:
> with Samba-3.2.0 if you run
> 
>     smbcontrol smbd ping
> 
> you get responses from not only smbd but winbindd and nmbd as well.
> Not sure when this broke.
> 
> If you use winbindd or nmbd instead of smbd you only get a pong
> from the appropriate daemon.
> 
> I won't have time until Friday to look at this so if someone else
> has nothing to do ... :-)

Ok, tracked it down (not saying I have nothing to do mind :-).

In parse_dest() we have :

        /* Zero is a special return value for broadcast smbd */

        if (strequal(dest, "smbd")) {
                return interpret_pid(MSG_BROADCAST_PID_STR);
        }

which means for smbd it broadcasts to all processes, not
just the running smbd one.

In lib/messages there's a default "ping/pong" protocol
set up so all running processes that have set up their
messaging database will respond.
(Continue reading)

Jeremy Allison | 1 Aug 2008 02:38
Picon
Favicon

Re: Kerberos Ticket Forwarding Patch/Update (3.2)

On Mon, Jul 28, 2008 at 05:56:24PM -0400, Derrick Schommer wrote:
> Ah yes, forgot, samba probably actually compiles on a BE system. :) 

Use the following MACROs to convert native byte order to LE.

SSVAL(buf,pos,val) - put a 2 byte SMB value (val) into a buffer (buf) at position (pos)
SIVAL(buf,pos,val) - put a 4 byte SMB value (val) into a buffer (buf) at position (pos)

These are defined in include/byteorder.h and are what we
use for creating LE fields in the SMB protocol.

Jeremy.

Jeremy Allison | 1 Aug 2008 02:44
Picon
Favicon

Re: Kerberos Ticket Forwarding Patch/Update (3.2)

On Fri, Jul 25, 2008 at 03:14:56PM -0400, Derrick Schommer wrote:
> Here is the update with C-style comment fixes for 3.2 for the Kerberos
> update and the gss_init() updated to have the C_DELEGAT flag enabled. 

Ok, just looked this over and you can't use a struct
to create a memory block like that. There's no guarentee
of correct packing by the compiler and also as Love
pointed out this needs to be explicitly LE.

Take a look at the code in smbd/nttrans.c around line 384
for an example of how we manually do this for SMB/CIFS.
eg.

    384         p = (char *)req->outbuf + smb_vwv2;
    385         p++;
    386         SSVAL(p,0,pnum);
    387         p += 2;
    388         SIVAL(p,0,FILE_WAS_OPENED);
    389         p += 4;
    390         p += 32;
    391         SIVAL(p,0,FILE_ATTRIBUTE_NORMAL); /* File Attributes. */
    392         p += 20;
    393         /* File type. */
    394         SSVAL(p,0,FILE_TYPE_MESSAGE_MODE_PIPE);
    395         /* Device state. */
    396         SSVAL(p,2, 0x5FF); /* ? */
    397         p += 4;

Cheers,

(Continue reading)

Derrick Schommer | 1 Aug 2008 03:18
Favicon

Re: Kerberos Ticket Forwarding Patch/Update (3.2)

Okay, I¹ll see what I can do. As it is, it works, so if I implement it and
it breaks I know I¹m doing it wrong :) I wrote an internal CIFS client for
scale testing, I know the ³fun² behind SMB and padding. I was just turning
off auto alignment with compiler directives on my structures to get around
the non-byte aligned protocol.

I¹ll give this a go, hopefully tomorrow morning after some coffee.

Derrick

On 7/31/08 8:44 PM, "Jeremy Allison" <jra <at> samba.org> wrote:

> On Fri, Jul 25, 2008 at 03:14:56PM -0400, Derrick Schommer wrote:
>> > Here is the update with C-style comment fixes for 3.2 for the Kerberos
>> > update and the gss_init() updated to have the C_DELEGAT flag enabled.
> 
> Ok, just looked this over and you can't use a struct
> to create a memory block like that. There's no guarentee
> of correct packing by the compiler and also as Love
> pointed out this needs to be explicitly LE.
> 
> Take a look at the code in smbd/nttrans.c around line 384
> for an example of how we manually do this for SMB/CIFS.
> eg.
> 
>     384         p = (char *)req->outbuf + smb_vwv2;
>     385         p++;
>     386         SSVAL(p,0,pnum);
>     387         p += 2;
>     388         SIVAL(p,0,FILE_WAS_OPENED);
(Continue reading)

Herb Lewis | 1 Aug 2008 03:42
Favicon

wbinfo -D change in samba 3.2

In samba 3.0.30 the wbinfo -D <domain> command used to return the
sequence number as well. Samba 3.2.0 does not. I must have missed
when this was removed, was there a specific reason for this?

Karolin Seeger | 1 Aug 2008 13:20
Picon
Favicon

Re: [Release Planning 3.3] 3.3.0rc1 on August 19?

On Thu, Jul 31, 2008 at 07:14:40PM +0200, Volker Lendecke wrote:
> When do we switch the build farm?

After the release of 3.2.1? 

--

-- 
SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.SerNet.DE, mailto: Info  <at>  SerNet.DE

Volker Lendecke | 1 Aug 2008 15:00
Picon
Favicon

Re: [Release Planning 3.3] 3.3.0rc1 on August 19?

On Fri, Aug 01, 2008 at 01:20:05PM +0200, Karolin Seeger wrote:
> On Thu, Jul 31, 2008 at 07:14:40PM +0200, Volker Lendecke wrote:
> > When do we switch the build farm?
> 
> After the release of 3.2.1? 

Sounds good :-)

Volker
Volker Lendecke | 1 Aug 2008 15:16
Picon
Favicon

Re: Setting ACLs when creating files from Windows

On Thu, Jul 31, 2008 at 10:45:27PM +0200, Corinna Vinschen wrote:
> Sorry.  I attached now what happened when I cd'ed to the share for the
> first time.  I'm somewhat puzzled that the Windows user SID never shows
> up in the log.  Is it never transferred to the server?!?

No, only the name is at session setup time.

> > What does "rpcclient localhost -U% -c 'lookupnames corinna'"
> > say when run on the Samba box?
> 
> $ rpcclient localhost -U% -c 'lookupnames corinna'
> corinna S-1-22-1-500 (User: 1)

Ok, here we go. That's what you would have to set in the sd.

> > > How shall I know what UNIX user my Windows user is mapped to?  If
> > > smbusers contains a mapping like "foo = bar", and a UNIX user bar
> > > doesn't exist, how should I ever find out that I have to ask for a UNIX
> > > user foo?  Sure, winbind seems to solve this problem, but that works
> > > only for domains, not for standalone machines.
> 
> Oh and, even with winbind, there doesn't seem to be a way to map
> a Windows user to an arbitrary, already existing UNIX account.

?? Doesn't "username map" work for you?

> > Hmmm. Difficult. S-1-22-1-≤uid> should always work, but how
> > do you know your uid then? There's also a "lsa who am I"
> 
> I don't know my uid.  Not programatically.  I'm using the SID of the
(Continue reading)

Stefan (metze) Metzmacher | 1 Aug 2008 16:09
Picon
Favicon

Re: wbinfo -D change in samba 3.2

Herb Lewis schrieb:
> In samba 3.0.30 the wbinfo -D <domain> command used to return the
> sequence number as well. Samba 3.2.0 does not. I must have missed
> when this was removed, was there a specific reason for this?

the sequnce number is never correct, it was just used to say the domain
is online of offline. There's an "--online-status" option now.

metze

Derrick Schommer | 1 Aug 2008 20:59
Favicon

Update: Kerberos Ticket Forwarding Patch/Update [3.2]

Okay, I've updated the patch to include LE conversions using the macros'
supplied in byteorder.h, I've also taken out the structure copies and
replaced it with the byte-stream design seen in other areas of the samba
protocol builds. I've tested to make sure it didn't break with the
updates, and it all seems good.

When we've got all the issues and code reviews nailed down I'll send on
the 3.0 patch. I won't waste time sending extra emails until we're good
to go.

Thanks!

Derrick Schommer |  Corporate Systems Engineer 

F5 Networks 

  P 978.513.2900 

 F 978.513.2990

www.f5.com <http://www.f5.com>  

  D 978.513.2960 

 M 603.765.0012

Attachment (samba-3.2.patch): application/octet-stream, 8 KiB

Gmane