Logo Search packages:      
Sourcecode: uif2iso version File versions  Download package

void des_setkey_dec ( des_context ctx,
unsigned char  key[8] 
)

DES key schedule (56-bit, decryption).

Parameters:
ctx DES context to be initialized
key 8-byte secret key

Definition at line 368 of file des.c.

References des_context::sk.

{
    int i;

    des_setkey( ctx->sk, key );

    for( i = 0; i < 16; i += 2 )
    {
        SWAP( ctx->sk[i    ], ctx->sk[30 - i] );
        SWAP( ctx->sk[i + 1], ctx->sk[31 - i] );
    }
}


Generated by  Doxygen 1.6.0   Back to index