FreeBSD Bugzilla – Attachment 154234 Details for
Bug 198535
[PATCH] security/isakmpd: Replace deprecated DES_ methods and fix LibreSSL build
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
svn diff for security/isakmpd
patch-security_isakmpd (text/plain), 3.99 KB, created by
Bernard Spil
on 2015-03-12 09:33:48 UTC
(
hide
)
Description:
svn diff for security/isakmpd
Filename:
MIME Type:
Creator:
Bernard Spil
Created:
2015-03-12 09:33:48 UTC
Size:
3.99 KB
patch
obsolete
>Index: security/isakmpd/files/patch-crypto.c >=================================================================== >--- security/isakmpd/files/patch-crypto.c (revision 0) >+++ security/isakmpd/files/patch-crypto.c (working copy) >@@ -0,0 +1,82 @@ >+--- crypto.c.orig 2004-06-14 11:55:41.000000000 +0200 >++++ crypto.c 2015-02-28 13:23:13.232107608 +0100 >+@@ -100,7 +100,7 @@ >+ >+ /* Hmm, the function prototypes for des are really dumb */ >+ #ifdef __OpenBSD__ >+-#define DC (des_cblock *) >++#define DC (DES_cblock *) >+ #else >+ #define DC (void *) >+ #endif >+@@ -109,8 +109,8 @@ >+ des1_init(struct keystate *ks, u_int8_t *key, u_int16_t len) >+ { >+ /* des_set_key returns -1 for parity problems, and -2 for weak keys */ >+- des_set_odd_parity(DC key); >+- switch (des_set_key(DC key, ks->ks_des[0])) { >++ DES_set_odd_parity(DC key); >++ switch (DES_set_key(DC key, &ks->ks_des[0])) { >+ case -2: >+ return EWEAKKEY; >+ default: >+@@ -121,14 +121,14 @@ >+ void >+ des1_encrypt(struct keystate *ks, u_int8_t *d, u_int16_t len) >+ { >+- des_cbc_encrypt(DC d, DC d, len, ks->ks_des[0], DC ks->riv, >++ DES_cbc_encrypt(DC d, DC d, len, &ks->ks_des[0], DC ks->riv, >+ DES_ENCRYPT); >+ } >+ >+ void >+ des1_decrypt(struct keystate *ks, u_int8_t *d, u_int16_t len) >+ { >+- des_cbc_encrypt(DC d, DC d, len, ks->ks_des[0], DC ks->riv, >++ DES_cbc_encrypt(DC d, DC d, len, &ks->ks_des[0], DC ks->riv, >+ DES_DECRYPT); >+ } >+ >+@@ -136,14 +136,14 @@ >+ enum cryptoerr >+ des3_init(struct keystate *ks, u_int8_t *key, u_int16_t len) >+ { >+- des_set_odd_parity(DC key); >+- des_set_odd_parity(DC(key + 8)); >+- des_set_odd_parity(DC(key + 16)); >++ DES_set_odd_parity(DC key); >++ DES_set_odd_parity(DC(key + 8)); >++ DES_set_odd_parity(DC(key + 16)); >+ >+ /* As of the draft Tripe-DES does not check for weak keys */ >+- des_set_key(DC key, ks->ks_des[0]); >+- des_set_key(DC(key + 8), ks->ks_des[1]); >+- des_set_key(DC(key + 16), ks->ks_des[2]); >++ DES_set_key(DC key, &ks->ks_des[0]); >++ DES_set_key(DC(key + 8), &ks->ks_des[1]); >++ DES_set_key(DC(key + 16), &ks->ks_des[2]); >+ >+ return EOKAY; >+ } >+@@ -154,8 +154,8 @@ >+ u_int8_t iv[MAXBLK]; >+ >+ memcpy(iv, ks->riv, ks->xf->blocksize); >+- des_ede3_cbc_encrypt(DC data, DC data, len, ks->ks_des[0], >+- ks->ks_des[1], ks->ks_des[2], DC iv, DES_ENCRYPT); >++ DES_ede3_cbc_encrypt(DC data, DC data, len, &ks->ks_des[0], >++ &ks->ks_des[1], &ks->ks_des[2], DC iv, DES_ENCRYPT); >+ } >+ >+ void >+@@ -164,8 +164,8 @@ >+ u_int8_t iv[MAXBLK]; >+ >+ memcpy(iv, ks->riv, ks->xf->blocksize); >+- des_ede3_cbc_encrypt(DC data, DC data, len, ks->ks_des[0], >+- ks->ks_des[1], ks->ks_des[2], DC iv, DES_DECRYPT); >++ DES_ede3_cbc_encrypt(DC data, DC data, len, &ks->ks_des[0], >++ &ks->ks_des[1], &ks->ks_des[2], DC iv, DES_DECRYPT); >+ } >+ #undef DC >+ #endif /* USE_TRIPLEDES */ > >Property changes on: security/isakmpd/files/patch-crypto.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: security/isakmpd/files/patch-crypto.h >=================================================================== >--- security/isakmpd/files/patch-crypto.h (revision 0) >+++ security/isakmpd/files/patch-crypto.h (working copy) >@@ -0,0 +1,11 @@ >+--- crypto.h.orig 2004-05-14 10:42:56.000000000 +0200 >++++ crypto.h 2015-02-28 13:01:05.491296206 +0100 >+@@ -108,7 +108,7 @@ >+ u_int8_t iv2[MAXBLK]; >+ u_int8_t *riv, *liv; >+ union { >+- des_key_schedule desks[3]; >++ DES_key_schedule desks[3]; >+ #ifdef USE_BLOWFISH >+ blf_ctx blfks; >+ #endif > >Property changes on: security/isakmpd/files/patch-crypto.h >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 198535
: 154234 |
154235