From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from tb-mx1.topicbox.com (localhost.local [127.0.0.1]) by tb-mx1.topicbox.com (Postfix) with ESMTP id B10FB4BD9799 for <9fans@9fans.net>; Fri, 5 Jun 2020 08:45:40 -0400 (EDT) (envelope-from eekee57@fastmail.fm) Received: from tb-mx1.topicbox.com (localhost [127.0.0.1]) by tb-mx1.topicbox.com (Authentication Milter) with ESMTP id 6B83D94A8D3; Fri, 5 Jun 2020 08:45:40 -0400 ARC-Seal: i=1; a=rsa-sha256; cv=none; d=topicbox.com; s=arcseal; t= 1591361140; b=KvrE/47KCgMHYim0OB1lU6TTqEElJHYr4robtqW7ZJdSZprnxW mLc66yBCy/YywCpUCaEF/G5Kld+Dcv5yoINrd3+09rB6S3+kO4bUxTF++qckQqij Mc6PQ8P2Jk5GioD7kAmIuuIKNkDASQIlnfjwLGtwtoEQ5qhBaQNvO9Q60jP00hqf drjbanEkf8Sa9K+G1awSxRcjX28D+xhDc3oZEqEWwDrv2GDTHoba+/DbS1uCtKxn 3nA7UK9iUclPrdtZj82gr546gDj8kgGMXeRSPHPfbOGjSA+qmWCGw43GaN1JXIj4 4CWKggFaR2QKNMeHUqAhynNxL+rkwNXSYlFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d= topicbox.com; h=mime-version:message-id:date:from:to:subject :content-type; s=arcseal; t=1591361140; bh=hnZLqAD3Knsc+Lw/s8Sd7 CmUIP2eIliEZGUUhfWB7/I=; b=Mx1cbgMbWTlsNUBhKZJgppUWckACF+aGCdAHT 65rgAhDEciEz+RM7CGcWoe7nOIvZI2ch+Cu+VGjGdUXKTeIb7lP1MKtBTvBZXZWh Gx02s1QC0da4fYDyQ9dDQpLnS1LZFNQREUtJPfnX0mtUfrx0MhQZCsUIKb2hHGtv oELKJVGbpJWjCQBALFVbk/yxMDq7RfYpssArhKNIOx0TQwl6ZZuP4RSFsqZjySsL JjP0foULPPlyWwVPbHEN73vKHTFA6dzYlv6RCCYZ8aX2tyX3OIUKXiX5mPfs5/wz zki55ixzu41vIDY7RVF7ThAKqPWtyEbQTBThG2f+FbHaZFy4w== ARC-Authentication-Results: i=1; tb-mx1.topicbox.com; arc=none (no signatures found); bimi=none (Domain is not BIMI enabled); dkim=pass (2048-bit rsa key sha256) header.d=fastmail.fm header.i=@fastmail.fm header.b=wBG3OeBs header.a=rsa-sha256 header.s=fm3 x-bits=2048; dkim=pass (2048-bit rsa key sha256) header.d=messagingengine.com header.i=@messagingengine.com header.b=JOKydMDF header.a=rsa-sha256 header.s=fm3 x-bits=2048; dmarc=pass policy.published-domain-policy=none policy.applied-disposition=none policy.evaluated-disposition=none (p=none,d=none,d.eval=none) policy.policy-from=p header.from=fastmail.fm; iprev=pass smtp.remote-ip=64.147.123.20 (wout4-smtp.messagingengine.com); spf=pass smtp.mailfrom=eekee57@fastmail.fm smtp.helo=wout4-smtp.messagingengine.com; x-aligned-from=pass (Address match); x-ptr=pass smtp.helo=wout4-smtp.messagingengine.com policy.ptr=wout4-smtp.messagingengine.com; x-return-mx=pass header.domain=fastmail.fm policy.is_org=yes (MX Records found: in1-smtp.messagingengine.com,in2-smtp.messagingengine.com); x-return-mx=pass smtp.domain=fastmail.fm policy.is_org=yes (MX Records found: in1-smtp.messagingengine.com,in2-smtp.messagingengine.com); x-tls=pass smtp.version=TLSv1.2 smtp.cipher=ECDHE-RSA-AES256-GCM-SHA384 smtp.bits=256/256; x-vs=clean score=0 state=0 Authentication-Results: tb-mx1.topicbox.com; arc=none (no signatures found); bimi=none (Domain is not BIMI enabled); dkim=pass (2048-bit rsa key sha256) header.d=fastmail.fm header.i=@fastmail.fm header.b=wBG3OeBs header.a=rsa-sha256 header.s=fm3 x-bits=2048; dkim=pass (2048-bit rsa key sha256) header.d=messagingengine.com header.i=@messagingengine.com header.b=JOKydMDF header.a=rsa-sha256 header.s=fm3 x-bits=2048; dmarc=pass policy.published-domain-policy=none policy.applied-disposition=none policy.evaluated-disposition=none (p=none,d=none,d.eval=none) policy.policy-from=p header.from=fastmail.fm; iprev=pass smtp.remote-ip=64.147.123.20 (wout4-smtp.messagingengine.com); spf=pass smtp.mailfrom=eekee57@fastmail.fm smtp.helo=wout4-smtp.messagingengine.com; x-aligned-from=pass (Address match); x-ptr=pass smtp.helo=wout4-smtp.messagingengine.com policy.ptr=wout4-smtp.messagingengine.com; x-return-mx=pass header.domain=fastmail.fm policy.is_org=yes (MX Records found: in1-smtp.messagingengine.com,in2-smtp.messagingengine.com); x-return-mx=pass smtp.domain=fastmail.fm policy.is_org=yes (MX Records found: in1-smtp.messagingengine.com,in2-smtp.messagingengine.com); x-tls=pass smtp.version=TLSv1.2 smtp.cipher=ECDHE-RSA-AES256-GCM-SHA384 smtp.bits=256/256; x-vs=clean score=0 state=0 X-ME-VSCause: gggruggvucftvghtrhhoucdtuddrgeduhedrudefkedgleeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdggtfgfnhhsuhgsshgtrhhisggvpdfu rfetoffkrfgpnffqhgenuceurghilhhouhhtmecufedttdenucenucfjughrpefofgggkf ffhffvufgtsehttdertderredtnecuhfhrohhmpedfgfhthhgrnhcuifgrrhguvghnvghr fdcuoegvvghkvggvheejsehfrghsthhmrghilhdrfhhmqeenucggtffrrghtthgvrhhnpe dugffgvddvteelgfetteefudfguedtkeekgfefteejgeeikeffgeetudegtdekieenucfk phepieegrddugeejrdduvdefrddvtdenucevlhhushhtvghrufhiiigvpedtnecurfgrrh grmhepihhnvghtpeeigedrudegjedruddvfedrvddtpdhhvghlohepfihouhhtgedqshhm thhprdhmvghsshgrghhinhhgvghnghhinhgvrdgtohhmpdhmrghilhhfrhhomhepoegvvg hkvggvheejsehfrghsthhmrghilhdrfhhmqecuuffkkgfgpeegudejgedpmhgrihhlfhhr ohhmpegvvghkvggvheejsehfrghsthhmrghilhdrfhhm X-ME-VSScore: 0 X-ME-VSCategory: clean Received-SPF: pass (fastmail.fm: Sender is authorized to use 'eekee57@fastmail.fm' in 'mfrom' identity (mechanism 'include:spf.messagingengine.com' matched)) receiver=tb-mx1.topicbox.com; identity=mailfrom; envelope-from="eekee57@fastmail.fm"; helo=wout4-smtp.messagingengine.com; client-ip=64.147.123.20 Received: from wout4-smtp.messagingengine.com (wout4-smtp.messagingengine.com [64.147.123.20]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by tb-mx1.topicbox.com (Postfix) with ESMTPS for <9fans@9fans.net>; Fri, 5 Jun 2020 08:45:40 -0400 (EDT) (envelope-from eekee57@fastmail.fm) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.west.internal (Postfix) with ESMTP id 12DCA48E for <9fans@9fans.net>; Fri, 5 Jun 2020 08:45:39 -0400 (EDT) Received: from imap35 ([10.202.2.85]) by compute1.internal (MEProxy); Fri, 05 Jun 2020 08:45:39 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= mime-version:message-id:date:from:to:subject:content-type; s= fm3; bh=hnZLqAD3Knsc+Lw/s8Sd7CmUIP2eIliEZGUUhfWB7/I=; b=wBG3OeBs 4USyTuWkyF1jbOLgOzvSeiZyt27nTOxYupJ7DcWu4C94OzY77TTtEdylBLFKgzhp sF9UsGuCfAPCCY6szm7+ryU6Z5aH7+yBel8r99yzY+vLyUCD6HMfyxaHWCI16Ahc D588ZNEGWH9TeOfrfEIUSKBg46R3pcTBaS/mbZyVzwB+mVJErbpGpiWT0nr+5ivW Vs5k9kEFm22UhcNff0IioN3mOavus7KxJW/IC+E4unUPau4vKVRjNXWwMzphJMAk Texgf4zhW+0nJ3psAngUqBPDeNcQXX0XKQ1BjKKskEurOFQHLDoo5nPlue8WjFJ2 WrDla8wlzP7xcQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:message-id :mime-version:subject:to:x-me-proxy:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; bh=hnZLqAD3Knsc+Lw/s8Sd7CmUIP2eI liEZGUUhfWB7/I=; b=JOKydMDFjzOfgwfGfa/MICF9kEzNx00qi5P03jIC51dU/ npl855JUUXDWJYJUbyW3jM76yF62IQn2+lGBZ3VoLkv9Fp4WOhXUM+k+5KLJlvML WpyWIKPScKJpuLNaTocL9R8XtQmvAfgU7cdad+9gLpR650ANfsWFgM5AC5ILZlq8 o3wEdNGg4F1Yq32cvLCgv2l1jOniUoDjL/taEphyHkAX2oaTol2/qkBab8/hqnuA TRvGX0Kx5mBfMOSkgfmV7qnqdCl1penPNLextPvHZrIK2JNrF6raW3CqssnqkKpY MIMyT0jltSmUlpPgX/DR4BXRtiSGjfQY5W8O2KlMQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedrudegfedggeejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefofgggkfffhffvufgtsehttdertd erredtnecuhfhrohhmpedfgfhthhgrnhcuifgrrhguvghnvghrfdcuoegvvghkvggvheej sehfrghsthhmrghilhdrfhhmqeenucggtffrrghtthgvrhhnpedugffgvddvteelgfette efudfguedtkeekgfefteejgeeikeffgeetudegtdekieenucevlhhushhtvghrufhiiigv pedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegvvghkvggvheejsehfrghsthhmrghilh drfhhm X-ME-Proxy: Received: by mailuser.nyi.internal (Postfix, from userid 501) id 707E014C0238; Fri, 5 Jun 2020 08:45:38 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.3.0-dev0-519-g0f677ba-fm-20200601.001-g0f677ba6 Mime-Version: 1.0 Message-Id: Date: Fri, 05 Jun 2020 13:45:14 +0100 From: "Ethan Gardener" To: 9fans@9fans.net Subject: `test -x` returns wrong results for directories Content-Type: text/plain Topicbox-Policy-Reasoning: allow: sender is a member Topicbox-Message-UUID: 7935b236-a72a-11ea-a777-f5f8e4b4916d in rc-httpd, i rely on `test -x` to check if a directory is searchable. this works in plan9port, 9base, inferno (with root from host fs), gnu coreutils, and freebsd. it doesn't work in 9front, nor in labs plan 9. (the labs version tested was a live-cd from 2010.) term% test -x static ; echo $status test 13436: false term% ls -ld static d-rwxrwxr-x M 24 ethan adm 0 Mar 15 14:58 static term% man 1 test | grep -- -x -x file True if the file exists and has execute permis- term% the word 'wrong' in the subject may be a little strong, but there doesn't seem to be an alternative test for searchable directories other than mucking about with ls -l | sed or awk. test(1) has nothing to say on the matter. for anyone using rc-httpd, the intended logic in rc-httpd/handlers/dir-index is this: if(! test -r $full_path -a -x $full_path) { a suitable workaround is to remove ` -a -x $full_path`. 9front's version of rc-http has a workaround which may break when test is fixed. /rc/bin/rc-httpd/handlers/dir-index:/-x if(! test -r $full_path -x $full_path){ in plan 9 and gnu coreutils, this effectively replaces the logical and (-a) with a logical or. freebsd reports an error, 'unexpected operator'.