(command.CommandList children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:SOCK_LOCAL) op: assign_op.Equal rhs: {<unix> <Id.Lit_Colon ':'> <'//commsock1'>} spids: [83] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:SOCK_PEER) op: assign_op.Equal rhs: {<unix> <Id.Lit_Colon ':'> <'//commsock2'>} spids: [88] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:SOCK_GW) op: assign_op.Equal rhs: {<unix> <Id.Lit_Colon ':'> <'//commsock3'>} spids: [93] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:BUS) op: assign_op.Equal rhs: {<bus1>} spids: [98] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:BUS2) op: assign_op.Equal rhs: {<bus2>} spids: [101] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:REDIRECT_TIMEOUT) op: assign_op.Equal rhs: {<5>} spids: [104] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:DEBUG) op: assign_op.Equal rhs: { (braced_var_sub token: <Id.VSub_Name DEBUG> suffix_op: (suffix_op.Unary tok:<Id.VTest_ColonHyphen ':-'> arg_word:{<false>}) ) } spids: [108] ) ] ) (C {<atf_test_case>} {<icmp_redirect_timeout>} {<cleanup>}) (command.ShFunction name: icmp_redirect_timeout_head body: (BraceGroup children: [ (command.Sentence child: (C {<atf_set>} {(DQ <descr>)} {(DQ <'Tests for ICMP redirect timeout'>)}) terminator: <Id.Op_Semi _> ) (command.Sentence child: (C {<atf_set>} {(DQ <require.progs>)} {(DQ <rump_server>)}) terminator: <Id.Op_Semi _> ) ] ) ) (command.ShFunction name: setup_local body: (BraceGroup children: [ (C {<rump_server_start>} {($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<rump_server_add_iface>} {($ Id.VSub_DollarName '$SOCK_LOCAL')} {<shmif0>} {($ Id.VSub_DollarName '$BUS')} ) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif0>} {<'10.0.0.2/24'>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif0>} {<up>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.sysctl>} {<-w>} {<net.inet.icmp.redirtimeout> <Id.Lit_Equals '='> ($ Id.VSub_DollarName '$REDIRECT_TIMEOUT')} ) (command.AndOr ops: [Id.Op_DAmp] children: [(C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.ifconfig>})] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) ] ) ) (command.ShFunction name: setup_peer body: (BraceGroup children: [ (C {<rump_server_start>} {($ Id.VSub_DollarName '$SOCK_PEER')}) (C {<rump_server_add_iface>} {($ Id.VSub_DollarName '$SOCK_PEER')} {<shmif0>} {($ Id.VSub_DollarName '$BUS')} ) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif0>} {<'10.0.0.1/24'>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif0>} {<up>} ) (command.AndOr ops: [Id.Op_DAmp] children: [(C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.ifconfig>})] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) ] ) ) (command.ShFunction name: setup_gw body: (BraceGroup children: [ (C {<rump_server_start>} {($ Id.VSub_DollarName '$SOCK_GW')}) (C {<rump_server_add_iface>} {($ Id.VSub_DollarName '$SOCK_GW')} {<shmif0>} {($ Id.VSub_DollarName '$BUS')} ) (C {<rump_server_add_iface>} {($ Id.VSub_DollarName '$SOCK_GW')} {<shmif1>} {($ Id.VSub_DollarName '$BUS2')} ) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_GW')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif0>} {<'10.0.0.254/24'>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif0>} {<up>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif1>} {<'10.0.2.1/24'>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif1>} {<alias>} {<'10.0.2.2/24'>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<shmif1>} {<up>} ) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ifconfig>} {<-w>} {<10>} ) (C {<atf_check>} {<-s>} {<not-exit> <Id.Lit_Colon ':'> <0>} {<-x>} {(DQ <'rump.ifconfig shmif1 |grep -q tentative'>)} ) (command.AndOr ops: [Id.Op_DAmp] children: [(C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.ifconfig>})] ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) ] ) ) (command.ShFunction name: icmp_redirect_timeout_body body: (BraceGroup children: [ (command.AndOr ops: [Id.Op_DAmp] children: [(C {($ Id.VSub_DollarName '$DEBUG')}) (C {<ulimit>} {<-c>} {<unlimited>})] ) (C {<setup_local>}) (C {<setup_peer>}) (C {<setup_gw>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.route>} {<add>} {<-net>} {<'10.0.2.0/24'>} {<10.0.0.254>} ) (C {<check_route_flags>} {<'10.0.2/24'>} {<UGS>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.route>} {<add>} {<default>} {<10.0.0.1>} ) (C {<check_route_flags>} {<default>} {<UGS>}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ping>} {<-n>} {<-w>} {<1>} {<-c>} {<1>} {<10.0.2.1>} ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) (C {<check_route_flags>} {<10.0.2.1>} {<UGHD>}) (C {<check_route_gw>} {<10.0.2.1>} {<10.0.0.254>}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<sleep>} { (word_part.ArithSub anode: (arith_expr.Binary op_id: Id.Arith_Plus left: <Id.Lit_ArithVarLike REDIRECT_TIMEOUT> right: {<Id.Lit_Digits 2>} ) ) } ) (C {<check_route_no_entry>} {<10.0.2.1>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) (C {<rump_server_destroy_ifaces>}) ] ) ) (command.ShFunction name: icmp_redirect_timeout_cleanup body: (BraceGroup children: [ (command.AndOr ops: [Id.Op_DAmp] children: [(C {($ Id.VSub_DollarName '$DEBUG')}) (C {<dump>})] ) (C {<cleanup>}) ] ) ) (C {<atf_test_case>} {<icmp_redirect>} {<cleanup>}) (command.ShFunction name: icmp_redirect_head body: (BraceGroup children: [ (command.Sentence child: (C {<atf_set>} {(DQ <descr>)} {(DQ <'Tests for icmp redirect'>)}) terminator: <Id.Op_Semi _> ) (command.Sentence child: (C {<atf_set>} {(DQ <require.progs>)} {(DQ <rump_server>)}) terminator: <Id.Op_Semi _> ) ] ) ) (command.ShFunction name: setup_redirect body: (BraceGroup children: [ (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.sysctl>} {<-w>} {<net.inet.ip.redirect> <Id.Lit_Equals '='> <1>} ) ] ) ) (command.ShFunction name: teardown_redirect body: (BraceGroup children: [ (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.sysctl>} {<-w>} {<net.inet.ip.redirect> <Id.Lit_Equals '='> <0>} ) ] ) ) (command.ShFunction name: icmp_redirect_body body: (BraceGroup children: [ (command.AndOr ops: [Id.Op_DAmp] children: [(C {($ Id.VSub_DollarName '$DEBUG')}) (C {<ulimit>} {<-c>} {<unlimited>})] ) (C {<setup_local>}) (C {<setup_peer>}) (C {<setup_gw>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.route>} {<add>} {<-net>} {<'10.0.2.0/24'>} {<10.0.0.254>} ) (C {<check_route_flags>} {<'10.0.2/24'>} {<UGS>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.route>} {<add>} {<default>} {<10.0.0.1>} ) (C {<check_route_flags>} {<default>} {<UGS>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (C {<teardown_redirect>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ping>} {<-n>} {<-w>} {<1>} {<-c>} {<1>} {<10.0.2.1>} ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) (C {<check_route_no_entry>} {<10.0.2.1>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (C {<setup_redirect>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ping>} {<-n>} {<-w>} {<1>} {<-c>} {<1>} {<10.0.2.1>} ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) (C {<check_route_flags>} {<10.0.2.1>} {<UGHD>}) (C {<check_route_gw>} {<10.0.2.1>} {<10.0.0.254>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.route>} {<delete>} {<10.0.2.1>} ) (C {<check_route_no_entry>} {<10.0.2.1>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_PEER')}) (C {<teardown_redirect>}) (C {<export>} {<Id.Lit_VarLike 'RUMP_SERVER='> ($ Id.VSub_DollarName '$SOCK_LOCAL')}) (C {<atf_check>} {<-s>} {<Id.ControlFlow_Exit exit> <Id.Lit_Colon ':'> <0>} {<-o>} {<ignore>} {<rump.ping>} {<-n>} {<-w>} {<1>} {<-c>} {<1>} {<10.0.2.1>} ) (command.AndOr ops: [Id.Op_DAmp] children: [ (C {($ Id.VSub_DollarName '$DEBUG')}) (C {<rump.netstat>} {<-rn>} {<-f>} {<inet>}) ] ) (C {<check_route_no_entry>} {<10.0.2.1>}) (C {<rump_server_destroy_ifaces>}) ] ) ) (command.ShFunction name: icmp_redirect_cleanup body: (BraceGroup children: [ (command.AndOr ops: [Id.Op_DAmp] children: [(C {($ Id.VSub_DollarName '$DEBUG')}) (C {<dump>})] ) (C {<cleanup>}) ] ) ) (command.ShFunction name: atf_init_test_cases body: (BraceGroup children: [ (C {<atf_add_test_case>} {<icmp_redirect>}) (C {<atf_add_test_case>} {<icmp_redirect_timeout>}) ] ) ) ] )