home

Supported platforms

Vyatta documentation

Learn how to install, configure, and operate the Vyatta Network Operating System (Vyatta NOS) and Orchestrator, which help drive our virtual networking and physical platforms portfolio.

Authentication

When using the twping CLI command, you must specify the authentication mode. However, when invoking a twping RPC call, you do not have to explicitly specify the authentication mode because, by default, the mode is set to authenticate. However, you must specify a username and passphrase because RPC calls do not support interactive prompts.

The following example shows how to specify the authentication mode when running the twping CLI command. After entering the command, the CLI prompts you for a passphrase. After you enter the passphrase, the vRouter pings the TWAMP server and displays the results.

v@vyatta:~$ twping localhost auth-mode authenticate user v
Enter passphrase for identity 'v': 
Approximately 13.2 seconds until results available
--- twping statistics from [localhost]:8904 to [localhost]:44984 ---
SID:    00000001da3a464baf1eeada687abc61

The following example shows two twping RPC calls. The first call does not specify the authentication mode, but the second call does. Both calls specify a user and the corresponding passphrase.

<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="3">
  <twping xmlns="urn:vyatta.com:mgmt:vyatta-service-twamp:1">
    <host>localhost</host>
    <authentication>
      <user>user1</user>
      <passphrase>example-passphrase</passphrase>
    </authentication>
  </twping>
</rpc>]]>]]>

<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="3">
  <twping xmlns="urn:vyatta.com:mgmt:vyatta-service-twamp:1">
    <host>localhost</host>
    <authentication>
      <mode>authenticate</mode>
      <user>user1</user>
      <passphrase>example-passphrase</passphrase>
    </authentication>
  </twping>
</rpc>]]>]]>