<feed xmlns='http://www.w3.org/2005/Atom'>
<title>samba.git/source3/lib/util_sec.c, branch talloc-2.4.4</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/'/>
<entry>
<title>include &lt;grp.h&gt; for setgroups in a few places</title>
<updated>2025-01-02T17:58:50+00:00</updated>
<author>
<name>Michael Tokarev</name>
<email>mjt@tls.msk.ru</email>
</author>
<published>2024-11-29T06:34:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=5a560ba4896c34eca1b4c473bb140e24da650307'/>
<id>5a560ba4896c34eca1b4c473bb140e24da650307</id>
<content type='text'>
setgroups(), unlike getgroups(), is not in &lt;unistd.h&gt; but in &lt;grp.h&gt;.
Recent compilers require function declaration before using a function
(or more and more distributions treat lack of declaration as error),
so all configure-time tests fails with source3/lib/util_sec.c:

source3/../lib/util/setid.c: In function 'samba_setgroups':
source3/../lib/util/setid.c:244:16: error: implicit declaration of function \
  'setgroups'; did you mean 'getgroups'? [-Wimplicit-function-declaration]
  244 |         return setgroups(setlen, gidset);

Add the missing include so configuration finds the existing system
functions instead of failing.

Signed-off-by: Michael Tokarev &lt;mjt@tls.msk.ru&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Pavel Filipenský &lt;pfilipensky@samba.org&gt;

Autobuild-User(master): Pavel Filipensky &lt;pfilipensky@samba.org&gt;
Autobuild-Date(master): Thu Jan  2 17:58:50 UTC 2025 on atb-devel-224
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
setgroups(), unlike getgroups(), is not in &lt;unistd.h&gt; but in &lt;grp.h&gt;.
Recent compilers require function declaration before using a function
(or more and more distributions treat lack of declaration as error),
so all configure-time tests fails with source3/lib/util_sec.c:

source3/../lib/util/setid.c: In function 'samba_setgroups':
source3/../lib/util/setid.c:244:16: error: implicit declaration of function \
  'setgroups'; did you mean 'getgroups'? [-Wimplicit-function-declaration]
  244 |         return setgroups(setlen, gidset);

Add the missing include so configuration finds the existing system
functions instead of failing.

Signed-off-by: Michael Tokarev &lt;mjt@tls.msk.ru&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Pavel Filipenský &lt;pfilipensky@samba.org&gt;

Autobuild-User(master): Pavel Filipensky &lt;pfilipensky@samba.org&gt;
Autobuild-Date(master): Thu Jan  2 17:58:50 UTC 2025 on atb-devel-224
</pre>
</div>
</content>
</entry>
<entry>
<title>s3:lib: Fix code spelling</title>
<updated>2023-07-13T05:41:36+00:00</updated>
<author>
<name>Andreas Schneider</name>
<email>asn@samba.org</email>
</author>
<published>2023-07-05T09:16:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=71b40127e11c9b275f8e4049a40c5247d53b71f5'/>
<id>71b40127e11c9b275f8e4049a40c5247d53b71f5</id>
<content type='text'>
Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Martin Schwenke &lt;mschwenke@ddn.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Martin Schwenke &lt;mschwenke@ddn.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>lib: Improve comment wording</title>
<updated>2021-08-24T17:32:28+00:00</updated>
<author>
<name>Volker Lendecke</name>
<email>vl@samba.org</email>
</author>
<published>2021-08-17T15:10:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=8b45a42bc8b9c4efbbc7a4c64dd7fa599c3dccc4'/>
<id>8b45a42bc8b9c4efbbc7a4c64dd7fa599c3dccc4</id>
<content type='text'>
Signed-off-by: Volker Lendecke &lt;vl@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Volker Lendecke &lt;vl@samba.org&gt;
Reviewed-by: Jeremy Allison &lt;jra@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>s3:util_sec: fix the build on non-linux platforms</title>
<updated>2020-03-27T09:02:37+00:00</updated>
<author>
<name>Stefan Metzmacher</name>
<email>metze@samba.org</email>
</author>
<published>2019-11-06T07:47:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=1c0eed6ba7225fa6b655b3770228d2018fbeb3c4'/>
<id>1c0eed6ba7225fa6b655b3770228d2018fbeb3c4</id>
<content type='text'>
This fixes a regression introduced by
"util_sec.c: Move __thread variable to global scope"
(5a80f399b51221fb0b8661f30d940ca24e1ce627).

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes a regression introduced by
"util_sec.c: Move __thread variable to global scope"
(5a80f399b51221fb0b8661f30d940ca24e1ce627).

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>util_sec.c: Move __thread variable to global scope</title>
<updated>2019-09-17T12:31:40+00:00</updated>
<author>
<name>Khem Raj</name>
<email>raj.khem@gmail.com</email>
</author>
<published>2019-09-06T04:39:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=5a80f399b51221fb0b8661f30d940ca24e1ce627'/>
<id>5a80f399b51221fb0b8661f30d940ca24e1ce627</id>
<content type='text'>
Make clang happy otherwise it complains about variable scope

