Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp4130766pxf; Mon, 29 Mar 2021 23:12:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyK3uXkwGY6M/Ya91Rln4oxD96hpA2mq4wRv6Ekirs1mz9nDrgacm3VmKryK6qvO8fOQL1c X-Received: by 2002:a17:907:10ce:: with SMTP id rv14mr32424161ejb.56.1617084755296; Mon, 29 Mar 2021 23:12:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617084755; cv=none; d=google.com; s=arc-20160816; b=ITiMhrq9HqLAk3wI3lDrwXoHdbJrwmxaPuwiJJWgEsyEI3UXGRdqMGwhNJVaETV6DW KPxZBQVrY57b9Rh8Cg7/6NWHAlC6b/HlsM2fhwRmnONj4FXZ7qInZXeCLq9ykmPlfD2Z vMksz3DKRKK1DTs8PSwr7tcTy2h3/RJTwODwPkRfTPBcFNceQOubEQO2Z17/2nTAa8G3 FivczxxBmzGpMXGjS46c0bxhqE09h/Tbglve2jtv3bTA+ci1PX4Ra0b9K0cAoNeCiA8i 8IZYJ/L9+pSF19OIghHdXdbvOOcG/9ZZ2X9A9NWipTBm1YSD0/Ls4E2Fe+8wuVBchQr4 peHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=lNbJX303TKj0bY08nTN0li+FCpaX3fkQH86qG6Fy4cY=; b=djDT3tlxzurJLmXsmhz9aTN5KObNV9Bkfik+y7E1Zex645jG/qAjePDk2ku4rRnmp9 6ZLV3a8jAHAvXeagIiQBFS1TFJAPGLuiVLtg5scSdKVFuKajgtzDYRpzIKJStdWX//6I 9xNoIIR1ndHzDwR8m8AjOkPNqiCtBsB67IBSMSnmPM7a3xsZ10b9psvZPXaPftWXZna9 4evs3BV5Xn88aquAoRyn+3uTGFfMX9mZki8TtgsvAHoxWo99nfNzSwQff7YGosoBRegu tMECxR3fTLfLHWbgLd+7CEBWt/DWE0Bf4JuLoygbaoY+2f/zluF8rqyjB7qIxTQGsk7E vJwA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=kCXfj4yo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w5si15317495ejk.167.2021.03.29.23.12.12; Mon, 29 Mar 2021 23:12:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=kCXfj4yo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230248AbhC3GJN (ORCPT + 99 others); Tue, 30 Mar 2021 02:09:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49856 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230224AbhC3GIs (ORCPT ); Tue, 30 Mar 2021 02:08:48 -0400 Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3B7D7C061762 for ; Mon, 29 Mar 2021 23:08:48 -0700 (PDT) Received: by mail-ej1-x62e.google.com with SMTP id a7so22996516ejs.3 for ; Mon, 29 Mar 2021 23:08:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=lNbJX303TKj0bY08nTN0li+FCpaX3fkQH86qG6Fy4cY=; b=kCXfj4yojsaTUg2WjkiwZOb0nApyobIksGmDw2gUIj7sgOR1YC8VqnkPJrDYTzanUM owmndn0GmxBRPp3RUghzkdOdAZa/hI1Rn7vMTc5Df3Rbm1g9bHS3/mXN0NoVhcPnie7z sKysoVqz4CUGvQr2mUyVj041BzGXb5cQrV2gc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=lNbJX303TKj0bY08nTN0li+FCpaX3fkQH86qG6Fy4cY=; b=QRPfreFWnPSGL49WiSS+ojbVL2LEMzCihiWkWZFv3QsEJmxdiydFb85ASTIjwmG9wX 69tcYxYOBiCA36PGBlL2tgclQUBBq1LHKhAuo9UDA8UqITxpAyx+quAN+kl2hdw2dTrc c/P3Az+t7wlZQz3EXuWPakg8s9Vci4t6lCmI/+xlvlafWhlJniiiIKGOyvY7/5wxQYNg A0vK1XsTA/z8pdQ5QBYDgg0pBCDNxJ2COmQatLRW8CwQgKWLI9+ij9GOOyafFajtfZ2n CAeMH3HE8BFhCAHYXOojgFxRzocxzxF9DcQxvm365yRFBn0EQQXkrRQ82uh6VVpeI+t8 i2sQ== X-Gm-Message-State: AOAM531Y5kl+L6FF1w7+S3HbLu6t1RsmmAbnyUO5Fzt8bNqxXnDcuck1 wLHInP5woCGn1RpaBKm87SWA048xTqX7qQ== X-Received: by 2002:a17:906:4407:: with SMTP id x7mr31570991ejo.546.1617084526916; Mon, 29 Mar 2021 23:08:46 -0700 (PDT) Received: from alco.lan ([80.71.134.83]) by smtp.gmail.com with ESMTPSA id d1sm9449679eje.26.2021.03.29.23.08.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Mar 2021 23:08:46 -0700 (PDT) From: Ricardo Ribalda To: linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org, trivial@kernel.org Cc: Ricardo Ribalda Subject: [PATCH] IMA: Fix error in comment Date: Tue, 30 Mar 2021 08:08:45 +0200 Message-Id: <20210330060845.18422-1-ribalda@chromium.org> X-Mailer: git-send-email 2.31.0.291.g576ba9dcdaf-goog MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ima_file_mprotect does not return EACCES but EPERM. Signed-off-by: Ricardo Ribalda --- security/integrity/ima/ima_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/security/integrity/ima/ima_main.c b/security/integrity/ima/ima_main.c index 9ef748ea829f..716ea29cf897 100644 --- a/security/integrity/ima/ima_main.c +++ b/security/integrity/ima/ima_main.c @@ -409,7 +409,7 @@ int ima_file_mmap(struct file *file, unsigned long prot) * this point. Eliminate this integrity gap by denying the mprotect * PROT_EXECUTE change, if an mmap appraise policy rule exists. * - * On mprotect change success, return 0. On failure, return -EACESS. + * On mprotect change success, return 0. On failure, return -EPERM. */ int ima_file_mprotect(struct vm_area_struct *vma, unsigned long prot) { -- 2.31.0.291.g576ba9dcdaf-goog