Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
shc
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
rx-etersoft
shc
Commits
36a16f19
Commit
36a16f19
authored
Oct 21, 2008
by
Ilya Mashkin
Committed by
Automatic Converter
Oct 21, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
3.8.6-alt1
- 3.8.6
parent
9f5c41e1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
58 additions
and
29 deletions
+58
-29
rules
.gear/rules
+0
-0
shc.spec
shc.spec
+5
-4
CHANGES
shc/CHANGES
+21
-0
shc
shc/shc
+0
-0
shc.c
shc/shc.c
+32
-25
No files found.
.gear
-
rules
→
.gear
/
rules
View file @
36a16f19
File moved
shc.spec
View file @
36a16f19
Name: shc
Version: 3.8.
3
Version: 3.8.
6
Release: alt1
Summary: Generic shell script compiler
License: GPL
Group: Development/Other
URL: http://www.datsi.fi.upm.es/~frosal/
Packager: Alex Yustasov <yust@altlinux.ru>
Packager: Ilya Mashkin <oddity@altlinux.ru>
Source0: %name-%version.tgz
Patch0: %name-3.7-makefile.patch
...
...
@@ -38,6 +36,9 @@ stripped binary executable. Use with care.
%_mandir/man?/*
%changelog
* Wed Oct 22 2008 Ilya Mashkin <oddity@altlinux.ru> 3.8.6-alt1
- 3.8.6
* Mon Jul 18 2005 Alex Yustasov <yust@altlinux.ru> 3.8.3-alt1
- 3.8.3
...
...
shc/CHANGES
View file @
36a16f19
CHANGES
3.8.6 Fri Jul 7 15:54:39 CEST 2006
Thanks to George Danchev <danchev@spnet.net> for:
- License clarification about the rc4 implementation.
3.8.5 Fri Oct 21 13:11:36 CEST 2005
Thanks to Jukka A. Ukkonen <jau(a)iki.fi> for:
- Fixed untraceable() problems on FreeBSD.
3.8.4 Tue Oct 4 16:52:15 CEST 2005
Thanks to Ron McOuat for:
- Fixed sma11 -d option bug.
3.8.3 Tue Jun 28 21:29:06 CEST 2005
Thanks to Jacek Kalinski <jacek@dyski.one.pl> for:
- Fixed bug: "vfork" fails on multiprocessor systems.
3.8.2 Thu Jun 16 17:15:59 CEST 2005
Thanks to Arjen Visser <arjen.visser@avisit.co.nz> for:
...
...
shc/shc
0 → 100755
View file @
36a16f19
File added
shc/shc.c
View file @
36a16f19
/* shc.c */
/**
* This software contains the 'Alleged RC4' source code.
* The original source code was published on the Net by a group of cypherpunks.
* I picked up a modified version from the news.
* The copyright notice does not apply to that code.
* This software contains an ad hoc version of the 'Alleged RC4' algorithm,
* which was anonymously posted on sci.crypt news by cypherpunks on Sep 1994.
*
* My implementation is a complete rewrite of the one found in
* an unknown-copyright (283 characters) version picked up from:
* From: allen@gateway.grumman.com (John L. Allen)
* Newsgroups: comp.lang.c
* Subject: Shrink this C code for fame and fun
* Date: 21 May 1996 10:49:37 -0400
* And it is licensed also under GPL.
*/
static
const
char
my_name
[]
=
"shc"
;
static
const
char
version
[]
=
"Version 3.8.
3
"
;
static
const
char
version
[]
=
"Version 3.8.
6
"
;
static
const
char
subject
[]
=
"Generic Script Compiler"
;
static
const
char
cpright
[]
=
"Copyright (c) 1994-200
5
"
;
static
const
char
cpright
[]
=
"Copyright (c) 1994-200
6
"
;
static
const
struct
{
const
char
*
f
,
*
s
,
*
e
;
}
author
=
{
"Francisco"
,
"Rosales"
,
"<frosal@fi.upm.es>"
};
...
...
@@ -95,7 +102,7 @@ static const char * help[] = {
#define SIZE 4096
static
char
*
file
;
static
double
date
[
1
];
static
time_t
date
[
1
];
static
char
*
mail
=
"Please contact your provider"
;
static
char
rlax
[
1
];
static
char
*
shll
;
...
...
@@ -126,13 +133,7 @@ static const char * RTC[] = {
"#include <time.h>"
,
"#include <unistd.h>"
,
""
,
"/**"
,
" * 'Alleged RC4' Source Code picked up from the news."
,
" * From: allen@gateway.grumman.com (John L. Allen)"
,
" * Newsgroups: comp.lang.c"
,
" * Subject: Shrink this C code for fame and fun"
,
" * Date: 21 May 1996 10:49:37 -0400"
,
" */"
,
"/* 'Alleged RC4' */"
,
""
,
"static unsigned char stte[256], indx, jndx, kndx;"
,
""
,
...
...
@@ -185,6 +186,8 @@ static const char * RTC[] = {
" }"
,
"}"
,
""
,
"/* End of ARC4 */"
,
""
,
"/*"
,
" * Key with file invariants. "
,
" */"
,
...
...
@@ -211,10 +214,10 @@ static const char * RTC[] = {
"}"
,
""
,
"#if DEBUGEXEC"
,
"void debugexec(char * sh
ll
, int argc, char ** argv)"
,
"void debugexec(char * sh
11
, int argc, char ** argv)"
,
"{"
,
" int i;"
,
" fprintf(stderr,
\"
shll=%s
\\
n
\"
, sh
ll ? shll
:
\"
<null>
\"
);"
,
" fprintf(stderr,
\"
shll=%s
\\
n
\"
, sh
11 ? sh11
:
\"
<null>
\"
);"
,
" fprintf(stderr,
\"
argc=%d
\\
n
\"
, argc);"
,
" if (!argv) {"
,
" fprintf(stderr,
\"
argv=<null>
\\
n
\"
);"
,
...
...
@@ -274,6 +277,10 @@ static const char * RTC[] = {
"#include <stdio.h>"
,
"#include <unistd.h>"
,
""
,
"#if !defined(PTRACE_ATTACH) && defined(PT_ATTACH)"
,
"# define PTRACE_ATTACH PT_ATTACH"
,
"#endif"
,
"void untraceable(char * argv0)"
,
"{"
,
" char proc[80];"
,
...
...
@@ -283,7 +290,11 @@ static const char * RTC[] = {
" case 0:"
,
" pid = getppid();"
,
" /* For problematic SunOS ptrace */"
,
" sprintf(proc,
\"
/proc/%d/as
\"
, (int)pid);"
,
"#if defined(__FreeBSD__)"
,
" sprintf(proc,
\"
/proc/%d/mem
\"
, (int)pid);"
,
"#else"
,
" sprintf(proc,
\"
/proc/%d/as
\"
, (int)pid);"
,
"#endif"
,
" close(0);"
,
" mine = !open(proc, O_RDWR|O_EXCL);"
,
" if (!mine && errno != EBUSY)"
,
...
...
@@ -529,13 +540,7 @@ static void parse_args(int argc, char * argv[])
}
}
/**
* 'Alleged RC4' Source Code picked up from the news.
* From: allen@gateway.grumman.com (John L. Allen)
* Newsgroups: comp.lang.c
* Subject: Shrink this C code for fame and fun
* Date: 21 May 1996 10:49:37 -0400
*/
/* 'Alleged RC4' */
static
unsigned
char
stte
[
256
],
indx
,
jndx
,
kndx
;
...
...
@@ -588,6 +593,8 @@ void arc4(void * str, int len)
}
}
/* End of ARC4 */
/*
* Key with file invariants.
*/
...
...
@@ -889,7 +896,7 @@ int write_C(char * file, char * argv[])
switch
(
indx
)
{
case
0
:
if
(
pswd_z
>=
0
)
{
prnt_array
(
o
,
pswd
,
"pswd"
,
pswd_z
,
0
);
pswd_z
=
done
=-
1
;
break
;}
case
1
:
if
(
msg1_z
>=
0
)
{
prnt_array
(
o
,
msg1
,
"msg1"
,
msg1_z
,
0
);
msg1_z
=
done
=-
1
;
break
;}
case
2
:
if
(
date_z
>=
0
)
{
prnt_array
(
o
,
date
,
"date"
,
date_z
,
"(
double
*)"
);
date_z
=
done
=-
1
;
break
;}
case
2
:
if
(
date_z
>=
0
)
{
prnt_array
(
o
,
date
,
"date"
,
date_z
,
"(
time_t
*)"
);
date_z
=
done
=-
1
;
break
;}
case
3
:
if
(
shll_z
>=
0
)
{
prnt_array
(
o
,
shll
,
"shll"
,
shll_z
,
0
);
shll_z
=
done
=-
1
;
break
;}
case
4
:
if
(
inlo_z
>=
0
)
{
prnt_array
(
o
,
inlo
,
"inlo"
,
inlo_z
,
0
);
inlo_z
=
done
=-
1
;
break
;}
case
5
:
if
(
xecc_z
>=
0
)
{
prnt_array
(
o
,
xecc
,
"xecc"
,
xecc_z
,
0
);
xecc_z
=
done
=-
1
;
break
;}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment