1*05b00f60SXin Li /* 2*05b00f60SXin Li * Sun RPC is a product of Sun Microsystems, Inc. and is provided for 3*05b00f60SXin Li * unrestricted use provided that this legend is included on all tape 4*05b00f60SXin Li * media and as a part of the software program in whole or part. Users 5*05b00f60SXin Li * may copy or modify Sun RPC without charge, but are not authorized 6*05b00f60SXin Li * to license or distribute it to anyone else except as part of a product or 7*05b00f60SXin Li * program developed by the user. 8*05b00f60SXin Li * 9*05b00f60SXin Li * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE 10*05b00f60SXin Li * WARRANTIES OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR 11*05b00f60SXin Li * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. 12*05b00f60SXin Li * 13*05b00f60SXin Li * Sun RPC is provided with no support and without any obligation on the 14*05b00f60SXin Li * part of Sun Microsystems, Inc. to assist in its use, correction, 15*05b00f60SXin Li * modification or enhancement. 16*05b00f60SXin Li * 17*05b00f60SXin Li * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE 18*05b00f60SXin Li * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC 19*05b00f60SXin Li * OR ANY PART THEREOF. 20*05b00f60SXin Li * 21*05b00f60SXin Li * In no event will Sun Microsystems, Inc. be liable for any lost revenue 22*05b00f60SXin Li * or profits or other special, indirect and consequential damages, even if 23*05b00f60SXin Li * Sun has been advised of the possibility of such damages. 24*05b00f60SXin Li * 25*05b00f60SXin Li * Sun Microsystems, Inc. 26*05b00f60SXin Li * 2550 Garcia Avenue 27*05b00f60SXin Li * Mountain View, California 94043 28*05b00f60SXin Li * 29*05b00f60SXin Li * from: @(#)auth.h 1.17 88/02/08 SMI 30*05b00f60SXin Li * from: @(#)auth.h 2.3 88/08/07 4.0 RPCSRC 31*05b00f60SXin Li * $FreeBSD: src/include/rpc/auth.h,v 1.14.2.1 1999/08/29 14:39:02 peter Exp $ 32*05b00f60SXin Li */ 33*05b00f60SXin Li 34*05b00f60SXin Li /* 35*05b00f60SXin Li * auth.h, Authentication interface. 36*05b00f60SXin Li * 37*05b00f60SXin Li * Copyright (C) 1984, Sun Microsystems, Inc. 38*05b00f60SXin Li * 39*05b00f60SXin Li * The data structures are completely opaque to the client. The client 40*05b00f60SXin Li * is required to pass a AUTH * to routines that create rpc 41*05b00f60SXin Li * "sessions". 42*05b00f60SXin Li */ 43*05b00f60SXin Li 44*05b00f60SXin Li /* 45*05b00f60SXin Li * Status returned from authentication check 46*05b00f60SXin Li */ 47*05b00f60SXin Li enum sunrpc_auth_stat { 48*05b00f60SXin Li SUNRPC_AUTH_OK=0, 49*05b00f60SXin Li /* 50*05b00f60SXin Li * failed at remote end 51*05b00f60SXin Li */ 52*05b00f60SXin Li SUNRPC_AUTH_BADCRED=1, /* bogus credentials (seal broken) */ 53*05b00f60SXin Li SUNRPC_AUTH_REJECTEDCRED=2, /* client should begin new session */ 54*05b00f60SXin Li SUNRPC_AUTH_BADVERF=3, /* bogus verifier (seal broken) */ 55*05b00f60SXin Li SUNRPC_AUTH_REJECTEDVERF=4, /* verifier expired or was replayed */ 56*05b00f60SXin Li SUNRPC_AUTH_TOOWEAK=5, /* rejected due to security reasons */ 57*05b00f60SXin Li /* 58*05b00f60SXin Li * failed locally 59*05b00f60SXin Li */ 60*05b00f60SXin Li SUNRPC_AUTH_INVALIDRESP=6, /* bogus response verifier */ 61*05b00f60SXin Li SUNRPC_AUTH_FAILED=7 /* some unknown reason */ 62*05b00f60SXin Li }; 63*05b00f60SXin Li 64*05b00f60SXin Li /* 65*05b00f60SXin Li * Authentication info. Opaque to client. 66*05b00f60SXin Li */ 67*05b00f60SXin Li struct sunrpc_opaque_auth { 68*05b00f60SXin Li nd_uint32_t oa_flavor; /* flavor of auth */ 69*05b00f60SXin Li nd_uint32_t oa_len; /* length of opaque body */ 70*05b00f60SXin Li /* zero or more bytes of body */ 71*05b00f60SXin Li }; 72