Add support for setting NLSR prefix costs via configuration file and nlsrc

This change alters the nlsr.conf 'advertising' format, as the previous
setup used unnecessary keys which made dynamically adjusting the
stateful conf file difficult.

Incorporates code written by Yanbiao Li.

Change-Id: I3ed5d0a564099be8cc1389ee6acc6f2d04cef889
diff --git a/tests/test-conf-file-processor.cpp b/tests/test-conf-file-processor.cpp
index c9acbd2..dc9564f 100644
--- a/tests/test-conf-file-processor.cpp
+++ b/tests/test-conf-file-processor.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2024,  The University of Memphis,
+ * Copyright (c) 2014-2025,  The University of Memphis,
  *                           Regents of the University of California,
  *                           Arizona Board of Regents.
  *
@@ -110,8 +110,8 @@
 const std::string SECTION_ADVERTISING =
   "advertising\n"
   "{\n"
-  "  prefix /ndn/edu/memphis/cs/netlab\n"
-  "  prefix /ndn/edu/memphis/sports/basketball\n"
+  "  /ndn/edu/memphis/cs/netlab 0\n"
+  "  /ndn/edu/memphis/sports/basketball 0\n"
   "}\n";
 
 // NEED TO TEST SECURITY SECTION SUCH AS LOADING CERTIFICATE
diff --git a/tests/update/test-save-delete-prefix.cpp b/tests/update/test-save-delete-prefix.cpp
index 5adec17..4f1d3a5 100644
--- a/tests/update/test-save-delete-prefix.cpp
+++ b/tests/update/test-save-delete-prefix.cpp
@@ -123,7 +123,7 @@
     // counter helps to check if multiple prefix of same name exists on conf file
     counter = 0;
     for (const auto& section : m_savePrefix.get_child("advertising")) {
-      auto b = section.second.get_value<std::string>();
+      auto b = section.first.data();
       if (b == prefixName) {
         counter++;
       }