]> git.saurik.com Git - apple/security.git/blob - OSX/sec/SOSCircle/SecureObjectSync/SOSTransportMessageIDS.h
Security-57336.10.29.tar.gz
[apple/security.git] / OSX / sec / SOSCircle / SecureObjectSync / SOSTransportMessageIDS.h
1 //
2 // SOSTransportMessageIDS.h
3 // sec
4 //
5 //
6 #include <Security/SecureObjectSync/SOSAccount.h>
7
8 typedef enum {
9 kIDSStartPingTestMessage = 1,
10 kIDSEndPingTestMessage= 2,
11 kIDSSendOneMessage = 3,
12 kIDSSyncMessagesRaw = 4,
13 kIDSSyncMessagesCompact = 5,
14 kIDSPeerAvailability = 6,
15 kIDSPeerAvailabilityDone = 7
16 } idsOperation;
17
18 //error handling stuff
19
20 typedef enum {
21 kSecIDSErrorNoDeviceID = -1, //default case
22 kSecIDSErrorNotRegistered = -2,
23 kSecIDSErrorFailedToSend=-3,
24 kSecIDSErrorCouldNotFindMatchingAuthToken = -4,
25 kSecIDSErrorDeviceIsLocked = -5,
26 kSecIDSErrorNoPeersAvailable = -6
27
28 } idsError;
29
30
31 extern const CFStringRef kSecIDSErrorDomain;
32
33 typedef struct __OpaqueSOSTransportMessageIDS *SOSTransportMessageIDSRef;
34
35 SOSTransportMessageIDSRef SOSTransportMessageIDSCreate(SOSAccountRef account, CFStringRef circleName, CFErrorRef *error);
36
37 HandleIDSMessageReason SOSTransportMessageIDSHandleMessage(SOSAccountRef account, CFDictionaryRef message, CFErrorRef *error);
38