FreeBSD Bugzilla – Attachment 173362 Details for
Bug 211626
[exp-run] Removal of setkey(), encrypt(), des_setkey() and des_cipher()
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for removing a bunch of functions from the C library
setkey.diff (text/plain), 3.48 KB, created by
Ed Schouten
on 2016-08-06 19:14:13 UTC
(
hide
)
Description:
Patch for removing a bunch of functions from the C library
Filename:
MIME Type:
Creator:
Ed Schouten
Created:
2016-08-06 19:14:13 UTC
Size:
3.48 KB
patch
obsolete
>Index: include/stdlib.h >=================================================================== >--- include/stdlib.h (revision 303802) >+++ include/stdlib.h (working copy) >@@ -221,10 +221,6 @@ > long random(void); > unsigned short > *seed48(unsigned short[3]); >-#ifndef _SETKEY_DECLARED >-int setkey(const char *); >-#define _SETKEY_DECLARED >-#endif > char *setstate(/* const */ char *); > void srand48(long); > void srandom(unsigned int); >Index: include/unistd.h >=================================================================== >--- include/unistd.h (revision 303802) >+++ include/unistd.h (working copy) >@@ -448,8 +448,6 @@ > /* X/Open System Interfaces */ > #if __XSI_VISIBLE > char *crypt(const char *, const char *); >-/* char *ctermid(char *); */ /* XXX ??? */ >-int encrypt(char *, int); > long gethostid(void); > int lockf(int, int, off_t); > int nice(int); >@@ -490,8 +488,6 @@ > const char * > crypt_get_format(void); > int crypt_set_format(const char *); >-int des_cipher(const char *, char *, long, int); >-int des_setkey(const char *key); > int dup3(int, int, int); > int eaccess(const char *, int); > void endusershell(void); >@@ -559,10 +555,6 @@ > int setgroups(int, const gid_t *); > void sethostid(long); > int sethostname(const char *, int); >-#ifndef _SETKEY_DECLARED >-int setkey(const char *); >-#define _SETKEY_DECLARED >-#endif > int setlogin(const char *); > int setloginclass(const char *); > void *setmode(const char *); >Index: lib/libc/gen/Symbol.map >=================================================================== >--- lib/libc/gen/Symbol.map (revision 303802) >+++ lib/libc/gen/Symbol.map (working copy) >@@ -73,10 +73,6 @@ > clock; > closedir; > confstr; >- encrypt; >- des_setkey; >- des_cipher; >- setkey; > ctermid; > ctermid_r; > daemon; >Index: lib/libc/gen/crypt.c >=================================================================== >--- lib/libc/gen/crypt.c (revision 303802) >+++ lib/libc/gen/crypt.c (working copy) >@@ -48,23 +48,18 @@ > * encryption, make sure you've got libcrypt.a around. > */ > >-__warn_references(des_setkey, >- "WARNING! des_setkey(3) not present in the system!"); >- > /* ARGSUSED */ > int >-des_setkey(const char *key __unused) >+__freebsd11_des_setkey(const char *key __unused) > { > fprintf(stderr, "WARNING! des_setkey(3) not present in the system!\n"); > return (0); > } > >-__warn_references(des_cipher, >- "WARNING! des_cipher(3) not present in the system!"); >- > /* ARGSUSED */ > int >-des_cipher(const char *in, char *out, long salt __unused, int num_iter __unused) >+__freebsd11_des_cipher(const char *in, char *out, long salt __unused, >+ int num_iter __unused) > { > fprintf(stderr, "WARNING! des_cipher(3) not present in the system!\n"); > bcopy(in, out, 8); >@@ -71,24 +66,23 @@ > return (0); > } > >-__warn_references(setkey, >- "WARNING! setkey(3) not present in the system!"); >- > /* ARGSUSED */ > int >-setkey(const char *key __unused) >+__freebsd11_setkey(const char *key __unused) > { > fprintf(stderr, "WARNING! setkey(3) not present in the system!\n"); > return (0); > } > >-__warn_references(encrypt, >- "WARNING! encrypt(3) not present in the system!"); >- > /* ARGSUSED */ > int >-encrypt(char *block __unused, int flag __unused) >+__freebsd11_encrypt(char *block __unused, int flag __unused) > { > fprintf(stderr, "WARNING! encrypt(3) not present in the system!\n"); > return (0); > } >+ >+__sym_compat(des_setkey, __freebsd11_des_setkey, FBSD_1.0); >+__sym_compat(des_cipher, __freebsd11_des_cipher, FBSD_1.0); >+__sym_compat(setkey, __freebsd11_setkey, FBSD_1.0); >+__sym_compat(encrypt, __freebsd11_encrypt, FBSD_1.0);
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 211626
:
173362
|
175393
|
175394
|
175833