port to new RADIUS client library
[radsecproxy.git] / lib / radius / examples / example_2.c
index 1065c8e..0a58523 100644 (file)
@@ -36,8 +36,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
 static const char *secret = "testing123";
-static uint8_t request_buffer[NR_MAX_PACKET_LEN];
-static uint8_t response_buffer[NR_MAX_PACKET_LEN];
+static uint8_t request_buffer[RS_MAX_PACKET_LEN];
+static uint8_t response_buffer[RS_MAX_PACKET_LEN];
 static RADIUS_PACKET request, response;
 
 int main(int argc, const char *argv[])
@@ -58,12 +58,12 @@ int main(int argc, const char *argv[])
        if (argc > 2) password = argv[2];
 
        rcode = nr_packet_attr_append(&request, NULL,
-                                     NR_DA_USER_NAME,
+                                     RS_DA_USER_NAME,
                                      user, 0);
        if (rcode < 0) goto error;
        
        rcode = nr_packet_attr_append(&request, NULL,
-                                     NR_DA_CHAP_PASSWORD,
+                                     RS_DA_CHAP_PASSWORD,
                                      password, strlen(password));
        if (rcode < 0) goto error;