|
|
1.1 root 1: /* Copyright Bell Telephone Laboratories Whippany, N.J.
2:
3: * /////////////////////////////////////
4: * /////////////////////////////////////
5: * ///////////// chksec.c //////////////
6: * /// J. P. Hawkins WH X4610 8C-001 ///
7: * ///// Wed May 6 18:59:40 1981 //////
8: * /////////////////////////////////////
9: * /////////////////////////////////////
10: * @(#) chksec.c: V1.1 6/17/81
11: * Check for security breaching characters like '|' and '&' and ';'
12: * for restricted command lines
13:
14: */
15:
16: chksec(s)
17: char s[];
18: {
19: register int i;
20:
21: for(i=0; s[i] != '\0'; i++)
22: if(s[i] == '&' || s[i] == '|' || s[i] == ';')
23: {
24: printf("DON'T BE ABSURD THIS IS A RESTRICTED PROGRAM\n");
25: return(-1);
26: }
27: return(0);
28: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.