Skip to content

Commit 32376b4

Browse files
committed
apply Merge pull request #83 from RKX1209/fix_nullptr_ref
2 parents 71ac875 + 1bde08a commit 32376b4

File tree

8 files changed

+148
-100
lines changed

8 files changed

+148
-100
lines changed

AUTHORS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
Francisco Garcia <frosal@fi.upm.es>
22
MD. JAHIDUL HAMID <jahidulhamid@yahoo.com>
3+
intika <intika@librefox.org>

ChangeLog

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
CHANGES
22

3+
4.0.3 Tue Nov 20 08:22:20 UTC 2018
4+
5+
* Enhance -H flag by intika <https://github.com/intika> (Hide commands arguments from ps and cmdline)
6+
* Remove -s flag (experimental feature not working as expected by intika <https://github.com/intika>)
7+
38
4.0.2 Mon 01 Jul 2019 02:57:36 PM UTC
49

510
* Fix typo
@@ -11,17 +16,17 @@ CHANGES
1116

1217
4.0.0 Mon Nov 12 16:54:56 UTC 2018
1318

14-
* Add -H option for extra security without root (Thanks to intika <https://github.com/intika>). It protects against dumping, code injection, `cat /proc/pid/cmdline`, ptrace, etc.. (only works with Bourne shell (sh) scripts with no parameter)
19+
* Add -H option for extra security without root (Thanks to intika <https://github.com/intika>). It protects against dumping, code injection, `cat /proc/pid/cmdline`, ptrace, etc.. (only works with Bourne shell (sh) scripts with no parameter)
1520
* Add -s option to force single process for hardening features (requires -H) <https://github.com/intika>. (only works with Bourne shell (sh) scripts with no parameter)
16-
* dash support
21+
* dash support
1722

1823
3.9.8 Sat Oct 20 17:49:28 UTC 2018
1924

20-
* Add setuid option -S (Thanks to Boon Pang <https://github.com/wombat78>)
25+
* Add setuid option -S (Thanks to Boon Pang <https://github.com/wombat78>)
2126

2227
3.9.7 Sat Oct 20 15:25:13 UTC 2018
2328

24-
* Fix issue #58
29+
* Fix issue #58
2530

2631
3.9.6 Sat Jun 3 10:05:03 UTC 2017
2732

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ shc [options]
3838
shc -f script.sh -o binary
3939
shc -U -f script.sh -o binary # Untraceable binary (prevent strace, ptrace etc..)
4040
shc -H -f script.sh -o binary # Untraceable binary, does not require root (only bourne shell (sh) scripts with no parameter)
41-
shc -H -s -f script.sh -o binary # Untraceable binary running in a singe process, does not require root (only bourne shell (sh) scripts with no parameter)
4241
```
4342

4443
## The hardening flag -H

configure

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#! /bin/sh
22
# Guess values for system-dependent variables and create Makefiles.
3-
# Generated by GNU Autoconf 2.69 for shc 4.0.1.
3+
# Generated by GNU Autoconf 2.69 for shc 4.0.3.
44
#
55
# Report bugs to <http://github.com/neurobin/shc/issues>.
66
#
@@ -580,8 +580,8 @@ MAKEFLAGS=
580580
# Identity of this package.
581581
PACKAGE_NAME='shc'
582582
PACKAGE_TARNAME='shc'
583-
PACKAGE_VERSION='4.0.1'
584-
PACKAGE_STRING='shc 4.0.1'
583+
PACKAGE_VERSION='4.0.3'
584+
PACKAGE_STRING='shc 4.0.3'
585585
PACKAGE_BUGREPORT='http://github.com/neurobin/shc/issues'
586586
PACKAGE_URL=''
587587

@@ -1279,7 +1279,7 @@ if test "$ac_init_help" = "long"; then
12791279
# Omit some internal or obsolete options to make the list less imposing.
12801280
# This message is too long to be a string in the A/UX 3.1 sh.
12811281
cat <<_ACEOF
1282-
\`configure' configures shc 4.0.1 to adapt to many kinds of systems.
1282+
\`configure' configures shc 4.0.3 to adapt to many kinds of systems.
12831283
12841284
Usage: $0 [OPTION]... [VAR=VALUE]...
12851285
@@ -1346,7 +1346,7 @@ fi
13461346

13471347
if test -n "$ac_init_help"; then
13481348
case $ac_init_help in
1349-
short | recursive ) echo "Configuration of shc 4.0.1:";;
1349+
short | recursive ) echo "Configuration of shc 4.0.3:";;
13501350
esac
13511351
cat <<\_ACEOF
13521352
@@ -1437,7 +1437,7 @@ fi
14371437
test -n "$ac_init_help" && exit $ac_status
14381438
if $ac_init_version; then
14391439
cat <<\_ACEOF
1440-
shc configure 4.0.1
1440+
shc configure 4.0.3
14411441
generated by GNU Autoconf 2.69
14421442
14431443
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1863,7 +1863,7 @@ cat >config.log <<_ACEOF
18631863
This file contains any messages produced by compilers while
18641864
running configure, to aid debugging if configure makes a mistake.
18651865
1866-
It was created by shc $as_me 4.0.1, which was
1866+
It was created by shc $as_me 4.0.3, which was
18671867
generated by GNU Autoconf 2.69. Invocation command line was
18681868
18691869
$ $0 $@
@@ -2733,7 +2733,7 @@ fi
27332733
27342734
# Define the identity of the package.
27352735
PACKAGE='shc'
2736-
VERSION='4.0.1'
2736+
VERSION='4.0.3'
27372737
27382738
27392739
cat >>confdefs.h <<_ACEOF
@@ -5311,7 +5311,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
53115311
# report actual input values of CONFIG_FILES etc. instead of their
53125312
# values after options handling.
53135313
ac_log="
5314-
This file was extended by shc $as_me 4.0.1, which was
5314+
This file was extended by shc $as_me 4.0.3, which was
53155315
generated by GNU Autoconf 2.69. Invocation command line was
53165316
53175317
CONFIG_FILES = $CONFIG_FILES
@@ -5368,7 +5368,7 @@ _ACEOF
53685368
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
53695369
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
53705370
ac_cs_version="\\
5371-
shc config.status 4.0.1
5371+
shc config.status 4.0.3
53725372
configured by $0, generated by GNU Autoconf 2.69,
53735373
with options \\"\$ac_cs_config\\"
53745374

configure.ac

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
AC_INIT([shc], [4.0.2], [http://github.com/neurobin/shc/issues])
1+
AC_INIT([shc], [4.0.3], [http://github.com/neurobin/shc/issues])
22
AC_CONFIG_AUX_DIR(config)
33
#prefix="/usr"
44
AC_CONFIG_SRCDIR([src/shc.c])

man.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
shc - Generic shell script compiler
88

99
# SYNOPSIS
10-
**shc** [ -e *date* ] [ -m *addr* ] [ -i *iopt* ] [ -x *cmnd* ] [ -l *lopt* ] [ -o *outfile* ] [ -ABCDhUHsvSr ] -f *script*
10+
**shc** [ -e *date* ] [ -m *addr* ] [ -i *iopt* ] [ -x *cmnd* ] [ -l *lopt* ] [ -o *outfile* ] [ -ABCDhUHvSr ] -f *script*
1111

1212
# DESCRIPTION
1313
**shc** creates a stripped binary executable version of the script specified with `-f` on the command line.
@@ -71,10 +71,7 @@ You can use it if you wish to distribute your scripts but don't want them to be
7171
: Make binary to be untraceable (using *strace*, *ptrace*, *truss*, etc.)
7272

7373
-H
74-
: Hardening. Extra security flag without root access requirement that protects against dumping, code injection, `cat /proc/pid/cmdline`, ptrace, etc.. This feature is **experimental** and may not work on all systems. This option currently only works with Bourne shell (sh) scripts without any positional parameters.
75-
76-
-s
77-
: Hardening with single process. Requires -H option, runs the binary in a single process, shell is called in the main process otherwise its called in a child process. This feature is **experimental** (may hang) and may not work on all systems. This option currently only works with Bourne shell (sh) scripts without any positional parameters.
74+
: Hardening. Extra security flag without root access requirement that protects against dumping, code injection, `cat /proc/pid/cmdline`, ptrace, etc.. This feature is **experimental** and may not work on all systems. it require bourne shell (sh) scripts
7875

7976
-C
8077
: Display license and exit

shc.1

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ shc \- Generic shell script compiler
66
.PP
77
\f[B]shc\f[] [ \-e \f[I]date\f[] ] [ \-m \f[I]addr\f[] ] [ \-i
88
\f[I]iopt\f[] ] [ \-x \f[I]cmnd\f[] ] [ \-l \f[I]lopt\f[] ] [ \-o
9-
\f[I]outfile\f[] ] [ \-ABCDhUHsvSr ] \-f \f[I]script\f[]
9+
\f[I]outfile\f[] ] [ \-ABCDhUHvSr ] \-f \f[I]script\f[]
1010
.SH DESCRIPTION
1111
.PP
1212
\f[B]shc\f[] creates a stripped binary executable version of the script
@@ -86,15 +86,7 @@ Extra security flag without root access requirement that protects
8686
against dumping, code injection, \f[C]cat\ /proc/pid/cmdline\f[],
8787
ptrace, etc..
8888
This feature is \f[B]experimental\f[] and may not work on all systems.
89-
This option currently only works with Bourne shell (sh) scripts without
90-
any positional parameters.
91-
.PP
92-
\-s : Hardening with single process.
93-
Requires \-H option, runs the binary in a single process, shell is
94-
called in the main process otherwise its called in a child process.
95-
This feature is \f[B]experimental\f[] (may hang) and may not work on all
96-
systems.
97-
This option currently only works with Bourne shell (sh) scripts without
89+
it require bourne shell (sh) scripts
9890
any positional parameters.
9991
.PP
10092
\-C : Display license and exit
@@ -147,6 +139,8 @@ limited by the operating system configuration parameter
147139
.PP
148140
Francisco Rosales <frosal@fi.upm.es>
149141
.PP
142+
intika <intika@librefox.org>
143+
.PP
150144
Md Jahidul Hamid <jahidulhamid@yahoo.com>
151145
.SH REPORT BUGS TO
152146
.PP

0 commit comments

Comments
 (0)