3.1 KB、111行 生 Blame 履歴
1/*
2Copyright 1996, 1998 The Open Group
3
4Permission to use, copy, modify, distribute, and sell this software and its
5documentation for any purpose is hereby granted without fee, provided that
6the above copyright notice appear in all copies and that both that
7copyright notice and this permission notice appear in supporting
8documentation.
9
10The above copyright notice and this permission notice shall be included
11in all copies or substantial portions of the Software.
12
13THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
14OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
15MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
16IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
17OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
18ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
19OTHER DEALINGS IN THE SOFTWARE.
20
21Except as contained in this notice, the name of The Open Group shall
22not be used in advertising or otherwise to promote the sale, use or
23other dealings in this Software without prior written authorization
24from The Open Group.
25*/
26
27#ifndef _SECURPROTO_H
28#define _SECURPROTO_H
29
30#include <X11/Xmd.h>
31#include <X11/extensions/secur.h>
32
33#define X_SecurityQueryVersion 0
34#define X_SecurityGenerateAuthorization 1
35#define X_SecurityRevokeAuthorization 2
36
37typedef struct {
38 CARD8 reqType;
39 CARD8 securityReqType;
40 CARD16 length;
41 CARD16 majorVersion;
42 CARD16 minorVersion;
43} xSecurityQueryVersionReq;
44#define sz_xSecurityQueryVersionReq 8
45
46typedef struct {
47 CARD8 type;
48 CARD8 pad0;
49 CARD16 sequenceNumber;
50 CARD32 length;
51 CARD16 majorVersion;
52 CARD16 minorVersion;
53 CARD32 pad1;
54 CARD32 pad2;
55 CARD32 pad3;
56 CARD32 pad4;
57 CARD32 pad5;
58 } xSecurityQueryVersionReply;
59#define sz_xSecurityQueryVersionReply 32
60
61typedef struct {
62 CARD8 reqType;
63 CARD8 securityReqType;
64 CARD16 length;
65 CARD16 nbytesAuthProto;
66 CARD16 nbytesAuthData;
67 CARD32 valueMask;
68 /* auth protocol name padded to 4 bytes */
69 /* auth protocol data padded to 4 bytes */
70 /* list of CARD32 values, if any */
71} xSecurityGenerateAuthorizationReq;
72#define sz_xSecurityGenerateAuthorizationReq 12
73
74typedef struct {
75 CARD8 type;
76 CARD8 pad0;
77 CARD16 sequenceNumber;
78 CARD32 length;
79 CARD32 authId;
80 CARD16 dataLength;
81 CARD16 pad1;
82 CARD32 pad2;
83 CARD32 pad3;
84 CARD32 pad4;
85 CARD32 pad5;
86 } xSecurityGenerateAuthorizationReply;
87#define sz_xSecurityGenerateAuthorizationReply 32
88
89typedef struct {
90 CARD8 reqType;
91 CARD8 securityReqType;
92 CARD16 length;
93 CARD32 authId;
94} xSecurityRevokeAuthorizationReq;
95#define sz_xSecurityRevokeAuthorizationReq 8
96
97typedef struct _xSecurityAuthorizationRevokedEvent {
98 BYTE type;
99 BYTE detail;
100 CARD16 sequenceNumber;
101 CARD32 authId;
102 CARD32 pad0;
103 CARD32 pad1;
104 CARD32 pad2;
105 CARD32 pad3;
106 CARD32 pad4;
107 CARD32 pad5;
108} xSecurityAuthorizationRevokedEvent;
109#define sz_xSecurityAuthorizationRevokedEvent 32
110
111#endif /* _SECURPROTO_H */