We recently discovered a security issue in lispflowmapping and an
explicitly configured authentication key is needed since the fix was
committed to allow southbound Map-Register messages to write into the
mapping database. This patch adds such a key for the Map-Register tests
to produce usable results (notifies/s graph has value 0).
Change-Id: I14bac6c92f040abce71f40a24c531b9ca8e312b3
Signed-off-by: Lorand Jakab <lojakab@cisco.com>
Library RequestsLibrary
Library String
Resource ../../../libraries/Utils.robot
Library RequestsLibrary
Library String
Resource ../../../libraries/Utils.robot
+Resource ../../../libraries/LISPFlowMapping.robot
Variables ../../../variables/Variables.py
*** Variables ***
Variables ../../../variables/Variables.py
*** Variables ***
Set Suite Variable ${get_seconds_mreq}
Generate Map-Register Test Traffic
Set Suite Variable ${get_seconds_mreq}
Generate Map-Register Test Traffic
+ Allow Unauthenticated Map-Registers
${result}= Run Process With Logging And Status Check /usr/local/bin/udpreplay --pps ${REPLAY_PPS} --repeat ${REPLAY_CNT}
... --host ${ODL_SYSTEM_IP} --port 4342 ${REPLAY_FILE_MREG}
${partial}= Fetch From Left ${result.stdout} s =
${result}= Run Process With Logging And Status Check /usr/local/bin/udpreplay --pps ${REPLAY_PPS} --repeat ${REPLAY_CNT}
... --host ${ODL_SYSTEM_IP} --port 4342 ${REPLAY_FILE_MREG}
${partial}= Fetch From Left ${result.stdout} s =
Log ${resp.content}
Should Be Equal As Strings ${resp.status_code} 200
Log ${resp.content}
Should Be Equal As Strings ${resp.status_code} 200
+Allow Unauthenticated Map-Registers
+ ${add_key}= OperatingSystem.Get File ${JSON_DIR}/rpc_add-key_default.json
+ Post Log Check ${LFM_RPC_API}:add-key ${add_key}
+
Get Transmitted Map-Requests Stats
${resp}= RequestsLibrary.Post Request session ${LFM_SB_RPC_API}:get-stats
Log ${resp.content}
Get Transmitted Map-Requests Stats
${resp}= RequestsLibrary.Post Request session ${LFM_SB_RPC_API}:get-stats
Log ${resp.content}
--- /dev/null
+{
+ "input": {
+ "eid": {
+ "address-type": "ietf-lisp-address-types:ipv4-prefix-afi",
+ "ipv4-prefix": "0.0.0.0/0"
+ },
+ "mapping-authkey": {
+ "key-type": 0
+ }
+ }
+}