Issue While Installing NCrack 0.4Alpha

So today I was trying to install NCrack 0.4Alpha, and I encountered this problem of undeclared variable DE1 and userkey not in scope. Below are the commands to run and the red marks where the errors appear.

tar xzf ncrack-0.4ALPHA.tar.gz
cd ncrack-0.4ALPHA.tar.gz && ./configure
make install

The errors:

... In function 'void deskey(unsigned char*, int)': error: 'DE1' was not declared in this scope In function 'void cookey(long unsigned int*)': error: 'usekey' was not declared in this scope

Online people suggest to install the following crypto packages. And then redo above installation steps.

sudo apt-get install build-essential checkinstall libssl-dev libssh-dev

It works, but it seems like we do not need to install those.

After digging into the code where it went wrong, the solution is to make the following changes in the file


        if( edf == DE1) m = (15 - i) << 1;


        if( edf == 1) m = (15 - i) << 1;

And move

//void usekey(from) 
//register unsigned long *from; 
void usekey(
register unsigned long *from
    register unsigned long *to, *endp; 
    to = KnL, endp = &KnL[32]; 
    while( to < endp ) *to++ = *from++; 


static void cookey(
register unsigned long *raw1

Then it'll work.

Leave a comment

Your email address will not be published. Required fields are marked *