lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 7 Oct 2021 00:35:14 +0300
From:   Leonard Crestez <>
To:     David Ahern <>, Jakub Kicinski <>,
        Shuah Khan <>, David Ahern <>
Cc:     "David S. Miller" <>,
        Ido Schimmel <>,
        Seth David Schoen <>,,,
Subject: Re: [PATCH 08/11] selftests: net/fcnal: Replace sleep after server
 start with -k

On 06.10.2021 17:54, David Ahern wrote:
> On 10/6/21 5:47 AM, Leonard Crestez wrote:
>> The -k switch makes the server fork into the background after the listen
>> call is succesful, this can be used to replace most of the `sleep 1`
>> statements in this script.
>> Change performed with a vim command:
>> s/nettest \(.*-s.*\) &\n\s*sleep 1\n/nettest \1 -k\r
>> Signed-off-by: Leonard Crestez <>
>> ---
>>   tools/testing/selftests/net/ | 641 ++++++++--------------
>>   1 file changed, 219 insertions(+), 422 deletions(-)
> I have a change from January [1] that runs the tests with 1 binary -
> takes both client and server side arguments, does the server setup,
> switches namespaces as needed and then runs the client side. I got
> bogged down validating the before and after which takes a long time
> given the number of tests. The output in verbose mode is as important as
> the pass / fail. Many of the tests document existing behavior as well as
> intended behavior.
> You used a search and replace to update the tests. Did you then do the
> compare of test results - not pass / fail but output?

I counted the [FAIL] or [ OK ] markers but not the output of nettest 
itself. I don't know what to look for, I guess I could diff the outputs?

Shouldn't it be sufficient to compare the exit codes of the nettest client?

The output is also modified by a previous change to not capture server 
output separately and instead let it be combined with that of the 
client. That change is required for this one, doing out=$(nettest -k) 
does not return on fork unless the pipe is also closed.

I did not look at your change, mine is relatively minimal because it 
only changes who decide when the server goes into the background: the 
shell script or the server itself. This makes it work very easily even 
for tests with multiple server instances.


Powered by blists - more mailing lists