Permalink
Browse files

Revert 18100 before merging onto trunk

git-svn-id: svn://anonsvn.mit.edu/krb5/branches/ccapi@18199 dc483132-0cff-0310-8789-dd5450dbe970
  • Loading branch information...
1 parent c53a2e6 commit 3ab631c15911bd864a48f532c3c35acf35d6b56e hartmans committed Jun 22, 2006
@@ -1,47 +0,0 @@
-/*
- * kipc_client.h
- *
- * $Header$
- *
- * Copyright 2006 Massachusetts Institute of Technology.
- * All Rights Reserved.
- *
- * Export of this software from the United States of America may
- * require a specific license from the United States Government.
- * It is the responsibility of any person or organization contemplating
- * export to obtain such a license before exporting.
- *
- * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
- * distribute this software and its documentation for any purpose and
- * without fee is hereby granted, provided that the above copyright
- * notice appear in all copies and that both that copyright notice and
- * this permission notice appear in supporting documentation, and that
- * the name of M.I.T. not be used in advertising or publicity pertaining
- * to distribution of the software without specific, written prior
- * permission. Furthermore if you modify this software you must label
- * your software as modified software and not distribute it in such a
- * fashion that it might be confused with the original M.I.T. software.
- * M.I.T. makes no representations about the suitability of
- * this software for any purpose. It is provided "as is" without express
- * or implied warranty.
- */
-
-#ifndef KIPC_CLIENT_H
-#define KIPC_CLIENT_H
-
-#include <Kerberos/kipc_common.h>
-
-#if __cplusplus
-extern "C" {
-#endif
-
-kipc_err_t
-kipc_client_lookup_server (const char *in_service_id,
- boolean_t in_launch_if_necessary,
- mach_port_t *out_service_port);
-
-#if __cplusplus
-}
-#endif
-
-#endif /* KIPC_CLIENT_H */
@@ -1,76 +0,0 @@
-/*
- * KerberosIPCCommon.h
- *
- * $Header$
- *
- * Copyright 2006 Massachusetts Institute of Technology.
- * All Rights Reserved.
- *
- * Export of this software from the United States of America may
- * require a specific license from the United States Government.
- * It is the responsibility of any person or organization contemplating
- * export to obtain such a license before exporting.
- *
- * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
- * distribute this software and its documentation for any purpose and
- * without fee is hereby granted, provided that the above copyright
- * notice appear in all copies and that both that copyright notice and
- * this permission notice appear in supporting documentation, and that
- * the name of M.I.T. not be used in advertising or publicity pertaining
- * to distribution of the software without specific, written prior
- * permission. Furthermore if you modify this software you must label
- * your software as modified software and not distribute it in such a
- * fashion that it might be confused with the original M.I.T. software.
- * M.I.T. makes no representations about the suitability of
- * this software for any purpose. It is provided "as is" without express
- * or implied warranty.
- */
-
-#ifndef KIPC_COMMON_H
-#define KIPC_COMMON_H
-
-//#include <Kerberos/KerberosDebug.h>
-#include <CoreFoundation/CoreFoundation.h>
-#include <mach/mach.h>
-#include <mach/boolean.h>
-#include <mach/mach_error.h>
-#include <mach/notify.h>
-#include <servers/bootstrap.h>
-#include <sys/types.h>
-#include <sys/time.h>
-#include <sys/resource.h>
-#include <sys/wait.h>
-#include <sys/param.h>
-#include <unistd.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <errno.h>
-
-
-#if __cplusplus
-extern "C" {
-#endif
-
-typedef kern_return_t kipc_err_t;
-typedef boolean_t kipc_boolean_t;
-typedef char *kipc_string;
-
-#define kkipc_max_message_size 2048 + MAX_TRAILER_SIZE
-#define kkipc_timeout 200
-
-// Debugging API used by library
-kipc_err_t __kipc_err (kipc_err_t inError, const char *function, const char *file, int line);
-#define kipc_err(err) __kipc_err(err, __FUNCTION__, __FILE__, __LINE__)
-
-const char *kipc_error_string (kipc_err_t in_error);
-
-kipc_err_t kipc_get_lookup_name (char **out_lookup_name, const char *in_service_id);
-kipc_err_t kipc_get_service_name (char **out_service_name, const char *in_service_id);
-
-void kipc_free_string (char *io_string);
-
-#if __cplusplus
-}
-#endif
-
-#endif /* KIPC_COMMON_H */
@@ -1,54 +0,0 @@
-/*
- * kipc_server.h
- *
- * $Header$
- *
- * Copyright 2006 Massachusetts Institute of Technology.
- * All Rights Reserved.
- *
- * Export of this software from the United States of America may
- * require a specific license from the United States Government.
- * It is the responsibility of any person or organization contemplating
- * export to obtain such a license before exporting.
- *
- * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
- * distribute this software and its documentation for any purpose and
- * without fee is hereby granted, provided that the above copyright
- * notice appear in all copies and that both that copyright notice and
- * this permission notice appear in supporting documentation, and that
- * the name of M.I.T. not be used in advertising or publicity pertaining
- * to distribution of the software without specific, written prior
- * permission. Furthermore if you modify this software you must label
- * your software as modified software and not distribute it in such a
- * fashion that it might be confused with the original M.I.T. software.
- * M.I.T. makes no representations about the suitability of
- * this software for any purpose. It is provided "as is" without express
- * or implied warranty.
- */
-
-#ifndef KIPC_SERVER_H
-#define KIPC_SERVER_H
-
-#include <Kerberos/kipc_common.h>
-
-#define kKerberosIPCMaxMsgSize 2048 + MAX_TRAILER_SIZE
-#define kKerberosIPCTimeout 200
-
-#if __cplusplus
-extern "C" {
-#endif
-
-typedef kipc_boolean_t (*kipc_demux_proc) (mach_msg_header_t *, mach_msg_header_t *);
-
-
-kipc_err_t kipc_server_run_server (kipc_demux_proc in_demux_proc);
-
-mach_port_t kipc_server_get_service_port ();
-
-kipc_boolean_t kipc_server_quit (void);
-
-#if __cplusplus
-}
-#endif
-
-#endif /* KIPC_SERVER_H */
@@ -1,59 +0,0 @@
-/*
- * kipc_session.h
- *
- * $Header$
- *
- * Copyright 2006 Massachusetts Institute of Technology.
- * All Rights Reserved.
- *
- * Export of this software from the United States of America may
- * require a specific license from the United States Government.
- * It is the responsibility of any person or organization contemplating
- * export to obtain such a license before exporting.
- *
- * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
- * distribute this software and its documentation for any purpose and
- * without fee is hereby granted, provided that the above copyright
- * notice appear in all copies and that both that copyright notice and
- * this permission notice appear in supporting documentation, and that
- * the name of M.I.T. not be used in advertising or publicity pertaining
- * to distribution of the software without specific, written prior
- * permission. Furthermore if you modify this software you must label
- * your software as modified software and not distribute it in such a
- * fashion that it might be confused with the original M.I.T. software.
- * M.I.T. makes no representations about the suitability of
- * this software for any purpose. It is provided "as is" without express
- * or implied warranty.
- */
-
-#ifndef KIPC_SESSION_H
-#define KIPC_SESSION_H
-
-#include <Kerberos/kipc_common.h>
-
-#if __cplusplus
-extern "C" {
-#endif
-
-#define kkipc_session_has_gui_access 0x00000001
-#define kkipc_session_caller_uses_gui 0x00000002
-#define kkipc_session_has_cli_access 0x00000004
-
-typedef u_int32_t kipc_session_attributes_t;
-
-
-kipc_boolean_t kipc_session_is_root_session (void);
-
-kipc_session_attributes_t kipc_session_get_attributes (void);
-
-kipc_string kipc_get_session_id_string (void);
-
-uid_t kipc_session_get_session_uid (void);
-
-uid_t kipc_session_get_server_uid (void);
-
-#if __cplusplus
-}
-#endif
-
-#endif /* KIPC_SESSION_H */
@@ -1,3 +0,0 @@
-This is a temporary copy of the KfM KerberosIPC library sources.
-Once this gets merged onto the trunk the KfM build will use the
-KerberosIPC library instead.
@@ -1,86 +0,0 @@
-/*
- * kipc_client.c
- *
- * $Header$
- *
- * Copyright 2006 Massachusetts Institute of Technology.
- * All Rights Reserved.
- *
- * Export of this software from the United States of America may
- * require a specific license from the United States Government.
- * It is the responsibility of any person or organization contemplating
- * export to obtain such a license before exporting.
- *
- * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
- * distribute this software and its documentation for any purpose and
- * without fee is hereby granted, provided that the above copyright
- * notice appear in all copies and that both that copyright notice and
- * this permission notice appear in supporting documentation, and that
- * the name of M.I.T. not be used in advertising or publicity pertaining
- * to distribution of the software without specific, written prior
- * permission. Furthermore if you modify this software you must label
- * your software as modified software and not distribute it in such a
- * fashion that it might be confused with the original M.I.T. software.
- * M.I.T. makes no representations about the suitability of
- * this software for any purpose. It is provided "as is" without express
- * or implied warranty.
- */
-
-#include <Kerberos/kipc_client.h>
-
-// ---------------------------------------------------------------------------
-
-kipc_err_t
-kipc_client_lookup_server (const char *in_service_id,
- boolean_t in_launch_if_necessary,
- mach_port_t *out_service_port)
-{
- kipc_err_t err = 0;
- mach_port_t boot_port = MACH_PORT_NULL;
- char *service_name = NULL;
-
- if (in_service_id == NULL) { err = kipc_err (EINVAL); }
- if (out_service_port == NULL) { err = kipc_err (EINVAL); }
-
- if (!err) {
- // Get our bootstrap port
- err = task_get_bootstrap_port (mach_task_self (), &boot_port);
- }
-
- if (!err && !in_launch_if_necessary) {
- char *lookup_name = NULL;
- mach_port_t lookup_port = MACH_PORT_NULL;
-
- err = kipc_get_lookup_name (&lookup_name, in_service_id);
-
- if (!err) {
- // Use the lookup name because the service name will return
- // a valid port even if the server isn't running
- err = bootstrap_look_up (boot_port, lookup_name, &lookup_port);
- //dprintf ("%s(): bootstrap_look_up('%s'): port is %x (err = %d '%s')",
- // __FUNCTION__, lookup_name, lookup_port, err, mach_error_string (err));
- }
-
- if (lookup_name != NULL ) { kipc_free_string (lookup_name); }
- if (lookup_port != MACH_PORT_NULL) { mach_port_deallocate (mach_task_self (), lookup_port); }
- }
-
- if (!err) {
- err = kipc_get_service_name (&service_name, in_service_id);
- }
-
- if (!err) {
- err = bootstrap_look_up (boot_port, service_name, out_service_port);
- //dprintf ("%s(): bootstrap_look_up('%s'): port is %x (err = %d '%s')",
- // __FUNCTION__, service_name, *out_service_port, err, mach_error_string (err));
- }
-
- if (service_name != NULL ) { kipc_free_string (service_name); }
- if (boot_port != MACH_PORT_NULL) { mach_port_deallocate (mach_task_self (), boot_port); }
-
- if (err == BOOTSTRAP_UNKNOWN_SERVICE) {
- return err; // Avoid spewing to the log file
- } else {
- return kipc_err (err);
- }
-}
Oops, something went wrong.

0 comments on commit 3ab631c

Please sign in to comment.