Path: csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.026 X-Spam-Evidence: '*H*': 0.95; '*S*': 0.00; 'skip:/ 10': 0.09; 'cc:addr :python-list': 0.11; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'nesting': 0.16; 'password,': 0.16; 'raised.': 0.16; 'sudo': 0.16; 'wrote:': 0.18; 'wed,': 0.18; 'command': 0.22; 'cc:addr:python.org': 0.22; 'this?': 0.23; 'instance,': 0.24; 'passes': 0.24; 'cc:2**0': 0.24; 'second': 0.26; 'header:In-Reply- To:1': 0.27; 'tim': 0.29; 'bigger': 0.30; 'message- id:@mail.gmail.com': 0.30; 'concern': 0.31; 'but': 0.35; 'received:google.com': 0.35; 'problems': 0.38; 'nov': 0.38; 'pm,': 0.38; 'rather': 0.38; 'quote': 0.39; 'first': 0.61; 'needing': 0.65; '26,': 0.68; 'compare:': 0.84; 'to:none': 0.92 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=k/0vUkjZFnoZBl6HMnDxb4rwlAtTyWixY6EkViNP95A=; b=SIrbXolbd8XF9lWta2X3YUR9r4bc+DbArsqyXHOhFboT3a2iUm7eTrKb4JWZq4TALG nT/wr7rTHwz5G8lQVzt/AmdYrS4iO/XcqepXtCH0Cb51ybgbBLKr0utW0fOTzq6M6KOK UA4m9ULX6A4M4i9BRgKNP9RFnZxOq3L6yJGn4IVhyu4qEu3eD37Cw+Eg8g+F1z0BYT1n VBrGF2FLS5Glipg/9vtdVhfROnyqV1ADn07/Vdm4X8ORNXlcEySqRLLPTG3+d7uS5hYm BeLAEYfO8WI0VTRv1LdZoga7XtZyHBHpLICwrht4nXYUksf59o7kSrGQtSDQQsy5og/0 SE9g== MIME-Version: 1.0 X-Received: by 10.42.130.194 with SMTP id w2mr9484031ics.12.1416985809602; Tue, 25 Nov 2014 23:10:09 -0800 (PST) In-Reply-To: <54756D5F.4040806@tundraware.com> References: <54756D5F.4040806@tundraware.com> Date: Wed, 26 Nov 2014 18:10:09 +1100 Subject: Re: Quotation Ugliness From: Chris Angelico Cc: "python-list@python.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 23 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1416985812 news.xs4all.nl 2918 [2001:888:2000:d::a6]:51606 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:81551 On Wed, Nov 26, 2014 at 5:04 PM, Tim Daneliuk wrote: > Here's a usecase - I want to know whether I need > to use a sudo password when the user passes a command on the command line > of a program: > > someprog.py uname && sudo cat /etc/sudoers > > vs. > > someprog.py uname && echo "sudo cat /etc/suoders" > > > In the first instance, I need the sudo passoword, in the second I don't. This is actually needing the nesting concern that I raised. Compare: someprog.py uname " ' " && sudo cat /etc/sudoers But frankly, you have much MUCH bigger problems than quote characters. Why not set up sudo to not require a password, rather than fiddling with this? ChrisA