projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix the S/MIME code so it now works again and
[openssl.git]
/
crypto
/
bf
/
bf_ecb.c
diff --git
a/crypto/bf/bf_ecb.c
b/crypto/bf/bf_ecb.c
index 0af1405c0690ab17a0f6e41f7b15421b1040f4da..341991636f4ab3634174df44717404a50c846db2 100644
(file)
--- a/
crypto/bf/bf_ecb.c
+++ b/
crypto/bf/bf_ecb.c
@@
-56,17
+56,18
@@
* [including the GNU Public Licence.]
*/
* [including the GNU Public Licence.]
*/
-#include
"blowfish.h"
+#include
<openssl/blowfish.h>
#include "bf_locl.h"
#include "bf_locl.h"
+#include <openssl/opensslv.h>
/* Blowfish as implemented from 'Blowfish: Springer-Verlag paper'
/* Blowfish as implemented from 'Blowfish: Springer-Verlag paper'
- * (From LECTURE NOTES IN CO
I
MPUTER SCIENCE 809, FAST SOFTWARE ENCRYPTION,
+ * (From LECTURE NOTES IN COMPUTER SCIENCE 809, FAST SOFTWARE ENCRYPTION,
* CAMBRIDGE SECURITY WORKSHOP, CAMBRIDGE, U.K., DECEMBER 9-11, 1993)
*/
* CAMBRIDGE SECURITY WORKSHOP, CAMBRIDGE, U.K., DECEMBER 9-11, 1993)
*/
-c
har *BF_version="BlowFish part of OpenSSL 0.9.2 31-Dec-1998"
;
+c
onst char *BF_version="Blowfish" OPENSSL_VERSION_PTEXT
;
-c
har *BF_options(
)
+c
onst char *BF_options(void
)
{
#ifdef BF_PTR
return("blowfish(ptr)");
{
#ifdef BF_PTR
return("blowfish(ptr)");
@@
-77,20
+78,17
@@
char *BF_options()
#endif
}
#endif
}
-void BF_ecb_encrypt(in, out, ks, encrypt)
-unsigned char *in;
-unsigned char *out;
-BF_KEY *ks;
-int encrypt;
+void BF_ecb_encrypt(const unsigned char *in, unsigned char *out,
+ const BF_KEY *key, int encrypt)
{
BF_LONG l,d[2];
n2l(in,l); d[0]=l;
n2l(in,l); d[1]=l;
if (encrypt)
{
BF_LONG l,d[2];
n2l(in,l); d[0]=l;
n2l(in,l); d[1]=l;
if (encrypt)
- BF_encrypt(d,k
s
);
+ BF_encrypt(d,k
ey
);
else
else
- BF_decrypt(d,k
s
);
+ BF_decrypt(d,k
ey
);
l=d[0]; l2n(l,out);
l=d[1]; l2n(l,out);
l=d[0]=d[1]=0;
l=d[0]; l2n(l,out);
l=d[1]; l2n(l,out);
l=d[0]=d[1]=0;