summaryrefslogtreecommitdiffstats
path: root/tests/commands.sh
Commit message (Collapse)AuthorAgeFilesLines
* tests: add cases for testing fincore commandMasatake YAMATO2017-03-231-0/+1
| | | | Signed-off-by: Masatake YAMATO <yamato@redhat.com>
* lsmem: add testcaseHeiko Carstens2016-11-091-0/+1
| | | | | | | | | | Add a single s390 specific test case to verify that the contents of various output formats do not change in incompatible way if the lsmem code is changed. This is based on a patch from Clemens von Mann. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
* tests: add flock testsKarel Zak2016-10-311-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: Add helper for TIOCSTI exploitStanislav Brabec2016-09-291-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This helper/exploit injects "id -u -n\n" to the vulnerable calling terminal. Use id -u -n to get a reproducible output of test cases based on it. What can happen: Nothing, no exploit: pty is not accessible, sedsid() disconnected the task from pty, TIOCSTI failed. The command is injected to the unprivileged environment pty, and you see e. g. "nobody": This is acceptable. The command is injected to the caller (privileged) pty, and you see "root" (or caller uid name): This is not acceptable and has security implications. References: CVE-2016-2779 http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-2779 http://seclists.org/oss-sec/2016/q1/448 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=815922 https://bugzilla.redhat.com/show_bug.cgi?id=173008 https://bugzilla.suse.com/show_bug.cgi?id=968674 https://bugzilla.suse.com/show_bug.cgi?id=968675 CVE-2016-2781 http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-2781 http://seclists.org/oss-sec/2016/q1/452 Signed-off-by: Stanislav Brabec <sbrabec@suse.cz> Cc: Federico Bento <up201407890@alunos.dcc.fc.up.pt>
* tests: add libsmartcols title testKarel Zak2016-09-141-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libsmartcols: add application to test library featuresKarel Zak2016-09-131-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add chrt testKarel Zak2016-07-111-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add uuidd output checkSami Kerola2015-10-181-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add uuid parser checkSami Kerola2015-10-181-0/+1
| | | | | | | The check is based on code by Theodore Ts'o to test libuuid, from which unstable output is commented out. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add colcrt regression testsSami Kerola2015-08-101-0/+1
| | | | | | | Thanks to Alaa Mubaied for providing crash1 input file making colcrt to crash. The crash2 was generated using American Fuzzy Lop. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add way to control mkfs.minix time stampsSami Kerola2015-08-031-0/+1
| | | | | | | Needed in order to create reproducable file systems image files, so that out come of mkfs.minix can be checksum'ed. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add scriptreplay testSami Kerola2015-06-081-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: check script options work as expectedSami Kerola2015-06-061-0/+1
| | | | | | | Options --flush and --timing remain unchecked, as I do not have an idea how to check them reliably. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* libfdisk: (gpt) add API for raw partition attributesMichael Marineau2015-05-051-0/+1
| | | | | | | | | | | | | | | | | The existing APIs can only toggle individual bits or get and set bits in a complex text representation, making it impractical to use libfdisk for manipulating the GPT partition attribute field in more complex ways such as updating a value that is multiple bits wide. For example priority based partition selection originally designed for ChromeOS includes two integer values that are 4-bits wide. http://www.chromium.org/chromium-os/chromiumos-design-docs/disk-format#TOC-Trusting-the-GPT [kzak@redhat.com: - add new symbols to .sym file and docs - remove unused variables from test program] Signed-off-by: Michael Marineau <michael.marineau@coreos.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add test_dmesg that has fixed boot timeSami Kerola2015-03-231-1/+1
| | | | | | This allows testing time stamp formats. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: mount/move also tests findmnt vs. mountpointRuediger Meier2015-03-191-0/+1
| | | | Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
* logger: add -DTEST_LOGGERKarel Zak2015-03-161-0/+1
| | | | | | | | | | | | | | | | | | | | | | "make test_logger" now compiles logger(1) test program to overwrite system datetime stuff, hostname and PID, for example: export TZ=GMT export LOGGER_TEST_TIMEOFDAY=1234567890.123456 export LOGGER_TEST_HOSTNAME=foo export LOGGER_TEST_GETPID=123 ./test_logger --rfc5424 --no-act --stderr -i --tag MyTag mesg <13>1 2009-02-13T23:31:30.123456+00:00 foo MyTag 123 - [timeQuality tzKnown="1" isSynced="0"] mesg if the LOGGER_TEST_* variables are not specified then default to standard logger(1) behavior. Note that it would be possible to use for example "unshare --utc" to make hostname stable and portable, but LOGGER_TEST_* variables allow to keep the tests less complex. Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add blkdiscard offsets testFederico Simoncelli2014-10-271-0/+1
| | | | Signed-off-by: Federico Simoncelli <fsimonce@redhat.com>
* tests: add sfdisk testKarel Zak2014-10-071-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libs/debug: accept human readable names for _DEBUG=Ondrej Oprala2014-08-131-0/+1
| | | | | | | | | | For example $ LIBMOUNT_DEBUG=tab,cache findmnt to debug only TAB and CACHE subsystem. Signed-off-by: Ondrej Oprala <ooprala@redhat.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add rename(1) checksSami Kerola2014-07-181-0/+1
| | | | | | | | | Check basic file moves, symlink relinking, and both file moves and symlinks when operations are have directory in destination path. Reviewed-by: Ruediger Meier <sweet_f_a@gmx.de> Reviewed-by: Karel Zak <kzak@redhat.com> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: fix python tests for dist and out-of-tree buildsRuediger Meier2014-06-041-3/+3
| | | | | | | | | - add python helper scripts to the dist - helper scripts are always in srcdir - python libs are in builddir - abort tests if helpers are missing Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
* tests: remove test_fsck.cramfs (reverts 6c32ae78)Ruediger Meier2014-05-191-1/+1
| | | | Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
* tests: introduce TS_CMD_UUIDGEN (never use installed one)Ruediger Meier2014-05-131-0/+1
| | | | Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
* tests: check kill all user processesSami Kerola2014-04-261-1/+1
| | | | | CC: Bernhard Voelker <mail@bernhard-voelker.de> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: check kill is converting signals names correctlySami Kerola2014-04-261-0/+1
| | | | | CC: Bernhard Voelker <mail@bernhard-voelker.de> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add signal receiver programSami Kerola2014-04-261-0/+1
| | | | | | | Target to kill with a check that will be written later. CC: Bernhard Voelker <mail@bernhard-voelker.de> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: check swaplabel, and perform more swapon boundary testsSami Kerola2014-03-121-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add last(1) testSami Kerola2013-08-291-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* pylibmount: add regression testsOndrej Oprala2013-08-191-0/+3
| | | | | Signed-off-by: Ondrej Oprala <ooprala@redhat.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add losetup testsKarel Zak2013-05-131-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* wipefs: add --backupOndrej Oprala2013-04-261-0/+1
| | | | | | | | [kzak@redhat.com: - don't wipe if failed to create a backup file - use ts_scsi_debug_init in the regression tests] Signed-off-by: Ondrej Oprala <ooprala@redhat.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add partx regression testsOndrej Oprala2013-04-261-0/+2
| | | | Signed-off-by: Ondrej Oprala <ooprala@redhat.com>
* tests: sort commands stringsSami Kerola2013-01-251-62/+43Star
| | | | | | | The list is starting to be long enough that making any order to it seems like right thing to do. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add ipcmk(1) and ipcrm(1) checksSami Kerola2013-01-251-0/+2
| | | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add whereis(1) checkSami Kerola2013-01-251-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add isosize(1) checkSami Kerola2013-01-251-0/+1
| | | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add fallocate(1) checkSami Kerola2013-01-251-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add setarch(8) checkSami Kerola2013-01-251-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add setsid(1) checkSami Kerola2013-01-251-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add dmesg(1) checkSami Kerola2013-01-251-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add line(1) checkSami Kerola2013-01-251-0/+2
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add more(1) checkSami Kerola2013-01-241-0/+2
| | | | | | | [kzak@redhat.com: use test_more program rather than directly more(1)] Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add ionice(1) checkSami Kerola2013-01-241-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add ul(1) checkSami Kerola2013-01-241-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add tailf(1) checkSami Kerola2013-01-241-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add mcookie(1) checkSami Kerola2013-01-241-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add getopt(1) checkSami Kerola2013-01-241-0/+1
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add utmpdump(1) checkSami Kerola2013-01-241-0/+2
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add rev(1) checkSami Kerola2013-01-241-0/+1
| | | | | | | Fairly lenghty input line tries to ensure realloc segment in code is hit at least once. Signed-off-by: Sami Kerola <kerolasa@iki.fi>