Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp1735035ybn; Thu, 26 Sep 2019 01:09:25 -0700 (PDT) X-Google-Smtp-Source: APXvYqxNwiUt78Oy6P8bbk9brJPzQL/t2dXPqWNSJY20XwbShjUdL4wNZVYWp0eE4h7mYhFCBuGd X-Received: by 2002:a17:906:82c1:: with SMTP id a1mr1949581ejy.187.1569485365310; Thu, 26 Sep 2019 01:09:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569485365; cv=none; d=google.com; s=arc-20160816; b=jPGoz72d4U9mj/y271zAegbN8p0GFzW9jEdGrGjMrz5whiKUPzEMT59eAv3Pbzjm4M tw4kaKxJD+y1r4MUDqLFYTPOMWHzZ/gf79CAmnly4+sOn/8j3Ndm/qvoDQX4VSGDutZr 1EgiZbA+fCOGdftcnBHfhd7jzuvrd+cj1KqkvcOciU+B3Hu3wCAsCMicamV/4AfB1Csp PvN5sJoFCkRLDv+TMTSCOn145Rjyu/Ety3baxCOMUiYLRw/qYE/3HxT0dKb6ryqxnBuF GxiL6gjBJg/GfHEjP3aqkFpHAFiRGFafxgcNmn1AgGxIFmadAxEuAghWdnqVuFZNPww6 5WLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:organization:message-id:date:subject:cc:to :from; bh=e+r7Zb4BqECop1JhANT+4h6DaMrv2hkFc+Ekym6Dfy8=; b=mazCNFzEURu4StogkURqPCcf/2J8cveSB8ENttrGgC8R8q+kFY4cxZ66pDhQnxz6Bd S49XzlyXeLvJJJXzAlyPTZ8FKz+G5OZzBNj4eKoKDTgYkMwcDCpCFjWECqosnejoMFAG SEknV0WGANRy0qSlNjSIQJ9F+R6g9nldGNX7IcV/zT+n7oi10ROB0AEIxjcpjbWaUgBL +MpbyYqVVE+1qWiI6MavCdXkRroWVbJvjm4u6UGStyhMldPjPlSaaOfhMn5yjWb1DZqE RL5eLY9QtJg9XOzKvd8pHYjR8HbzEPmw5f0PjyOI12IlAtsch7RHt47Xwng3sAbZi4/+ iMyw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e23si814127edq.344.2019.09.26.01.09.01; Thu, 26 Sep 2019 01:09:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2441116AbfIXNT2 (ORCPT + 99 others); Tue, 24 Sep 2019 09:19:28 -0400 Received: from mx1.redhat.com ([209.132.183.28]:48864 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729908AbfIXNT2 (ORCPT ); Tue, 24 Sep 2019 09:19:28 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 13EB23B708; Tue, 24 Sep 2019 13:19:28 +0000 (UTC) Received: from x2.localnet (ovpn-117-6.phx2.redhat.com [10.3.117.6]) by smtp.corp.redhat.com (Postfix) with ESMTP id AB04D1001B30; Tue, 24 Sep 2019 13:19:23 +0000 (UTC) From: Steve Grubb To: linux-audit@redhat.com Cc: Paul Moore , Dave Jones , Linux Kernel Subject: Re: ntp audit spew. Date: Tue, 24 Sep 2019 09:19:23 -0400 Message-ID: <2130348.JY4ctgmguH@x2> Organization: Red Hat In-Reply-To: References: <20190923155041.GA14807@codemonkey.org.uk> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Tue, 24 Sep 2019 13:19:28 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Monday, September 23, 2019 12:14:14 PM EDT Paul Moore wrote: > On Mon, Sep 23, 2019 at 11:50 AM Dave Jones wrote: > > I have some hosts that are constantly spewing audit messages like so: > > > > [46897.591182] audit: type=1333 audit(1569250288.663:220): op=offset > > old=2543677901372 new=2980866217213 [46897.591184] audit: type=1333 > > audit(1569250288.663:221): op=freq old=-2443166611284 new=-2436281764244 > > [48850.604005] audit: type=1333 audit(1569252241.675:222): op=offset > > old=1850302393317 new=3190241577926 [48850.604008] audit: type=1333 > > audit(1569252241.675:223): op=freq old=-2436281764244 new=-2413071187316 > > [49926.567270] audit: type=1333 audit(1569253317.638:224): op=offset > > old=2453141035832 new=2372389610455 [49926.567273] audit: type=1333 > > audit(1569253317.638:225): op=freq old=-2413071187316 new=-2403561671476 > > > > This gets emitted every time ntp makes an adjustment, which is apparently > > very frequent on some hosts. > > > > > > Audit isn't even enabled on these machines. > > > > # auditctl -l > > No rules > > [NOTE: added linux-audit to the CC line] > > There is an audit mailing list, please CC it when you have audit > concerns/questions/etc. > > What happens when you run 'auditctl -a never,task'? Actually, "-e 0" should turn it off. There is a general problem where systemd turns on auditing just because it can. The above rule just makes audit processes inauditable, but does not affect the kernel originating events. -Steve > That *should* > silence those messages as the audit_ntp_log() function has the > requisite audit_dummy_context() check. FWIW, this is the distro > default for many (most? all?) distros; for example, check > /etc/audit/audit.rules on a stock Fedora system. A more selective > configuration could simply exclude the TIME_ADJNTPVAL record (type > 1333) from the records that the kernel emits. > > We could also add a audit_enabled check at the top of > audit_ntp_log()/__audit_ntp_log(), but I imagine some of that depends > on the various security requirements (they can be bizzare and I can't > say I'm up to date on all those - Steve Grubb should be able to > comment on that).