Changeset 9775069d0bd28eb34916f5721722ba5447612023

Show
Ignore:
Timestamp:
10/03/07 20:25:39 (2 years ago)
Author:
Rémi Denis-Courmont <rem@videolan.org>
git-committer:
Rémi Denis-Courmont <rem@videolan.org> 1173554739 +0000
git-parent:

[bfd8795c23735f60369cf72cf1571fd332546184]

git-author:
Rémi Denis-Courmont <rem@videolan.org> 1173554739 +0000
Message:

Remove window size parameter.
It has to be at least 64, and it is too complicated to implement a bigger
value, so it's not going to be configurable

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • libs/srtp/recv.c

    r10ee356 r9775069  
    5252        "\x12\x34\x56\x78\x90" "\x12\x34\x56\x78\x90" "\x12\x34\x56\x78"; 
    5353 
    54     srtp_session_t *s = srtp_create ("AES_CM_128_HMAC_SHA1_80", 0, 0, 0); 
     54    srtp_session_t *s = srtp_create ("AES_CM_128_HMAC_SHA1_80", 0, 0); 
    5555    if (s == NULL) 
    5656        return 1; 
  • libs/srtp/srtp.c

    re5c071a r9775069  
    5050    gcry_cipher_hd_t cipher; 
    5151    gcry_md_hd_t     mac; 
     52    uint64_t         window; 
    5253    uint32_t         salt[4]; 
    5354} srtp_proto_t; 
     
    162163 * @param name cipher-suite name 
    163164 * @param kdr key derivation rate 
    164  * @param winsize anti-replay windows size (between 64 and 32767 inclusive) 
    165  *                0 disable replay attack protection (OK for send only) 
    166165 * @param flags OR'ed optional flags. 
    167166 * 
     
    169168 */ 
    170169srtp_session_t * 
    171 srtp_create (const char *name, unsigned flags, unsigned kdr, uint16_t winsize
     170srtp_create (const char *name, unsigned flags, unsigned kdr
    172171{ 
    173172    assert (name != NULL); 
     
    175174    if (kdr != 0) 
    176175        return NULL; // FIXME: KDR not implemented yet 
    177     if (winsize != 0) 
    178         return NULL; // FIXME: replay protection not implemented yet 
    179176 
    180177    uint8_t tag_len; 
     
    190187        return NULL; 
    191188 
    192     if ((flags & ~SRTP_FLAGS_MASK) || (winsize > 32767) || init_libgcrypt ()) 
     189    if ((flags & ~SRTP_FLAGS_MASK) || init_libgcrypt ()) 
    193190        return NULL; 
    194191 
     
    658655         return EACCES; 
    659656 
    660     len -= 4; /* Remove SRTCP index befor decryption */ 
     657    len -= 4; /* Remove SRTCP index before decryption */ 
    661658    *lenp = len; 
    662659 
  • libs/srtp/srtp.h

    re5c071a r9775069  
    3737# endif 
    3838 
    39 srtp_session_t *srtp_create (const char *name, unsigned flags, unsigned kdr, 
    40                              uint16_t winsize); 
     39srtp_session_t *srtp_create (const char *name, unsigned flags, unsigned kdr); 
    4140void srtp_destroy (srtp_session_t *s); 
    4241int srtp_setkey (srtp_session_t *s, const void *key, size_t keylen,