fixes

source3/./lib/util_sec.c:470:4: error: '__thread' variables must have global storage
        } __thread cache;
          ^

Signed-off-by: Khem Raj &lt;raj.khem@gmail.com&gt;
Reviewed-by: Matthias Dieter Wallnöfer &lt;mdw@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Make clang happy otherwise it complains about variable scope

fixes

source3/./lib/util_sec.c:470:4: error: '__thread' variables must have global storage
        } __thread cache;
          ^

Signed-off-by: Khem Raj &lt;raj.khem@gmail.com&gt;
Reviewed-by: Matthias Dieter Wallnöfer &lt;mdw@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>s3/lib: clean up have_syscall() formatting</title>
<updated>2019-01-28T23:29:17+00:00</updated>
<author>
<name>David Disseldorp</name>
<email>ddiss@samba.org</email>
</author>
<published>2019-01-26T23:41:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=f1b43dfe4a75683d881811bd0830e38e16822d6a'/>
<id>f1b43dfe4a75683d881811bd0830e38e16822d6a</id>
<content type='text'>
Signed-off-by: David Disseldorp &lt;ddiss@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: David Disseldorp &lt;ddiss@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>s3/lib: don't rely on implicit int return type</title>
<updated>2019-01-28T23:29:17+00:00</updated>
<author>
<name>David Disseldorp</name>
<email>ddiss@samba.org</email>
</author>
<published>2019-01-26T23:41:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=45a202a197d7615a6285768545a691cfb05deb22'/>
<id>45a202a197d7615a6285768545a691cfb05deb22</id>
<content type='text'>
C99 removed this behaviour.

Signed-off-by: David Disseldorp &lt;ddiss@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
C99 removed this behaviour.

Signed-off-by: David Disseldorp &lt;ddiss@samba.org&gt;
Reviewed-by: Andreas Schneider &lt;asn@samba.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>s3:lib: Do not redefine bool and use stdbool.h</title>
<updated>2018-11-22T21:13:27+00:00</updated>
<author>
<name>Andreas Schneider</name>
<email>asn@samba.org</email>
</author>
<published>2018-11-20T09:39:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=1642dc2fd4c3e89bab127c5c1d0b675d1c5cb6f9'/>
<id>1642dc2fd4c3e89bab127c5c1d0b675d1c5cb6f9</id>
<content type='text'>
Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Gary Lockyer &lt;gary@catalyst.net.nz&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Andreas Schneider &lt;asn@samba.org&gt;
Reviewed-by: Gary Lockyer &lt;gary@catalyst.net.nz&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>s3:util_sec: add a cache to set_thread_credentials()</title>
<updated>2018-07-24T18:35:17+00:00</updated>
<author>
<name>Stefan Metzmacher</name>
<email>metze@samba.org</email>
</author>
<published>2018-05-03T14:08:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=10fc65b74d7b94e0e6454c704b63c138d1d54bd1'/>
<id>10fc65b74d7b94e0e6454c704b63c138d1d54bd1</id>
<content type='text'>
Calling set_thread_credentials() with the same values,
skips syscalls the 2nd time.

We only do this if '__thread' is supported to provide
thread local storage.

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Ralph Boehme &lt;slow@samba.org&gt;

Autobuild-User(master): Ralph Böhme &lt;slow@samba.org&gt;
Autobuild-Date(master): Tue Jul 24 20:35:17 CEST 2018 on sn-devel-144
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Calling set_thread_credentials() with the same values,
skips syscalls the 2nd time.

We only do this if '__thread' is supported to provide
thread local storage.

Signed-off-by: Stefan Metzmacher &lt;metze@samba.org&gt;
Reviewed-by: Ralph Boehme &lt;slow@samba.org&gt;

Autobuild-User(master): Ralph Böhme &lt;slow@samba.org&gt;
Autobuild-Date(master): Tue Jul 24 20:35:17 CEST 2018 on sn-devel-144
</pre>
</div>
</content>
</entry>
<entry>
<title>lib/util: rename USE_LINUX_THREAD_CREDENTIALS to HAVE_LINUX_THREAD_CREDENTIALS</title>
<updated>2018-07-24T15:38:28+00:00</updated>
<author>
<name>Ralph Boehme</name>
<email>slow@samba.org</email>
</author>
<published>2018-06-28T12:28:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/samba.git/commit/?id=0d2eeb9422bf3fb3097637c63d9e7c8bd20417af'/>
<id>0d2eeb9422bf3fb3097637c63d9e7c8bd20417af</id>
<content type='text'>
The define reflects the results of a feature test, not a configure
option.

Signed-off-by: Ralph Boehme &lt;slow@samba.org&gt;
Reviewed-by: Stefan Metzmacher &lt;metze@samba.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The define reflects the results of a feature test, not a configure
option.

Signed-off-by: Ralph Boehme &lt;slow@samba.org&gt;
Reviewed-by: Stefan Metzmacher &lt;metze@samba.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
