aboutsummaryrefslogtreecommitdiff
path: root/toys
AgeCommit message (Collapse)Author
2015-04-14Yet more ps work. Still not there yet.Rob Landley
2015-04-12unshare: fix -rSamuel Holland
Calling unshare(2) immediately puts us in the new namespace with the "overflow" user and group ID. By calling geteuid() and getegid() in handle_r() after calling unshare(), we try to map that to root, which Linux refuses to let us do. What we really want to map to root is the caller's uid/gid in the original namespace. So we have to save them before calling unshare().
2015-04-12Before trying to remount read only, see if block device responds to "become rw"Rob Landley
ioctl(). (This is a thing Android's old mount already does.)
2015-04-10Implement Android restorecon.Elliott Hughes
On Android, much of the restorecon logic is in libselinux, so this isn't portable. We do want to be able to build on the host for testing *other* toys, though, so #if keeps this building. Change-Id: Ida5a6713a926140c549d5770d62798f4aedca748
2015-04-10Fix load_policy error reporting.Elliott Hughes
Also switch to xopen for O_CLOEXEC paranoia and to avoid a conditional. Change-Id: Iee5c4c124bcac800313f586768ffcaade542bd22
2015-04-10getenforce takes no arguments.Elliott Hughes
Change-Id: Icbee1df8b316039c68ef326f9d4d80f32c603b21
2015-04-10setenforce takes exactly one argument.Elliott Hughes
Change-Id: I83c478ea9ddd456c61e3f0f99506a1028a7027a1
2015-04-10Make more(1) usable.Elliott Hughes
> Yes, I know, "don't use pending". Sadly, more(1) is pretty useless > without this. It gets confused by long lines or tabs. > > This patch also adds the missing prompt between multiple files. actually, it looks like we're already hard-coding some escape sequences? more(1) doesn't need anything that isn't in ANSI, so here's an alternative patch that fixes the same bugs as the other patch but also has a reverse-video prompt:
2015-04-08Revert last mdev commit because it copied code out of a GPLv2 program.Rob Landley
Guys, you CANNOT COPY CODE FROM BUSYBOX. I don't care if I was the initial author of that file, other people have touched it since. I know I added "pending" because I couldn't keep up with code review in realtime and stuff was getting lost, so we needed a place to park things before they underwent the full dorodango process. I also know none of the binaries I distribute has anything in pending enabled. But dude, if I'm going to find stuff like this I have to start reviewing the code BEFORE applying it to pending, and we all know where that leads. Please don't do this again.
2015-04-04To ensure that toybox can be installed alongside busybox withoutPaul Barker
confusing update-alternatives, the paths of the links installed by toybox should match those installed by busybox. This is accomplished by changing the flags of a few tools within toybox.
2015-04-04Another in-progress ps snapshot.Rob Landley
2015-04-03ps checkpoint du jour. Does not work yet.Rob Landley
2015-04-02Redoing ps from scratch. Random checkpoint that probably doesn't even compile.Rob Landley
Checking in a stopping point where I figured out what I did wrong, before changing it.
2015-03-29Fix head bug pointed out by felix janda (recent -123 code broke first file ↵Rob Landley
argument of -n).
2015-03-28Fix sed bug David Halls hit trying to compile libiconv.Rob Landley
2015-03-28Fix printf bug (%.s should be %.0s not %s) reported by Isabella Parakiss.Rob Landley
2015-03-27Promote setenforce to android.Rob Landley
2015-03-27Cleanup setenforce.Rob Landley
2015-03-27Promote getenforce.Rob Landley
2015-03-27Cleanup getenforce.Rob Landley
2015-03-27tail: add old -123 support and comment out #-f until it's actually implemented.Rob Landley
2015-03-27Promote load_policy to android.Rob Landley
2015-03-27Minor cleanup of load_policy.Rob Landley
2015-03-24Implement load_policy.Elliott Hughes
Note that this is a case where Android's tool isn't the same as the usual tool. Ours takes an explicit file containing the policy to be loaded. restorecon is at least command-line compatible, but the implementation is all in Android's libselinux where there's a selinux_android_restorecon function.
2015-03-23Promote runcon to android (and add an android menu).Rob Landley
2015-03-23Trivial runcon cleanups.Rob Landley
2015-03-23Add runcon(1).Elliott Hughes
2015-03-23add missing space in dd outputElliott Hughes
Also, coreutils says "s" instead of "seconds". POSIX specifies the format of the previous two lines, but doesn't even mention this line.
2015-03-21Another bug from David Halls: find -exec wasn't consuming its argument when ↵Rob Landley
it didn't activate. test: find . -name README -exec echo one '{}' ';' -or -exec echo two '{}' ';'
2015-03-21install -D bugfix from David Halls.Rob Landley
(I tweaked some comment text while I was there.)
2015-03-19Add -123 support to head (suggested by Elliott Hughes).Rob Landley
2015-03-18mdev : add hotplugin featureHyejin Kim
As internal needs, Ranjan Kumar (ranjankumar.bth at gmail.com) added hotplug feature into mdev.
2015-03-15I added error handling code in write_rotate().Hyejin Kim
I think that it is better to check tf->logfd before doing truncate()/write() and getting error.
2015-03-14More ps cleanup, mostly refactoring.Rob Landley
2015-03-13Minor ps refactoring.Rob Landley
2015-03-13Clean up sort help text.Rob Landley
Use tabs for option indent and don't have -g show up in menu (TOYBOX_FLOAT is the decision).
2015-03-12Switch nsenter to default y.Rob Landley
2015-03-12Implement shred -u and switch to default y in defconfig.Rob Landley
2015-03-12Remove cat -v help text debris.Rob Landley
2015-03-12The time command depends on floating point support.Rob Landley
2015-03-12Make find accept numeric uid/gid, and simplify makedevs using the new ↵Rob Landley
infrastructure.
2015-03-12Make install support numeric uid/gids (reported by Kylie McClain).Rob Landley
2015-03-12Factor out xgetgrnamid() and xgetpwnamid() into xwrap.c.Rob Landley
2015-03-11Fix mktemp when TMPDIR is set to empty string, reported by Kylie McClain.Rob Landley
2015-03-10Add -m to mknodRob Landley
2015-03-10Use xsignal() instead of signal().Rob Landley
2015-03-09Fix thinko (don't &toybuf to get scratch space) and add -v option.Rob Landley
2015-03-09Upgrade oneit with -r (restart), -3 (send exiting PID values to child), and ↵Rob Landley
signal handling.
2015-03-06sed depends on -r to be rightmost flag to simplify the REG_EXTENDED test.Rob Landley
(If a flag is 1, you can multiply it by the value you want and get that value else zero without a branch or conditional assignment.) So move -E one to the left so FLAG_r is 1 again, and add a [+Er] suffix instead of testing FLAG_r | FLAG_E in the users.
2015-03-03Quick cleanup pass on tar.Rob Landley