Enable ccache use in libsmbclient by default?

Derrell Lipman derrell.lipman at unwireduniverse.com
Mon Jan 25 06:53:02 MST 2010


On Sun, Jan 24, 2010 at 17:15, Volker Lendecke <Volker.Lendecke at sernet.de>wrote:

>
> With 4eb1523d87 (and the preceding commits) libsmbclient now
> has the ability to use the winbind ccache for ntlmssp
> authentications. Right now this must be activated with
> smbc_setOptionUseCCache, so applications not aware of it
> will not benefit from it.
>
> I would like to enable this by default, I think this can be
> pretty handy. But that is a change in behaviour.
>
> Any objections?
>

Volker, does ccache impose a start-up penalty? Some libsmbclient
applications are "one-shots"; they start-up, do their thing, and then exit.
I'm not sure we'd want to impose a start-up penalty on those apps.

In any case, this could be configured by a parameter in the global smb.conf
and, specifically for libsmbclient, on a per-user basis in ~/.smb/smb.conf
(a replacement for the global one) or ~/.smb/smb.conf.append (applies after
applying the global one). smbc_setOptionUseCCache() could be called with the
value read from the config file, as is done in libsmb/libsmb_context.c for
the workgroup:

                char *workgroup;

                if (lp_workgroup()) {
                        workgroup = SMB_STRDUP(lp_workgroup());
                }
                ...
                smbc_setWorkgroup(context, workgroup);

Derrell


More information about the samba-technical mailing list