+++ /dev/null
-#!/bin/bash
-> curl_log.txt
-TRACE="--trace-ascii curl_log.txt"
-SERVER=`cat .httpServer`
-
-echo
-echo
-echo "Use: $0 [xml_file] [2e]"
-echo
-echo "Programm 'xml_file' answer to the diameter client or to the server (entity) when"
-echo "'2e' parameter is provided. If missing xml file, current programmed answers will"
-echo "be shown: '$0' (answers to client), '$0 2e' (answers to server)."
-echo
-if test "$1" != ""
-then
- if test "$1" = "2e"
- then
- operation="answerxml2e"
- else
- [[ ! -f "$1" ]] && { echo "ERROR: file '$1' not found" ; echo; echo; exit ; }
- operation="answerxml|$1"
- [[ "$2" = "2e" ]] && operation="answerxml2e|$1"
- fi
-else
- operation="answerxml"
-fi
-echo
-curl -m 1 --data "$operation" $TRACE ${SERVER}
-