From patchwork Mon Dec 16 16:00:01 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Armin Kuster X-Patchwork-Id: 181744 Delivered-To: patch@linaro.org Received: by 2002:ac9:44c4:0:0:0:0:0 with SMTP id t4csp4481947och; Mon, 16 Dec 2019 08:02:13 -0800 (PST) X-Google-Smtp-Source: APXvYqyHMgVPPMVDruFZOGQoa8jSRssP41vvKn2hLcWCrRPDzYbd796+wo2W1Q9HID409VVhFsQv X-Received: by 2002:aa7:9567:: with SMTP id x7mr16705383pfq.133.1576512133193; Mon, 16 Dec 2019 08:02:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576512133; cv=none; d=google.com; s=arc-20160816; b=ZsnRvSKMTcLyCz5EM3Phlkol5sDlx+xyxRZFtfqBfqigtALdoW9p9mfgKsKEAGajdM elEOzllIzffYrqPdhRvSbiSDbg7xg2LgtkOWGb4ICeCeCSRCtOojSCaosswqem4QoaLr QGalThRF/szlwQctqibpWJ3/iO/mF3Xo3QqqdHGnFG0nS+oBiFCZN2nsRU5youOEWNtf DoDB2zLcTKts9h+kEe1QpooMmxU0RuG2nUyuHOni3Ehxbhu/jVg7VQ66F2O89unwH3sb XLGGn24H3Rvk9bR8eJrno6XCzh1eIYy8pGh2hfbDeSc1rLX7sUqwqPsEW6jQT66CnbhX IHHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=zNdg1LtpwJO6MAOm3mXn9wOLbKRuzLKhcACd7suBqCU=; b=VVSmJh6cdjXCXMeWacvqKABk87SAYSy5UhO9gRUv5EjPSPMLGs11E2CnwJX9QlMe9Q aEdKvFfA3FW5jhMaOJID2wrW+liUi4eKfo+GJk9OuAmq8ABQbx1lGY0YFwsRmQFqTLDB Fy0IrrGURFtpE+YO+MEeiZA5LlWLrTUZ1g0sZdVdJgZ+unjnr7YxdbQ3of9Frn6Mjnop eyqnPBd3/boWnPt/x2AACSsnRfnB9+X0cV4djYaYISlKU/FU+4594M4FB14tFVwCelMI Mi16/DOVwQvLd0zx1U3aQem+syTGZl36EDoD9XX3+OjVb2TxMcCyja8/w0/RArJ8eRUg 6srQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=DqBx+MAZ; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id a18si8768202pgi.97.2019.12.16.08.02.12; Mon, 16 Dec 2019 08:02:13 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=DqBx+MAZ; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from ec2-34-214-78-129.us-west-2.compute.amazonaws.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 63ED17FE0E; Mon, 16 Dec 2019 16:00:46 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-pj1-f53.google.com (mail-pj1-f53.google.com [209.85.216.53]) by mail.openembedded.org (Postfix) with ESMTP id E84407FDA4 for ; Mon, 16 Dec 2019 16:00:21 +0000 (UTC) Received: by mail-pj1-f53.google.com with SMTP id ca19so3164168pjb.8 for ; Mon, 16 Dec 2019 08:00:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references; bh=905yWqdeIGCayTdsC6Nq6OoyUJiefrqmQru1RYtH1Mc=; b=DqBx+MAZzrtEIIg+h1qkYg6Zj/ra2jT/QGrU1yUiViXHXBl/IKSu3D0IhLbE5Gomiy DSKtzHHQ8VVcuIqO5PHu2SPdpBZjJNmI/sPavJE3m44N9V8FOtpCskr1iJSh7G2DrV4U cAb6xW3F6Fcu/fb5UCNPNmyWB6vyxR4QUjN3NAGZTXh/8DOXrVHhOxGFzDX/iJJsNdB+ 9B9Tk+6pcoBIldBUjx7cIBq/VbeVXosRGe8P2oAd9qLuy5HL+XwSEJnuagnELW+oQABx YzX1E2gv2Ef5MpzJtPqomC9oVDxOVMyIIi9m6k4DMP2uy8eNgB131zomjN5w1DLrQm2U CH1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=905yWqdeIGCayTdsC6Nq6OoyUJiefrqmQru1RYtH1Mc=; b=qoUD0B3i/FCbgqPJGpCTwpJh86s3AoPgYrUaOGgNAWVslCOjLeTXvJMAUYSyJJEfjs ZSk4ncJ1cCmMVO6mFsfOQsQgKGySoKVfm+WmwoXRi/HJXbmlIQj3d4X9OB7TJRv1S2fh pNbG+r/KZerMYl2LpArYcD69WlQbIUVnLmjn8MMPe55sZD8be8EDHUxeefF9E64x5SBB flvw+SjEsAumkiO2QFZj3VYUfaHfWeqH8ovHEPYo8ypXytWXY4ylNJBUKGcCH6BEbmwM /eQzJlZYC8V63r6JxSdrpHgvbiVrEpcI81Bz4alTQ+ATRKpRQ/Xkvhm9+Z6qcVBmBAYL S2Ng== X-Gm-Message-State: APjAAAWubtqp7gZDzfQHLSbUYl/KScr/7t/EVfLEpRthO4v+9KKIIhGT huvByVskhEmgDOXd5ETZ/8Nl7UU532c= X-Received: by 2002:a17:902:ff10:: with SMTP id f16mr16806117plj.312.1576512022884; Mon, 16 Dec 2019 08:00:22 -0800 (PST) Received: from akuster-ThinkPad-T460s.mvista.com ([2601:202:4180:a5c0:e5c5:31c9:a010:f145]) by smtp.gmail.com with ESMTPSA id g6sm19568697pjl.25.2019.12.16.08.00.22 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 16 Dec 2019 08:00:22 -0800 (PST) From: Armin Kuster To: openembedded-core@lists.openembedded.org Date: Mon, 16 Dec 2019 08:00:01 -0800 Message-Id: <29cc2b5cd4bcce1c9e93395a1640014877486d7a.1576511913.git.akuster808@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: References: Subject: [OE-core] [thud 11/18] cve-update-db-native: don't hardcode the database name X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org From: Ross Burton Don't hardcode the database filename, there's a variable for this in cve-check.bbclass. (From OE-Core rev: 0d188a9dc4ae64c64cd661e9d9c3841e86f226ab) Signed-off-by: Ross Burton Signed-off-by: Richard Purdie Signed-off-by: Armin Kuster --- meta/recipes-core/meta/cve-update-db-native.bb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.7.4 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-core/meta/cve-update-db-native.bb b/meta/recipes-core/meta/cve-update-db-native.bb index 19875a4..c15534d 100644 --- a/meta/recipes-core/meta/cve-update-db-native.bb +++ b/meta/recipes-core/meta/cve-update-db-native.bb @@ -28,8 +28,8 @@ python do_populate_cve_db() { BASE_URL = "https://nvd.nist.gov/feeds/json/cve/1.0/nvdcve-1.0-" YEAR_START = 2002 - db_dir = os.path.join(d.getVar("DL_DIR"), 'CVE_CHECK') - db_file = os.path.join(db_dir, 'nvdcve_1.0.db') + db_file = d.getVar("CVE_CHECK_DB_FILE") + db_dir = os.path.dirname(db_file) json_tmpfile = os.path.join(db_dir, 'nvd.json.gz') # Don't refresh the database more than once an hour