2
* Copyright 2008 Massachusetts Institute of Technology.
5
* Export of this software from the United States of America may
6
* require a specific license from the United States Government.
7
* It is the responsibility of any person or organization contemplating
8
* export to obtain such a license before exporting.
10
* WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
11
* distribute this software and its documentation for any purpose and
12
* without fee is hereby granted, provided that the above copyright
13
* notice appear in all copies and that both that copyright notice and
14
* this permission notice appear in supporting documentation, and that
15
* the name of M.I.T. not be used in advertising or publicity pertaining
16
* to distribution of the software without specific, written prior
17
* permission. Furthermore if you modify this software you must label
18
* your software as modified software and not distribute it in such a
19
* fashion that it might be confused with the original M.I.T. software.
20
* M.I.T. makes no representations about the suitability of
21
* this software for any purpose. It is provided "as is" without express
22
* or implied warranty.
26
#import <Cocoa/Cocoa.h>
27
#import <Kerberos/kim.h>
29
#define kCheckinMessage 100
31
@interface KerberosAgentListener : NSObject {
35
@property (readwrite, retain) NSThread *thread;
37
+ (KerberosAgentListener *) sharedListener;
39
+ (void) startListening;
43
+ (void) addClientWithPort: (mach_port_t) client_port
44
replyPort: (mach_port_t) reply_port
45
name: (kim_string) name
46
path: (kim_string) path;
48
// contains reply_port
49
+ (void) didAddClient: (NSDictionary *) info
50
error: (int32_t) error;
52
+ (void) enterIdentityWithClientPort: (mach_port_t) client_port
53
replyPort: (mach_port_t) reply_port
54
options: (kim_options) options;
56
// contains reply_port, kim_identity
57
+ (void) didEnterIdentity: (NSDictionary *) info
58
error: (int32_t) error;
60
+ (void) selectIdentityWithClientPort: (mach_port_t) client_port
61
replyPort: (mach_port_t) reply_port
62
hints: (kim_selection_hints) hints;
64
// contains reply_port, kim_identity
65
+ (void) didSelectIdentity: (NSDictionary *) info
66
error: (int32_t) error;
68
+ (void) promptForAuthWithClientPort: (mach_port_t) client_port
69
replyPort: (mach_port_t) reply_port
70
identity: (kim_string) identity_string
71
promptType: (uint32_t) prompt_type
72
allowSave: (kim_boolean) allow_save
73
hideReply: (kim_boolean) hide_reply
74
title: (kim_string) title
75
message: (kim_string) message
76
description: (kim_string) description;
78
// contains reply_port, (string) prompt_response
79
+ (void) didPromptForAuth: (NSDictionary *) info
80
error: (int32_t) error;
82
+ (void) changePasswordWithClientPort: (mach_port_t) client_port
83
replyPort: (mach_port_t) reply_port
84
identity: (kim_string) identity_string
85
expired: (kim_boolean) expired;
87
// contains reply_port, old password, new password, verify password
88
+ (void) didChangePassword: (NSDictionary *) info
89
error: (int32_t) error;
91
+ (void) handleErrorWithClientPort: (mach_port_t) client_port
92
replyPort: (mach_port_t) reply_port
93
identity: (kim_string) identity_string
94
error: (kim_error) error
95
message: (kim_string) message
96
description: (kim_string) description;
98
// contains reply_port
99
+ (void) didHandleError: (NSDictionary *) info
100
error: (int32_t) error;
103
+ (void) removeClientMatchingPort: (mach_port_t) client_port
104
replyPort: (mach_port_t) reply_port;
106
+ (void) didRemoveClient: (NSDictionary *)info
107
error: (int32_t) error;