auth.h (1684B)
1 /* 2 * 3 * 4 * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file. 5 * 6 * Copyright 2007-2020 Broadcom Inc. All rights reserved. 7 * 8 * DO NOT EDIT THIS FILE! 9 * This file is auto-generated. 10 * Edits to this file will be lost when it is regenerated. 11 */ 12 13 #ifndef __BCMX_AUTH_H__ 14 #define __BCMX_AUTH_H__ 15 16 #include <bcm/types.h> 17 #include <bcmx/bcmx.h> 18 #include <bcmx/lport.h> 19 #include <bcm/auth.h> 20 21 /* Sets or gets authorization operating mode. */ 22 extern int bcmx_auth_mode_set( 23 bcmx_lport_t port, 24 uint32 mode); 25 26 /* Sets or gets authorization operating mode. */ 27 extern int bcmx_auth_mode_get( 28 bcmx_lport_t port, 29 uint32 *modep); 30 31 /* Definition for 802.1X callout functions. */ 32 typedef void (*bcmx_auth_cb_t)( 33 void *cookie, 34 bcmx_lport_t port, 35 int reason); 36 37 /* 38 * Register a callback function to be called when a port becomes 39 * asynchronously unauthorized. 40 */ 41 extern int bcmx_auth_unauth_callback( 42 bcmx_auth_cb_t func, 43 void *cookie); 44 45 /* Enable/disable the ability of packets to be sent out a port. */ 46 extern int bcmx_auth_egress_set( 47 bcmx_lport_t port, 48 int enable); 49 50 /* Enable/disable the ability of packets to be sent out a port. */ 51 extern int bcmx_auth_egress_get( 52 bcmx_lport_t port, 53 int *enable); 54 55 /* Add Switch's MAC address. */ 56 extern int bcmx_auth_mac_add( 57 bcmx_lport_t port, 58 bcm_mac_t mac); 59 60 /* Remove Switch's MAC address. */ 61 extern int bcmx_auth_mac_delete( 62 bcmx_lport_t port, 63 bcm_mac_t mac); 64 65 /* Remove Switch's MAC address. */ 66 extern int bcmx_auth_mac_delete_all( 67 bcmx_lport_t port); 68 69 #endif /* __BCMX_AUTH_H__ */