Re: Using Source within Binary Shell Scripts

2019-03-27 Thread Chet Ramey
On 3/27/19 2:22 PM, Al Payne wrote: > On Wed, Mar 27, 2019 at 09:09:37AM -0700, Eduardo Bustamante wrote: >> On Wed, Mar 27, 2019 at 8:17 AM Jason Hall wrote: >> (...) >>> The point is, their is a legitimate use for sourcing Binary Shell >>> Scripts (...) >> >> Is it really a legitimate use? If yo

Re: Using Source within Binary Shell Scripts

2019-03-27 Thread Al Payne
On Wed, Mar 27, 2019 at 09:09:37AM -0700, Eduardo Bustamante wrote: > On Wed, Mar 27, 2019 at 8:17 AM Jason Hall wrote: > (...) > > The point is, their is a legitimate use for sourcing Binary Shell > > Scripts (...) > > Is it really a legitimate use? If you're doing it for "security" (by > obscur

Re: Feature request or advice on implementation for buffering command output

2019-03-27 Thread Chet Ramey
On 3/27/19 3:49 AM, Anders Brujordet wrote: > Usecase: > You run a command, the output is displayed in your terminal. Now that you > see the output, you would like to grab say an ID from this output. Instead > of coping and pasting the output, I would like to be able to do something > like: > # gre

Re: Using Source within Binary Shell Scripts

2019-03-27 Thread Eduardo Bustamante
On Wed, Mar 27, 2019 at 8:17 AM Jason Hall wrote: (...) > The point is, their is a legitimate use for sourcing Binary Shell > Scripts (...) Is it really a legitimate use? If you're doing it for "security" (by obscurity I guess?), it's easy to defeat. > and BASH as is, won't let you do this. May

Using Source within Binary Shell Scripts

2019-03-27 Thread Jason Hall
I was provided a shell script that is self decrypting, self unzipping, and checks if the file has been tampered with using an encrypted MD5 sum. The file uses the filename, command line parameters and some trial data to create the encryption key in a shell variable which it uses to decrypt an embe

Re: Feature request or advice on implementation for buffering command output

2019-03-27 Thread Greg Wooledge
On Wed, Mar 27, 2019 at 12:49:45AM -0700, Anders Brujordet wrote: > Usecase: > You run a command, the output is displayed in your terminal. Now that you > see the output, you would like to grab say an ID from this output. Instead > of coping and pasting the output, I would like to be able to do som

Feature request or advice on implementation for buffering command output

2019-03-27 Thread Anders Brujordet
Usecase: You run a command, the output is displayed in your terminal. Now that you see the output, you would like to grab say an ID from this output. Instead of coping and pasting the output, I would like to be able to do something like: # grep 'the thing that you want' <<< ${COMMAND_OUTPUT} | ./so

Re[9]: Subshell exit trap is not invoked if shell exit trap also set

2019-03-27 Thread Konstantin Andreev
Al, thank you for your time. Being under the impression of your experiment, I went back to my setup, looked at it thoughtfully for a while, and realized that bash-5.* ... if fact works. There was a unfortunate mistake of mine: I launched [ssxtrap] from inside interactive bash-5, but ... as [./