Lines Matching refs:method

2  * EAP server method registration
20 * eap_server_get_eap_method - Get EAP method based on type number
22 * @method: EAP type number
23 * Returns: Pointer to EAP method or %NULL if not found
25 const struct eap_method * eap_server_get_eap_method(int vendor, EapType method)
29 if (m->vendor == vendor && m->method == method)
37 * eap_server_get_type - Get EAP type for the given EAP method name
38 * @name: EAP method name, e.g., TLS
40 * Returns: EAP method type or %EAP_TYPE_NONE if not found
51 return m->method;
60 * eap_server_method_alloc - Allocate EAP server method structure
61 * @version: Version of the EAP server method interface (set to
64 * @method: EAP type number (EAP_TYPE_*)
65 * @name: Name of the method (e.g., "TLS")
66 * Returns: Allocated EAP method structure or %NULL on failure
72 EapType method, const char *name)
80 eap->method = method;
87 * eap_server_method_free - Free EAP server method structure
88 * @method: Method structure allocated with eap_server_method_alloc()
90 void eap_server_method_free(struct eap_method *method)
92 os_free(method);
97 * eap_server_method_register - Register an EAP server method
98 * @method: EAP method to register
99 * Returns: 0 on success, -1 on invalid method, or -2 if a matching EAP method
102 * Each EAP server method needs to call this function to register itself as a
103 * supported EAP method.
105 int eap_server_method_register(struct eap_method *method)
109 if (method == NULL || method->name == NULL ||
110 method->version != EAP_SERVER_METHOD_INTERFACE_VERSION)
114 if ((m->vendor == method->vendor &&
115 m->method == method->method) ||
116 os_strcmp(m->name, method->name) == 0)
122 last->next = method;
124 eap_methods = method;
153 * eap_server_get_name - Get EAP method name for the given EAP type
155 * @type: EAP method type
156 * Returns: EAP method name, e.g., TLS, or %NULL if not found
167 if (m->vendor == vendor && m->method == type)