ALT Linux kernel packages development
 help / color / mirror / Atom feed
From: Vitaly Chikunov <vt@altlinux.org>
To: ALT Linux kernel packages development <devel-kernel@lists.altlinux.org>
Subject: Re: [d-kernel] [PATCH v5] AltHa: handle setcap binaries in the same way as setuid ones
Date: Wed, 1 Jun 2022 04:06:13 +0300
Message-ID: <20220601010613.2pppdma263ps2pxn@altlinux.org> (raw)
In-Reply-To: <Ypaa/0VAT4jjw+9V@portlab>

Vladimir,

On Wed, Jun 01, 2022 at 01:47:27AM +0300, Vladimir D. Seleznev wrote:
> On Tue, May 31, 2022 at 09:45:03AM +0300, Dmitry V. Levin wrote:
> > On Tue, May 31, 2022 at 12:28:19AM +0300, Vladimir D. Seleznev wrote:
> > > On Mon, May 30, 2022 at 06:45:09PM +0300, Dmitry V. Levin wrote:
> > > > On Mon, May 30, 2022 at 06:24:12PM +0300, Vladimir D. Seleznev wrote:
> > > > > On Mon, May 30, 2022 at 06:11:25PM +0300, Vitaly Chikunov wrote:
> > > > [...]
> > > > > > What about tests?
> > > > > 
> > > > > I'm not ready to put efforts for tests at this moment. Please apply the
> > > > > patch, the tests can be a future work for this module.
> > > > 
> > > > In the absence of tests, how can we make sure the new feature works properly?
> > > 
> > > I tested it. The tests are good, but how do you know they are correct? I
> > > don't mind to write tests but not now.
> > 
> > Tests are crucial in proving that new features work properly.
> > In some projects, e.g. strace, a new feature is not merged
> > until accompanied with a proper test.
> > 
> > What's stopping you from supplying a test now?
> 
> I'm not an expert in kernel tests framework, so I need to involve time
> to learn it.

You'll be disappointed be the kernel test framework. Basically it's just
convention to print in TAP format. So for shell scripts you're on your
own. And I'm suggesting you to write just a simple and understandable
test shell script. Kiosk test is just an example of such script and not
"framework" suggestion. It's as suitable as bash.

Only properties we need for such test script it that it's easily runnable,
understandable, and cover positive and negative cases.

I will run it at least once. Perhaps, no need to run it on every kernel
build, but it's possible, since we run some LTP tests anyway, it'll
depend on how heavy the test is. Testers can run it too (if they wish).

You don't need to integrate it into kselftests, since we don't run it
anyway, and upstream will not run your tests either, so why bother?
Simple literate bash script is enough.

> vt@ suggested taking as an example kiosk test, but as far
> as I understand it does not use kernel test facility, instead it is
> written independently, and it poorly suitable for altha nosuid
> functionality. Besides, the kiost test does not run during build process
> (correct me if I'm wrong), so its presence does not make things any
> better.

Perhaps, more people should be able to understand what test does than
what LSM code does. So the test is supposed to increase confidence in
nosuid feature, and show there's no regressions anywhere in the future
we wish to be reassured.

The test will not "make things any better" if you absolutely confident
in flawlessness of your code.

Thanks,

> 
> AltHa code is almost stand-alone and does not change any part of the
> vanilla kernel. I think if it does not work as expected, users will
> report that (and I use it).
> 
> -- 
>    WBR,
>    Vladimir D. Seleznev
> _______________________________________________
> devel-kernel mailing list
> devel-kernel@lists.altlinux.org
> https://lists.altlinux.org/mailman/listinfo/devel-kernel


  reply	other threads:[~2022-06-01  1:06 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-23 13:44 Vladimir D. Seleznev
2022-05-30 11:48 ` Vladimir D. Seleznev
2022-05-30 15:11   ` Vitaly Chikunov
2022-05-30 15:24     ` Vladimir D. Seleznev
2022-05-30 15:45       ` Dmitry V. Levin
2022-05-30 21:28         ` Vladimir D. Seleznev
2022-05-31  6:45           ` Dmitry V. Levin
2022-05-31 22:47             ` Vladimir D. Seleznev
2022-06-01  1:06               ` Vitaly Chikunov [this message]
2022-05-30 17:08 ` Andrey Savchenko
2022-05-30 21:29   ` Vladimir D. Seleznev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220601010613.2pppdma263ps2pxn@altlinux.org \
    --to=vt@altlinux.org \
    --cc=devel-kernel@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux kernel packages development

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/devel-kernel/0 devel-kernel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 devel-kernel devel-kernel/ http://lore.altlinux.org/devel-kernel \
		devel-kernel@altlinux.org devel-kernel@altlinux.ru devel-kernel@altlinux.com
	public-inbox-index devel-kernel

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.devel-kernel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git