Ticket #4410: decrypt_intro.patch

File decrypt_intro.patch, 748 bytes (added by drosenbe, 8 years ago)

Patch for assertion failure in encrypted introduction parsing

  • src/or/routerparse.c

     src/or/routerparse.c |    5 +++++
     1 files changed, 5 insertions(+), 0 deletions(-)
    
    diff --git a/src/or/routerparse.c b/src/or/routerparse.c
    index e8b2dd7..4ea7b96 100644
    a b rend_decrypt_introduction_points(char **ipos_decrypted, 
    48864886    crypto_cipher_env_t *cipher;
    48874887    char *dec;
    48884888    int declen;
     4889    if (ipos_encrypted_size < CIPHER_IV_LEN + 2) {
     4890      log_warn(LD_REND, "Size of encrypted introduction points is too "
     4891                        "small.");
     4892      return -1;
     4893    }
    48894894    dec = tor_malloc_zero(ipos_encrypted_size - CIPHER_IV_LEN - 1);
    48904895    cipher = crypto_create_init_cipher(descriptor_cookie, 0);
    48914896    declen = crypto_cipher_decrypt_with_iv(cipher, dec,