From: Wouter van Doorn <wouter@vandoorn.tv>
To: Richard Beels <rbeels@yahoo.com>, cygwin@cygwin.com
Subject: Re: Challenge: a VERY strange problem with command substitution in bash
Date: Wed, 12 Jul 2017 06:08:00 -0000 [thread overview]
Message-ID: <CANZ2p_e3NLaQGFyjXHP3UGjkAiUh6YhfiZYYCRnQ+ecCfMrjxA@mail.gmail.com> (raw)
In-Reply-To: <59655e58.d532240a.ae3d8.4253SMTPIN_ADDED_MISSING@mx.google.com>
I bet Comodo is the golden tip. They have introduced whitelisting
without telling anyone, and I have had very strange behaviour (strange
until that whitelist explained it) too. Including that subshell thing.
They call it 'auto-containment'. Just disable that, and done.
Wouter
On 12 July 2017 at 00:22, Richard Beels via cygwin <cygwin@cygwin.com> wrote:
> At 07/11/2017 at 15:12, Shakespearean monkeys danced on Jürgen Wagner's
> keyboard and said:
>>
>> ...
>> Using backquotes instead of the command substitution with $(...) does not
>> change the results. I could swear this did work in an earlier version of
>> Cygwin on my Windows 7 machine.
>>
>> I tried this to see if the code in the parentheses is executed at all:
>>
>> $ value="$( date 2> foo | cat )"; echo "$? <$value>"
>>
>> The file "foo" was not created, i.e., it seems the commands don't really
>> get executed.
>>
>> $ value="$( date && pwd )"; echo "$? <$value>"
>> 0 <Tue Jul 11 20:49:09 CEST 2017
>> /home/juergen>
>>
>> $ value="$( date || pwd )"; echo "$? <$value>"
>> 0 <Tue Jul 11 20:32:27 CEST 2017>
>>
>> both work, so some control structures seem to be permissible... just not a
>> pipe.
>>
>> What is going on? Some misconfiguration? A Cygwin bug? Some interaction
>> with something weird in Windows 10? I am at loss to understand what could be
>> wrong... and am now most curious whether anybody has an idea what is causing
>> this. Does it work/not work in the same way in your Cygwin installation?
>>
>> I came across this effect because ssh-host-config did not recognize me as
>> administrator anymore. It's due to a check for a certain user group that
>> uses a command substitution with a pipe. Replacing this with an equivalent
>> command works. The original line used "id -G" and then a "grep -Eq" to check
>> whether a certain group is on that list.
>>
>> I am VERY curious now! I've rarely been puzzled that much by such a very
>> elementary shell expression (looking back at 34 years of Unix experience).
>
>
>
> Hi Jurgen.
>
> 90% chance it's what is called bloda in these parts. It's in the FAQ on
> cygwin.com. I'll go out on a limb and say you might have just
> installed/changed your AV/Firewall software.
>
> And if I want to be super-psychic, can I guess comodo? Because I just
> changed to comodo a couple weeks ago and had the same subshell/command
> substitution/pipeline errors you're mentioning.
>
> If so, you need to exclude your cygwin folder from AV scanning. AND... if
> the software does whitelisting or host intrusion protection (HIPS) or "run
> unknown executables in a container/sandbox" or something similar, you also
> need to trust all the executables, too. Or switch to something else that
> doesn't trip cygwin's trigger.
>
> After doing that and a rebaseall, I haven't had a fork error in a week. I
> can't wait to run setup and come up with an update process, though...
>
> Cheers!
>
>
>
> --
> Problem reports: http://cygwin.com/problems.html
> FAQ: http://cygwin.com/faq/
> Documentation: http://cygwin.com/docs.html
> Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
>
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
next prev parent reply other threads:[~2017-07-12 6:08 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-11 19:12 Jürgen Wagner
2017-07-11 19:16 ` Jürgen Wagner
2017-07-11 20:40 ` Jürgen Wagner
2017-07-11 23:22 ` Steven Penny
2017-07-11 23:24 ` Richard Beels via cygwin
[not found] ` <59655e58.d532240a.ae3d8.4253SMTPIN_ADDED_MISSING@mx.google.com>
2017-07-12 6:08 ` Wouter van Doorn [this message]
[not found] ` <20170711232506.02CE91C3666@atlantis.udag.de>
2017-07-28 18:03 ` Jürgen Wagner
2017-12-04 13:01 Erik Haukjær Andersen
2017-12-04 13:22 ` David Macek
2017-12-04 21:41 ` Brian Inglis
2017-12-04 20:20 ` Andrey Repin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CANZ2p_e3NLaQGFyjXHP3UGjkAiUh6YhfiZYYCRnQ+ecCfMrjxA@mail.gmail.com \
--to=wouter@vandoorn.tv \
--cc=cygwin@cygwin.com \
--cc=rbeels@yahoo.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).