#!/usr/bin/env bash

nfdConf='hub.nfd.conf'
systemNfdConf='/usr/local/etc/ndn/nfd.conf.sample'
testLog='hub.test.log'
nfdLog='hub.nfd.log'

LOG() {
    echo "[B] $1"
    echo "[B] $1" >>$testLog
}

kill_process() {
    # $1: name of process
    if [[ $# -lt 1 ]]; then
        echo "require process name"
        exit 1
    fi

    if pgrep -x $1 > /dev/null; then
        sudo -b killall -w "$1" >>$testLog 2>&1
    fi
}

delete_identity() {
    # $1: name of identity
    if [[ $(ndnsec-list | grep -c "$1$") -gt 0 ]]; then
        LOG " deleting identity $1!"
        ndnsec-delete $1 >>$testLog 2>&1
    else
        LOG " identity $1 does not exist"
    fi
}

clean_up() {
    LOG "Killing NFD process!"
    kill_process nfd
    kill_process ndn-autoconfig-server
}

prepare_for_test() {
    echo "Start test log on remote hub" >$testLog
    echo "Start nfd log on remote hub" >$nfdLog

    LOG "create nfd conf file with localhop_security section specified for test"
    [[ ! -f $systemNfdConf ]] && LOG "can not find nfd config file" && exit 1

    # copy the config file to the working directory
    cp $systemNfdConf $nfdConf

    # set UDP face timeout to 35 seconds
    infoedit -f $nfdConf -s face_system.udp.idle_timeout -v 35

    # insert a rule section to validate Interest
    cat <<EOF | infoedit -f $nfdConf -a rib.localhop_security.rule
id "NRD Prefix Registration Command Rule"
for interest
filter
{
   type name
   regex ^[<localhop><localhost>]<nfd><rib>[<register><unregister>]<>$
}
checker
{
   type customized
   sig-type rsa-sha256
   key-locator
   {
      type name
      regex ^[^<KEY>]*<KEY><>*[<ksk-.*>]<ID-CERT>$
   }
}
EOF

    #insert a rule section to validate Data
    cat <<EOF | infoedit -f $nfdConf -a rib.localhop_security.rule
id "NDN Testbed Hierarchy Rule"
for data
filter
{
  type name
  regex ^[^<KEY>]*<KEY><>*[<ksk-.*>]<ID-CERT><>*$
}
checker
{
  type customized
  sig-type rsa-sha256
  key-locator
  {
    type name
    regex ^[^<KEY>]*<KEY><>*[<ksk-.*>]<ID-CERT>$
  }
}
EOF

    #insert a trust-anchor section
    cat <<EOF | infoedit -f $nfdConf -a rib.localhop_security.trust-anchor
type file
file-name anchor.cert
EOF

    #delete remote_register section
    infoedit -f $nfdConf -d rib.auto_prefix_propagate

    kill_process nfd
    LOG "start NFD"
    sudo -b nohup nfd --config $nfdConf >>$nfdLog 2>&1 &
    sleep 2

    LOG "set multicast strategy for ndn:/"
    nfdc strategy set / /localhost/nfd/strategy/multicast >>$testLog 2>&1
    LOG "set autoreg prefix to /Z"
    nfd-autoreg --prefix=/Z >> $testLog 2>&1 &
}

while getopts "a:cp" arg
    do
        case $arg in
             c)
                 clean_up
                 ;;
             p)
                 prepare_for_test
                 ;;
             ?)
                 echo "unknown argument"
        exit 1
        ;;
        esac
done
