<feed xmlns='http://www.w3.org/2005/Atom'>
<title>passt, branch 2023_05_09.96f8d55</title>
<subtitle>Plug A Simple Socket Transport</subtitle>
<link rel='alternate' type='text/html' href='https://passt.top/passt/'/>
<entry>
<title>correct -6 option in manpage</title>
<updated>2023-05-09T21:29:32+00:00</updated>
<author>
<name>lemmi</name>
<email>lemmi@nerd2nerd.org</email>
</author>
<published>2023-05-08T16:05:01+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=96f8d55c4f5093fa59c168361c0428b53b6d2d06'/>
<id>96f8d55c4f5093fa59c168361c0428b53b6d2d06</id>
<content type='text'>
Signed-off-by: lemmi &lt;lemmi@nerd2nerd.org&gt;
Reviewed-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: lemmi &lt;lemmi@nerd2nerd.org&gt;
Reviewed-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>passt: Fix error check for signal(), improve error messages</title>
<updated>2023-04-13T17:32:13+00:00</updated>
<author>
<name>Stefano Brivio</name>
<email>sbrivio@redhat.com</email>
</author>
<published>2023-04-13T17:32:13+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=940bd3eff922c46ac280136e3674ee70ea40f08e'/>
<id>940bd3eff922c46ac280136e3674ee70ea40f08e</id>
<content type='text'>
Valtteri reports that if SIGPIPE already has a disposition set by the
parent process, such as systemd with the default setting of
IgnoreSIGPIPE=yes, signal() will return the previous value, not zero,
and this is not an error: check for SIG_ERR instead.

While at it, split messages for failures of sigaction() and signal(),
and report the actual error.

Reported-by: Valtteri Vuorikoski &lt;vuori@notcom.org&gt;
Fixes: 8534be076c73 ("Catch failures when installing signal handlers")
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Valtteri reports that if SIGPIPE already has a disposition set by the
parent process, such as systemd with the default setting of
IgnoreSIGPIPE=yes, signal() will return the previous value, not zero,
and this is not an error: check for SIG_ERR instead.

While at it, split messages for failures of sigaction() and signal(),
and report the actual error.

Reported-by: Valtteri Vuorikoski &lt;vuori@notcom.org&gt;
Fixes: 8534be076c73 ("Catch failures when installing signal handlers")
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nstool: Enter holder's cwd when changing mount ns with nstool exec</title>
<updated>2023-04-07T23:12:12+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:19+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=1a3ade90371f7e9490e8f3be0aff83f2e178c327'/>
<id>1a3ade90371f7e9490e8f3be0aff83f2e178c327</id>
<content type='text'>
If we enter a mount namespace with nstool exec our working directory will
be changed to / in the new mount ns.  This is surprising if we haven't
actually altered any mounts yet in the new ns.  Instead, change the working
directory to match that of the holder process in this situation.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If we enter a mount namespace with nstool exec our working directory will
be changed to / in the new mount ns.  This is surprising if we haven't
actually altered any mounts yet in the new ns.  Instead, change the working
directory to match that of the holder process in this situation.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nstool: Advertise the holder's cwd (in its mountns) across the socket</title>
<updated>2023-04-07T23:12:10+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:18+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=98031bee73b30ec82a4bc5f078175061d6157b4f'/>
<id>98031bee73b30ec82a4bc5f078175061d6157b4f</id>
<content type='text'>
This is possible useful in nstool info and has further uses for nstool
exec.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is possible useful in nstool info and has further uses for nstool
exec.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: Use "nstool exec" to slightly simplify tests</title>
<updated>2023-04-07T23:12:08+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:17+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=469b69aaa141a8163a6930e2dd4a25272a85d146'/>
<id>469b69aaa141a8163a6930e2dd4a25272a85d146</id>
<content type='text'>
Using this, rather than using "nstool info" to get the pid then manually
connecting with nsenter makes things a little simpler.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Using this, rather than using "nstool info" to get the pid then manually
connecting with nsenter makes things a little simpler.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: Initialise ${TRACE} properly</title>
<updated>2023-04-07T23:12:05+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:16+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=3372cd0902f262b591ecb930a12d0049e69ac372'/>
<id>3372cd0902f262b591ecb930a12d0049e69ac372</id>
<content type='text'>
Unlike ${DEBUG} we don't initialize ${TRACE} to 0 if not set, which cases
failures when testing it later.  That failure acts as though it is false,
however it emits spurious errors in script.log, which can make it harder to
spot real errors.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Unlike ${DEBUG} we don't initialize ${TRACE} to 0 if not set, which cases
failures when testing it later.  That failure acts as though it is false,
however it emits spurious errors in script.log, which can make it harder to
spot real errors.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nstool: Add --keep-caps option to nstool exec</title>
<updated>2023-04-07T23:12:03+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:15+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=329149d51a7f8132beefcafc688812e2926607e1'/>
<id>329149d51a7f8132beefcafc688812e2926607e1</id>
<content type='text'>
This allows you to run commands within a user namespace with the
privilege that comes from owning that userns.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This allows you to run commands within a user namespace with the
privilege that comes from owning that userns.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nstool: Add nstool exec command to execute commands in an nstool namespace</title>
<updated>2023-04-07T23:12:01+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:14+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=0b669446482e110719b3935aa4819396dea4d1ab'/>
<id>0b669446482e110719b3935aa4819396dea4d1ab</id>
<content type='text'>
This combines nstool info -pw &lt;sock&gt; with nsenter with various options for
a more convenient and less verbose of entering existing nstool managed
namespaces.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This combines nstool info -pw &lt;sock&gt; with nsenter with various options for
a more convenient and less verbose of entering existing nstool managed
namespaces.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nstool: Helpers to iterate through namespace types</title>
<updated>2023-04-07T23:11:59+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:13+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=3bcbca5db8547142df54debbe3ca2aba9e807b9c'/>
<id>3bcbca5db8547142df54debbe3ca2aba9e807b9c</id>
<content type='text'>
Will make things a bit less verbose in future.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Will make things a bit less verbose in future.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nstool: Add magic number to advertized information</title>
<updated>2023-04-07T23:11:57+00:00</updated>
<author>
<name>David Gibson</name>
<email>david@gibson.dropbear.id.au</email>
</author>
<published>2023-04-06T03:28:12+00:00</published>
<link rel='alternate' type='text/html' href='https://passt.top/passt/commit/?id=f6a9ea3af5384ac561b67494073d520145ae2281'/>
<id>f6a9ea3af5384ac561b67494073d520145ae2281</id>
<content type='text'>
So that we'll probably give a better error if you point it at something
that's not an nstool hold control socket.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
So that we'll probably give a better error if you point it at something
that's not an nstool hold control socket.

Signed-off-by: David Gibson &lt;david@gibson.dropbear.id.au&gt;
Signed-off-by: Stefano Brivio &lt;sbrivio@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
