-
Notifications
You must be signed in to change notification settings - Fork 27
/
KerbUtil.h
31 lines (25 loc) · 1.29 KB
/
KerbUtil.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
//
// Header.h
// NoMAD
//
// Created by Joel Rennich on 4/26/16.
// Copyright © 2016 Orchard & Grove Inc. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <GSS/GSS.h>
#import <Cocoa/Cocoa.h>
#import <Security/Security.h>
#import <DirectoryService/DirectoryService.h>
#import <OpenDirectory/OpenDirectory.h>
extern OSStatus SecKeychainItemSetAccessWithPassword(SecKeychainItemRef item, SecAccessRef access, UInt32 passLength, const void* password);
@interface KerbUtil : NSObject
@property (nonatomic, assign, readonly) BOOL finished; // observable
- (NSDictionary *)getKerbCredentialWithPassword:password userPrincipal:(NSString *)userPrincipal;
- (void)getKerberosCredentials:(NSString *)password :(NSString *)userPrincipal completion:(void(^)(NSDictionary *))callback;
- (NSString *)getKerbCredentials:(NSString *)password :(NSString *)userPrincipal;
- (void)changeKerberosPassword:(NSString *)oldPassword :(NSString *)newPassword :(NSString *)userPrincipal completion:(void(^)(NSString *))callback;
- (NSString *)changeKerbPassword:(NSString *)oldPassword :(NSString *)newPassword :(NSString *)userPrincipal;
- (int)checkPassword:(NSString *)myPassword;
- (int)changeKeychainPassword:(NSString *)oldPassword :(NSString *)newPassword;
- (OSStatus)resetKeychain:(NSString *)password;
@end