diff options
author | 2016-05-30 02:53:29 +0000 | |
---|---|---|
committer | 2016-05-30 02:53:29 +0000 | |
commit | 8ae7fd5a8b25750a56d9f379f0a603221b54b459 (patch) | |
tree | 5c946b7388fc8c353d1ff653a5b60400078d72af | |
parent | Do setjmp cookies for eip, esp, and ebp. For bonus points, mix how (diff) | |
download | wireguard-openbsd-8ae7fd5a8b25750a56d9f379f0a603221b54b459.tar.xz wireguard-openbsd-8ae7fd5a8b25750a56d9f379f0a603221b54b459.zip |
Stop publicly declaring _yp_dobind() and struct dom_binding, closing out
a rant Theo wrote 24 years ago. Mark __ypexclude_{add,is,free}() as hidden
"get off my lawn!" deraadt@
-rw-r--r-- | include/rpcsvc/yp_prot.h | 25 | ||||
-rw-r--r-- | include/rpcsvc/ypclnt.h | 4 | ||||
-rw-r--r-- | lib/libc/hidden/rpcsvc/ypclnt.h | 8 | ||||
-rw-r--r-- | lib/libc/yp/yp_bind.c | 3 | ||||
-rw-r--r-- | lib/libc/yp/ypexclude.h | 4 |
5 files changed, 12 insertions, 32 deletions
diff --git a/include/rpcsvc/yp_prot.h b/include/rpcsvc/yp_prot.h index d78bd61df0f..243cf5296fa 100644 --- a/include/rpcsvc/yp_prot.h +++ b/include/rpcsvc/yp_prot.h @@ -1,4 +1,4 @@ -/* $OpenBSD: yp_prot.h,v 1.9 2015/09/28 20:49:24 deraadt Exp $ */ +/* $OpenBSD: yp_prot.h,v 1.10 2016/05/30 02:53:29 guenther Exp $ */ /* $NetBSD: yp_prot.h,v 1.6 1995/07/14 21:10:58 christos Exp $ */ /* @@ -190,29 +190,6 @@ struct ypresp_maplist { #define YP_VERS ((unsigned long)-8) /* YP server version mismatch */ /* - * Sun's header file says: - * "Domain binding data structure, used by ypclnt package and ypserv modules. - * Users of the ypclnt package (or of this protocol) don't HAVE to know about - * it, but it must be available to users because _yp_dobind is a public - * interface." - * - * This is totally bogus! Nowhere else does Sun state that _yp_dobind() is - * a public interface, and I don't know any reason anyone would want to call - * it. But, just in case anyone does actually expect it to be available.. - * we provide this.. exactly as Sun wants it. - */ -struct dom_binding { - struct dom_binding *dom_pnext; - char dom_domain[YPMAXDOMAIN + 1]; - struct sockaddr_in dom_server_addr; - unsigned short dom_server_port; - int dom_socket; - CLIENT *dom_client; - unsigned short dom_local_port; - long dom_vers; -}; - -/* * YPBIND PROTOCOL: * * ypbind supports the following procedures: diff --git a/include/rpcsvc/ypclnt.h b/include/rpcsvc/ypclnt.h index f271e5c6246..f7af7c3d30c 100644 --- a/include/rpcsvc/ypclnt.h +++ b/include/rpcsvc/ypclnt.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ypclnt.h,v 1.9 2004/01/22 21:48:02 espie Exp $ */ +/* $OpenBSD: ypclnt.h,v 1.10 2016/05/30 02:53:29 guenther Exp $ */ /* $NetBSD: ypclnt.h,v 1.7 1995/07/14 21:11:10 christos Exp $ */ /* @@ -63,8 +63,6 @@ struct ypall_callback { __BEGIN_DECLS int yp_bind(const char *); -struct dom_binding; -int _yp_dobind(const char *, struct dom_binding **); void yp_unbind(const char *); int yp_get_default_domain(char **); int yp_match(const char *, const char *, const char *, int , char **, diff --git a/lib/libc/hidden/rpcsvc/ypclnt.h b/lib/libc/hidden/rpcsvc/ypclnt.h index 6a5aa7b8365..30ad7660069 100644 --- a/lib/libc/hidden/rpcsvc/ypclnt.h +++ b/lib/libc/hidden/rpcsvc/ypclnt.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ypclnt.h,v 1.1 2015/09/13 20:57:28 guenther Exp $ */ +/* $OpenBSD: ypclnt.h,v 1.2 2016/05/30 02:53:29 guenther Exp $ */ /* * Copyright (c) 2015 Philip Guenther <guenther@openbsd.org> * @@ -20,7 +20,11 @@ #include_next <rpcsvc/ypclnt.h> -PROTO_NORMAL(_yp_dobind); +__BEGIN_HIDDEN_DECLS +struct dom_binding; +int _yp_dobind(const char *, struct dom_binding **); +__END_HIDDEN_DECLS + PROTO_DEPRECATED(yp_all); PROTO_NORMAL(yp_bind); PROTO_NORMAL(yp_first); diff --git a/lib/libc/yp/yp_bind.c b/lib/libc/yp/yp_bind.c index 48c639739e3..9208fd5225b 100644 --- a/lib/libc/yp/yp_bind.c +++ b/lib/libc/yp/yp_bind.c @@ -1,4 +1,4 @@ -/* $OpenBSD: yp_bind.c,v 1.27 2016/05/29 22:42:24 guenther Exp $ */ +/* $OpenBSD: yp_bind.c,v 1.28 2016/05/30 02:53:29 guenther Exp $ */ /* * Copyright (c) 1992, 1993, 1996 Theo de Raadt <deraadt@theos.com> * All rights reserved. @@ -248,7 +248,6 @@ gotdata: *ypdb = ysd; return 0; } -DEF_WEAK(_yp_dobind); void _yp_unbind(struct dom_binding *ypb) diff --git a/lib/libc/yp/ypexclude.h b/lib/libc/yp/ypexclude.h index 4ab5fabe1b2..599064dd57c 100644 --- a/lib/libc/yp/ypexclude.h +++ b/lib/libc/yp/ypexclude.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ypexclude.h,v 1.1 2009/06/03 16:02:44 schwarze Exp $ */ +/* $OpenBSD: ypexclude.h,v 1.2 2016/05/30 02:53:29 guenther Exp $ */ /* * Copyright (c) 1995, 1996, Jason Downs. All rights reserved. * @@ -36,6 +36,8 @@ struct _ypexclude { struct _ypexclude *next; }; +__BEGIN_HIDDEN_DECLS int __ypexclude_add(struct _ypexclude **, const char *); int __ypexclude_is(struct _ypexclude **, const char *); void __ypexclude_free(struct _ypexclude **); +__END_HIDDEN_DECLS |