(CommandList children: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:homedir) op:Equal rhs:{(DQ (/home))} spids:[8])] spids: [8] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:secs) op:Equal rhs:{(10)} spids:[16])] spids: [16] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-z)} {($ VSub_Number '$1')} {(Lit_Other ']')}) terminator: <Op_Semi ';'> ) ] action: [ (Sentence child: (SimpleCommand words: [{(echo)} {(DQ ('Usage: ') ($ VSub_Number '$0') (' account'))}] redirects: [(Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) terminator: <Op_Semi ';'> ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [16777215 35] ) (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} { (DQ (CommandSubPart command_list: (CommandList children:[(C {(id)} {(-un)})]) left_token: <Left_CommandSub '$('> spids: [60 64] ) ) } {(KW_Bang '!') (Lit_Other '=')} {(DQ (root))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Sentence child: (SimpleCommand words: [{(echo)} {(DQ ("Error. You must be 'root' to run this command."))}] redirects: [(Redir op:<Redir_GreatAnd '>&'> fd:16777215 arg_word:{(2)})] ) terminator: <Op_Semi ';'> ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(1)}) ] spids: [55 78] ) ] spids: [16777215 95] ) (C {(echo)} {(DQ ('Please change account ') ($ VSub_Number '$1') (' password to something new.'))}) (C {(passwd)} {($ VSub_Number '$1')}) (If arms: [ (if_arm cond: [ (Sentence child: (Pipeline children: [ (C {(who)}) (SimpleCommand words: [{(grep)} {(DQ ($ VSub_Number '$1'))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(/dev/null)})] ) ] negated: F ) terminator: <Op_Semi ';'> ) ] action: [ (ForEach iter_name: tty iter_words: [ { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(who)}) (C {(grep)} {($ VSub_Number '$1')}) (C {(awk)} {(SQ <'{print $2}'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [140 156] ) } ] do_arg_iter: F body: (DoGroup children: [ (SimpleCommand words: [{(cat)}] redirects: [ (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(DQ (EOF))} here_end_span_id: 187 stdin_parts: [ ('\n') ('*************************************************************\n') ('URGENT NOTICE FROM THE ADMINISTRATOR:\n') ('\n') ( 'This account is being suspended, and you are going to be logged out \n' ) ('in $secs seconds. Please immediately shut down any processes you \n') ('have running and log out.\n') ('\n') ('If you have any questions, please contact your supervisor or \n') ('John Doe, Director of Information Technology.\n') ('*************************************************************\n') ] ) (Redir op: <Redir_Great '>'> fd: 16777215 arg_word: {(/dev/) ($ VSub_Name '$tty')} ) ] ) ] spids: [159 189] ) spids: [139 157] ) (C {(echo)} { (DQ ('(Warned ') ($ VSub_Number '$1') (', now sleeping ') ($ VSub_Name '$secs') (' seconds)') ) } ) (C {(sleep)} {($ VSub_Name '$secs')}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:jobs) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(ps)} {(-u)} {($ VSub_Number '$1')}) (C {(cut)} {(-d) (EscapedLiteralPart token:<Lit_EscapedChar '\\ '>)} {(-f1)} ) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [212 227] ) } spids: [211] ) ] spids: [211] ) (C {(kill)} {(-s)} {(HUP)} {($ VSub_Name '$jobs')}) (C {(sleep)} {(1)}) (SimpleCommand words: [{(kill)} {(-s)} {(KILL)} {($ VSub_Name '$jobs')}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(/dev/null)}) (Redir op:<Redir_Great '2>'> fd:2 arg_word:{(1)}) ] ) (C {(echo)} {(DQ ($ VSub_Number '$1') (' was logged in. Just logged them out.'))}) ] spids: [16777215 130] ) ] spids: [16777215 278] ) (C {(chmod)} {(000)} {($ VSub_Name '$homedir') (/) ($ VSub_Number '$1')}) (C {(echo)} {(DQ ('Account ') ($ VSub_Number '$1') (' has been suspended.'))}) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(0)}) ] )