dmake: do not set MAKEFLAGS=k
[unleashed/tickless.git] / kernel / comstar / port / iscsit / radius_auth.h
blobd77b2d23ca41824e6bebb277ae60fc9b00aad8c4
1 /*
2 * CDDL HEADER START
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
19 * CDDL HEADER END
22 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
25 #ifndef _RADIUS_AUTH_H
26 #define _RADIUS_AUTH_H
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
32 #include <netinet/in.h>
33 #include <sys/iscsit/chap.h>
36 * Function: iscsit_radius_chap_validate
38 * Description: To validate a target response given the
39 * associated challenge via the specified
40 * RADIUS server.
42 * Arguments:
43 * target_chap_name - The CHAP name of the target being authenticated.
44 * initiator_chap_name - The CHAP name of the authenticating initiator.
45 * challenge - The CHAP challenge to which the target responded.
46 * target_response - The target's CHAP response to be validated.
47 * identifier - The identifier associated with the CHAP challenge.
48 * radius_server_ip_address - The IP address of the RADIUS server.
49 * radius_server_port - The port number of the RADIUS server.
50 * radius_shared_secret - The shared secret for accessing the RADIUS server.
51 * radius_shared_secret_len - The length of the shared secret.
53 * Return: See chap_validation_status_type.
55 chap_validation_status_type
56 iscsit_radius_chap_validate(char *target_chap_name,
57 char *initiator_chap_name,
58 uint8_t *challenge,
59 uint32_t challenge_length,
60 uint8_t *target_response,
61 uint32_t response_length,
62 uint8_t identifier,
63 iscsi_ipaddr_t rad_svr_ip_addr,
64 uint32_t rad_svr_port,
65 uint8_t *rad_svr_shared_secret,
66 uint32_t rad_svr_shared_secret_len);
67 #ifdef __cplusplus
69 #endif
71 #endif /* _RADIUS_AUTH_H */