| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Change-Id: Ia538c7177f8d5cf2c1f0efb5b575da6527c13968
|
|
|
|
| |
Change-Id: I77b8ca2c32b9ff33abb6acadae47f0ab47b47907
|
|
|
|
| |
Change-Id: I4b6f2e0015f8cfa18400fa4bd08460a07e29a51b
|
|
|
|
|
|
|
|
|
| |
uid_from_user doesn't need to cope with numeric ids in the BSD code
like it did with the old Android code; the caller now handles those.
Also explain what SUPPORT_DOT is for.
Change-Id: I185c9f02b7039795069aa30545563b8a6ef54cd5
|
|\ |
|
| |
| |
| |
| | |
Change-Id: I45381b8a04f4cb651123a2d43860418e06df6e65
|
|/
|
|
|
|
| |
bionic has getline now.
Change-Id: I5e4ee137768ab3113dbe8a07406fa39f4b6546af
|
|
|
|
|
|
| |
(<asm/page.h> is going away.)
Change-Id: Id0d7ad0eb791cd47490c48458f9f8a6468ddf5c9
|
|
|
|
|
|
|
| |
This depends on change I137588013ed1750315702c0dbe088ce3e4a29e83.
Change-Id: I5a4fef9affd6cddf98d72dc9d54899be25741779
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
libselinux selinux_android_restorecon API is changing to the more
general interface with flags and dropping the older variants.
Also get rid of the old, no longer used selinux_android_setfilecon API
and rename selinux_android_setfilecon2 to it as it is the only API in use.
Change-Id: I1e71ec398ccdc24cac4ec76f1b858d0f680f4925
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
|
|/
|
|
|
|
| |
We only have uapi headers now.
Change-Id: I2c02e10bb3bba4006579772f3ab2a18c2df7535d
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Extend the libselinux restorecon implementation to allow reuse
by the toolbox restorecon command. This simply requires adding
support for the nochange (-n) and verbose (-v) options to the
libselinux functions and rewriting the toolbox restorecon command
to use the libselinux functions. Also add a force (-F) option to
support forcing a restorecon_recursive even if the restorecon_last
attribute matches the current file_contexts hash so that we can
continue to force a restorecon via the toolbox command for testing
or when we know something else has changed (e.g. for when we support
relabeling /data/data and package information has changed).
Change-Id: I92bb3259790a7195ba56a5e9555c3b6c76ceb862
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
|
|
|
|
| |
Change-Id: I8332a0a8045a70b3992fe34b0b9e334a721265a9
|
|
|
|
| |
Change-Id: I643a48653006b97bb10d7b996ecc003dbafad590
|
|
|
|
|
|
|
|
|
| |
This cleans up most of the size-related problems in system/core.
There are still a few changes needed for a clean 64-bit build,
but they look like they might require changes to things like the
fastboot protocol.
Change-Id: I1560425a289fa158e13e2e3173cc3e71976f92c0
|
|
|
|
|
| |
Change-Id: I6f8ad2149244c89690d5d5caae8ec55429462210
Signed-off-by: Benoit Goby <benoit@android.com>
|
|
|
|
|
| |
Bug: 9336527
Change-Id: I77e2b05cefbfb4eebda39b4079107833f4160563
|
|
|
|
|
|
|
| |
commit 403b1955 clobbered the error message on lstat()
calls.
Change-Id: Idbd24b648e3a85079b8f8541c0798bf944485ca1
|
|
|
|
|
| |
Change-Id: I48c0fd1f4cffef936afb8d48d6d93babf006004d
Signed-off-by: Greg Hackmann <ghackmann@google.com>
|
|
|
|
|
| |
Change-Id: I810a9abee8bc0061c5007fe08197384f2b85754b
Signed-off-by: Greg Hackmann <ghackmann@google.com>
|
|
|
|
|
| |
Change-Id: Id7287ca179cc0b8390c054803a25a961dd550a34
Signed-off-by: Greg Hackmann <ghackmann@google.com>
|
|
|
|
|
| |
Change-Id: Id240ce85bf09e1a81f4e2e2a7496ac7952edbf38
Signed-off-by: Greg Hackmann <ghackmann@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use ssize_t for handling the result of a readlink call.
Fix the following compiler warning:
system/core/toolbox/ls.c: In function 'listfile_maclabel':
system/core/toolbox/ls.c:238:68: warning: unused parameter 'flags' [-Wunused-parameter]
static int listfile_maclabel(const char *path, struct stat *s, int flags)
Change-Id: Idd65f3349fb9dfb6f7a374c81f72d3169af33505
|
|
|
|
|
|
|
|
|
|
|
| |
Increase the size of the user/group buffer from 16 bytes
to 32 bytes. Some OEMs are creating usernames longer than
15 bytes, causing problems.
Use bounds checking functions when handling user/group
data, to avoid overflowing buffers.
Change-Id: I4a5824b819b0c37662ba4f33573af0d0e071b444
|
|\
| |
| |
| | |
Change-Id: I5c469a4b738629d99d721cad7ded02d6c35f56d5
|
| |
| |
| |
| | |
Change-Id: I4c2624d22ce879a3578d5b17440a9895b19e2f1f
|
| |
| |
| |
| | |
Change-Id: I693c1098e6c6d107a9e97285bf826ab153a1c8f0
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Move the liblog headers to log/ instead of cutils/ to complete
the separation of libcutils and liblog. cutils/log.h still
exists and includes log/log.h in order to support the many existing
modules that use cutils/log.h.
Change-Id: I2758c9f4aedcb809ca7ba8383d0f55041dd44345
|
| |\ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Add swap utilities (mkswap, swapon, swapoff) to the toolbox
Change-Id: If5ed6981670a1cdda6b528b587dbc1be7ccdf832
Signed-off-by: Rom Lemarchand <romlem@google.com>
|
| |\ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
When running with the -f option, do not stop recursion or proccessing
command line args if an error occurs. Continue trying to remove all
the items specified on the command line. However, still return an
error status if some files could not be removed.
Change-Id: I83d66babe833da8a68aad68248647ba0601c5d32
|
| |\ \ \
| | |/ /
| | | /
| | |/
| |/| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Now the -t option to the toolbox touch command takes a timestamp
in the form of YYYYMMDD.hhmmss
Change-Id: I3812700edaa1a06590a07c15b050721b49e9b7e0
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Internally, replace the watchlist array with a hashmap since the array
assumes properties are enumerated in a consistent order and foreach()
probably won't. (find_nth() never guaranteed this either but it usually
worked in practice.)
Change-Id: I83843facdd671edd09652edf472e88ec3d1edd3b
Signed-off-by: Greg Hackmann <ghackmann@google.com>
|
| |/
| |
| |
| | |
Change-Id: Ia6609116d641d3354971ca40a16ffcab38484150
|
| |\
| | |
| | |
| | |
| | |
| | |
| | | |
Send-Q columns"
* commit '603746f0e3b645954f33be36f7602cc8205cb71c':
Fixed reversed output in netstat Recv-Q Send-Q columns
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This has the potential to overflow "buffer" if the command line
is more than 4K.
Change-Id: Icdfed0d9d21804f290b75787ef3809e0475b14f0
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The third argument of strncat() tells how much data to append from
src, not the total size of the buffer.
Change uses of strncat() to strlcat(), which has the buffer overflow
protection behavior intended by the original author.
This fixes the following compiler warning:
In function 'strncat',
inlined from 'print_type' at system/core/toolbox/lsof.c:76:12:
bionic/libc/include/string.h:142:5: warning: call to __builtin___strncat_chk might overflow destination buffer [enabled by default]
Change-Id: Id69edc641de3cb87d1867a409cd57b04b12f90a7
|
| |\ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
When a filesystem is mounted read-only, make the underlying
block device read-only too. This helps prevent an attacker
who is able to change permissions on the files in /dev
(for example, symlink attack) from modifying the block device.
In particular, this change would have stopped the LG Thrill / Optimus
3D rooting exploit
(http://vulnfactory.org/blog/2012/02/26/rooting-the-lg-thrill-optimus-3d/)
as that exploit modified the raw block device corresponding to /system.
This change also makes UID=0 less powerful. Block devices cannot
be made writable again without CAP_SYS_ADMIN, so an escalation
to UID=0 by itself doesn't give full root access.
adb/mount: Prior to mounting something read-write, remove the
read-only restrictions on the underlying block device. This avoids
messing up developer workflows.
Change-Id: I135098a8fe06f327336f045aab0d48ed9de33807
|
| |\ \ \
| | |/ /
| |/| |
| | | |
| | | | |
* commit '4c1840e6547266ba251d8c34905036d73240ff57':
mount: fix incorrect string length calculation
|
| |\ \ \
| | | | |
| | | | |
| | | | |
| | | | | |
* commit '03546553205b56fc1ba0318b146971f43f54a155':
use lseek64 to resolve offset oveflow
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* commit '129b6d907b3c32a0f0a2e4fc585502484d47a1e4':
Add liblog
|
| |\ \ \ \ \
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
* commit 'd3859e433d5a4e0da3f24851c5f5f6c9c8b97849':
toolbox/dmesg: do not hardcode KLOG_BUF_LEN
|
| |\ \ \ \ \ \
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
* commit 'a7096004f220dd7578d7b2e26a3513fa5efc0fc1':
Add -i option to toolbox cmd ls
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Set the CAP_SYS_BOOT filesystem capability on the new reboot
command and keep CAP_SYS_BOOT in adb bounding set so that the
shell user can run it.
Change-Id: I1dd6143445ee2a952254f0452ab6e544318431dd
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Only check errno if unlink returns -1.
Continue instead of exiting if one file does not exist.
Change-Id: Iaf01b8523b84e87fcb0d732b89b7be6e24279c0b
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Bug: 11559337
Change-Id: I9795a16649dafdfe3df150170265157170cd5a79
|