Heres a new code
New Page 1
//************************************** //INCLUDE files for :crypt.c
//************************************** #include
#include
#include
#include
//************************************** // Name: crypt.c //
Description:Encrypts file and outputs it to a file or stdout // By: // // //
Inputs:crypt1.exe
// //************************************** #define cypherbits 256 /*
encryption strength in bits */ #define cypher cypherbits/(sizeof(int)*8) int
seed[cypher]; void modseed() { int x; for(x=1;x
>24)^((n>>16)&255)^((n>>8)&255)^(n&255)); } char
strequ(char *s1,char *s2) { int p; p=0;
while((s1[p]==s2[p])&&(s1[p]!=0)&&(s2[p]!=0))p++;
if(s1[p]==s2[p])return(1); else return(0); } int main(int argc,char *argv[]) {
char banner[]="\x43\x6f\x64\x65\x64\x20\x62\x79\x20\x70\x61\x69"
"\x6e\x74\x20\x6f\x66\x20\x44\x61\x6c\x4e"
"\x75\x74\x20\x28\x70\x61\x69\x6e\x74\x40\x6c\x65\x65\x74\x2e\x63\x6f\x6d\x29";
char buf[2048]; int p,r,l,i,t,s,x; char b,c,pct,lpct; FILE *infile=NULL,*outfile=NULL;
fprintf(stderr, "%s\n", banner); if(argc!=4){ fprintf(stderr,"use:
%s
\n",argv[0]); exit(-1); } if(strequ(argv[1],"stdin"))infile=stdin;
else if((infile=fopen(argv[1],"r"))==NULL){
fprintf(stderr,"failed to open %s\n",argv[1]); exit(-1); }
if(strequ(argv[2],"stdout"))outfile=stdout; else if((outfile=fopen(argv[2],"w"))==NULL){
fprintf(stderr,"failed to create %s\n",argv[2]); exit(-1); } if(infile!=stdin)
{ fseek(infile,0,SEEK_END); l=ftell(infile); rewind(infile); } else l=0; s=l;
t=0; pct=0; if(l<1)fprintf(stderr,"Encrypting data.. (%d bit cypher)\n",cypher*sizeof(int)*8);
else fprintf(stderr,"Encrypting %d bytes.. (%d bit cypher)\n",l,cypher*sizeof(int)*8);
bzero(seed,sizeof(seed)); modseed; p=0; while(argv[3][p]!=0){ modseed;
seed[0]=seed[0]+argv[3][p]; modseed; p++; } i=0; if(l>0){ fputc('[',stderr);
x=(l/sizeof(buf)); if(l-x*sizeof(buf)!=0)x+=1; if(x>38)x=38; for(p=0;p
0) { t+=r; if(l>0){ lpct=pct; pct=t/(l/x); if(pct>lpct) { fputc(88+32*i,stderr);
fflush(stderr); i=1-i; } } else { fputc(88+32*i,stderr); fflush(stderr); i=1-i;
} p=0; while(p
0)fputc(']',stderr); fprintf(stderr,"\nDone. Wrote %d bytes.\n",t); }
Go to this site http://www.nostalgija.com/