static int qcrypto_cipher_init_des_rfb(QCryptoCipher *cipher,

                                       const uint8_t *key, size_t nkey,

                                       Error **errp)

{

    QCryptoCipherBuiltin *ctxt;



    if (cipher->mode != QCRYPTO_CIPHER_MODE_ECB) {

        error_setg(errp, "Unsupported cipher mode %d", cipher->mode);

        return -1;

    }



    ctxt = g_new0(QCryptoCipherBuiltin, 1);



    ctxt->state.desrfb.key = g_new0(uint8_t, nkey);

    memcpy(ctxt->state.desrfb.key, key, nkey);

    ctxt->state.desrfb.nkey = nkey;




    ctxt->free = qcrypto_cipher_free_des_rfb;

    ctxt->setiv = qcrypto_cipher_setiv_des_rfb;

    ctxt->encrypt = qcrypto_cipher_encrypt_des_rfb;

    ctxt->decrypt = qcrypto_cipher_decrypt_des_rfb;



    cipher->opaque = ctxt;



    return 0;

}
static int qcrypto_cipher_init_des_rfb(QCryptoCipher *cipher,

                                       const uint8_t *key, size_t nkey,

                                       Error **errp)

{

    QCryptoCipherBuiltin *ctxt;



    if (cipher->mode != QCRYPTO_CIPHER_MODE_ECB) {

        error_setg(errp, "Unsupported cipher mode %d", cipher->mode);

        return -1;

    }



    ctxt = g_new0(QCryptoCipherBuiltin, 1);



    ctxt->state.desrfb.key = g_new0(uint8_t, nkey);

    memcpy(ctxt->state.desrfb.key, key, nkey);

    ctxt->state.desrfb.nkey = nkey;




    ctxt->free = qcrypto_cipher_free_des_rfb;

    ctxt->setiv = qcrypto_cipher_setiv_des_rfb;

    ctxt->encrypt = qcrypto_cipher_encrypt_des_rfb;

    ctxt->decrypt = qcrypto_cipher_decrypt_des_rfb;



    cipher->opaque = ctxt;



    return 0;

}
static int FUNC_0(QCryptoCipher *VAR_0,

                                       const uint8_t *VAR_1, size_t VAR_2,

                                       Error **VAR_3)

{

    QCryptoCipherBuiltin *ctxt;



    if (VAR_0->mode != QCRYPTO_CIPHER_MODE_ECB) {

        error_setg(VAR_3, "Unsupported VAR_0 mode %d", VAR_0->mode);

        return -1;

    }



    ctxt = g_new0(QCryptoCipherBuiltin, 1);



    ctxt->state.desrfb.VAR_1 = g_new0(uint8_t, VAR_2);

    memcpy(ctxt->state.desrfb.VAR_1, VAR_1, VAR_2);

    ctxt->state.desrfb.VAR_2 = VAR_2;




    ctxt->free = qcrypto_cipher_free_des_rfb;

    ctxt->setiv = qcrypto_cipher_setiv_des_rfb;

    ctxt->encrypt = qcrypto_cipher_encrypt_des_rfb;

    ctxt->decrypt = qcrypto_cipher_decrypt_des_rfb;



    VAR_0->opaque = ctxt;



    return 0;

}
static int FUNC_0(QCryptoCipher *VAR_0,
const uint8_t *VAR_1, size_t VAR_2,
Error **VAR_3)
{ QCryptoCipherBuiltin *ctxt; if (VAR_0->mode != QCRYPTO_CIPHER_MODE_ECB) { error_setg(VAR_3, "Unsupported VAR_0 mode %d", VAR_0->mode); return -1; } ctxt = g_new0(QCryptoCipherBuiltin, 1); ctxt->state.desrfb.VAR_1 = g_new0(uint8_t, VAR_2); memcpy(ctxt->state.desrfb.VAR_1, VAR_1, VAR_2); ctxt->state.desrfb.VAR_2 = VAR_2; ctxt->free = qcrypto_cipher_free_des_rfb; ctxt->setiv = qcrypto_cipher_setiv_des_rfb; ctxt->encrypt = qcrypto_cipher_encrypt_des_rfb; ctxt->decrypt = qcrypto_cipher_decrypt_des_rfb; VAR_0->opaque = ctxt; return 0; }