From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from cross.elm.relay.mailchannels.net (cross.elm.relay.mailchannels.net [23.83.212.46]) by sourceware.org (Postfix) with ESMTPS id B60BD3858C83 for ; Fri, 21 Apr 2023 11:59:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B60BD3858C83 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=gotplt.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gotplt.org X-Sender-Id: dreamhost|x-authsender|siddhesh@gotplt.org Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 4743C5014AB; Fri, 21 Apr 2023 11:59:33 +0000 (UTC) Received: from pdx1-sub0-mail-a305.dreamhost.com (unknown [127.0.0.6]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id CF4775012BC; Fri, 21 Apr 2023 11:59:32 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1682078372; a=rsa-sha256; cv=none; b=ZE/Dwdqam9ZMZEeCMpY0eF3QTlf3KFWetnIEBU5E9Ks+xppwbJ1rR8cx+W3E5yK1/XBzYk 0mpHAu0kHM3nOFO9b2xKaeJnusF5Bv2/AtIyyAM8MyRcSfmGuAqHnEcvGDYVL0i1/hIPt8 R3cuXEyBxYSQUX1svXluew2e/fXFgULeE/qeAJY22n6w7PG5oZWDF0OuR3oDIgMlL96QRI BSPi7iz6n5FOsimDVchgtvofZzb0INvWPMRc0UORodSqdRyTrg98djO5G4UN3164/g3nlj vOzsGf0bgPPTzAMhDW2GIMqvAm2biySwS2ZFxDLS+5ft9GO18a2OyiX58JMQRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1682078372; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=/bkpkzFmm7UAcx0HqmUkGhHsXUndfXk1GOB2uX0J8PU=; b=3y8iHLPNQMbnTW7D0Sfr7/eda+hiFlxaAfFZ66wX8L9VBIwzSJoSF45y3pkRxdSG0pp1WH 2Zc/EfsXJGYluyh7YPIYPl7wqmFM2JF99t4sk2ljfq2eoKguoYsQya2c0qj/pcwUlSsYB/ o01+WrYB0apYirNZf3K9RjCtaTTjmfoEIuSh2NtmIrAP+ZdoAiQrSJfjYBGBFl6Cf7BlOb looBtUs65h1Ws8EDpHE/jrVEnxz9nnK7uGaNZty12FKEUmVHGXI6x98TWfpqFpJAc6+TI4 nom+UaSKhwVehbrnP/O+fleFaNPUUZgoKwXnmSjUHWJKi44zBdf63JlZfnPK5g== ARC-Authentication-Results: i=1; rspamd-548d6c8f77-d75cf; auth=pass smtp.auth=dreamhost smtp.mailfrom=siddhesh@gotplt.org X-Sender-Id: dreamhost|x-authsender|siddhesh@gotplt.org X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|siddhesh@gotplt.org X-MailChannels-Auth-Id: dreamhost X-Soft-Wipe: 78eaf2e924578aaa_1682078373086_893808738 X-MC-Loop-Signature: 1682078373086:2572724880 X-MC-Ingress-Time: 1682078373085 Received: from pdx1-sub0-mail-a305.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.125.42.141 (trex/6.7.2); Fri, 21 Apr 2023 11:59:33 +0000 Received: from [192.168.0.182] (bras-vprn-toroon4834w-lp130-09-174-91-45-80.dsl.bell.ca [174.91.45.80]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: siddhesh@gotplt.org) by pdx1-sub0-mail-a305.dreamhost.com (Postfix) with ESMTPSA id 4Q2tP02c1BzRn; Fri, 21 Apr 2023 04:59:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gotplt.org; s=dreamhost; t=1682078372; bh=/bkpkzFmm7UAcx0HqmUkGhHsXUndfXk1GOB2uX0J8PU=; h=Date:Subject:To:Cc:From:Content-Type:Content-Transfer-Encoding; b=mrxYBlvZWvNI+yojRpNnbXQKWyy2WkSQHHLbPOGk53sB7PUz3AJrWnwWs1asI0/zn LcPCpqUn/rjsolNzvTp7RMvUMHxcaTaSepqVRcBb3FdSm8b0Vl3Wurf3tC0SOfK1Ot khcf17i8ctm0mNBgV7rlkB4mSqoLpmN17/kJCkJCLAmWOwyZMrhk0Js0PjO60e4saF 9CD2OxAsyeb/CLJXjT/8GgFQo5qHzIb2iR1PiMH2VvBDO/3WKs0SVW/fmM5chrIS7C Z09/Yq4GrIhxL0b1Gxd07cTizEyCSlRFqCMt9H+Lfa8RS44kkMAZFs7HE1dqdQxVry +xzeDvzZBQYWw== Message-ID: <5b491049-809f-57b0-711f-0d9974043c05@gotplt.org> Date: Fri, 21 Apr 2023 07:59:30 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 Subject: Re: regexec(3): REG_STARTEND is not documented Content-Language: en-US To: Alejandro Colomar , GNU C Library Cc: =?UTF-8?B?0L3QsNCx?= References: <0de87674-1b35-8dc8-7d2b-8dacd6b015ff@gmail.com> From: Siddhesh Poyarekar In-Reply-To: <0de87674-1b35-8dc8-7d2b-8dacd6b015ff@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3032.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2023-04-20 20:45, Alejandro Colomar wrote: > It seems the glibc manual doesn't cover REG_STARTEND. We're having > some discussion about it, while we're improving the manual page, and > we have some slight disagreement about what are the constraints for > nmatch and pmatch when REG_STARTEND is specified. > > Since this is a BSD extension, not in POSIX, we can't refer to the > standard. And since glibc doesn't document it, I can't know for > sure your intention. The implementation predates my involvement by nearly a decade, so I can only guess based on the implementation. However, in general if it's a BSD extension, we tend to comply with the wording in the BSD manual, so based on that, what наб said seems right to me. In the absence of manual text, I'd defer to the BSD manual too. > I'm not sure how much we should rely on implementation details, and > if those will hold forever, or _FORTIFY_SOURCE and the like are > allowed to constrain some current details. Typically we add such non-standard constraints when the default usage is known to be insecure (e.g. writable format strings with %n in them), which doesn't seem to be the case here. Thanks, Sid