tcp_client_c2c_tcp_relay.sh 1.0 KB

12345678910111213141516171819202122232425
  1. #!/bin/sh
  2. #
  3. # This is an example of a script to run a "unsecure" TURN TCP client
  4. # with TCP relay endpoints (RFC 6062).
  5. # Options:
  6. # 1) -T is present, it means that TCP networking is used with TCP relay endpoints.
  7. # 5) -n 1000 means 1000 messages per single emulated client. Messages
  8. # are sent with interval of 20 milliseconds, to emulate an RTP stream.
  9. # 6) -m 10 means that 10 clients are emulated.
  10. # 7) -l 170 means that the payload size of the packets is 170 bytes
  11. # (like average audio RTP packet).
  12. # 8) -y means that the clients will connect to the 'neighbor' clients, no peer app will be used.
  13. # 9) -g means "set DONT_FRAGMENT parameter in TURN requests".
  14. # 10) ::1 (the last parameter) is the TURN Server IP address. We use IPv6 here
  15. # to illustrate how the TURN Server convert the traffic from IPv6 to IPv4 and back.
  16. #
  17. if [ -d examples ] ; then
  18. cd examples
  19. fi
  20. export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/usr/local/lib/
  21. PATH=examples/bin/:../bin:bin/:${PATH} turnutils_uclient -T -n 1000 -m 10 -l 170 -y -g $@ ::1