2 \brief Public interface for libradsec request's. */
4 /* See the file COPYING for licensing information. */
8 #if defined (__cplusplus)
12 /** Create a request associated with connection \a conn. */
13 int rs_request_create(struct rs_connection *conn, struct rs_request **req_out);
14 /** Add RADIUS request message \a req_msg to request \a req. */
15 void rs_request_add_reqpkt(struct rs_request *req, struct rs_packet *req_msg);
17 /** Create a request associated with connection \a conn containing a
18 RADIUS authentication message with \a user_name and \a user_pw
19 attributes. \a user_name and _user_pw are optional and can be
21 int rs_request_create_authn(struct rs_connection *conn,
22 struct rs_request **req_out,
23 const char *user_name,
25 /** Send request \a req and wait for a matching response. The
26 response is put in \a resp_msg (if not NULL). NOTE: At present,
27 no more than one outstanding request to a given realm is
28 supported. This will change in a future version. */
29 int rs_request_send(struct rs_request *req, struct rs_packet **resp_msg);
31 /** Free all memory allocated by request \a req including the request
32 packet and any response package associated with the request. Note
33 that a request must be freed before its associated connection can
35 void rs_request_destroy(struct rs_request *req);
37 #if defined (__cplusplus)