[core] bMAC test program for Arduino Nano

Pascal Urien <pascal.urien@gmail.com> Mon, 30 December 2019 19:46 UTC

Return-Path: <pascal.urien@gmail.com>
X-Original-To: core@ietfa.amsl.com
Delivered-To: core@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id DC005120B53 for <core@ietfa.amsl.com>; Mon, 30 Dec 2019 11:46:50 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.998
X-Spam-Level:
X-Spam-Status: No, score=-1.998 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id RIiS5NqZ55Hj for <core@ietfa.amsl.com>; Mon, 30 Dec 2019 11:46:49 -0800 (PST)
Received: from mail-vs1-xe36.google.com (mail-vs1-xe36.google.com [IPv6:2607:f8b0:4864:20::e36]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 1611C120020 for <core@ietf.org>; Mon, 30 Dec 2019 11:46:49 -0800 (PST)
Received: by mail-vs1-xe36.google.com with SMTP id b79so21530171vsd.9 for <core@ietf.org>; Mon, 30 Dec 2019 11:46:49 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=UZ/lwTK4pLq/2tjw19kOxuMxkElR3oYgPcmSmYLv4BI=; b=aOLwTnpGzHJyRSXCP2hMoiwR9Sc8y/j7PE7A1iEdbH68wTFNHc9HzhHNY4PH6a0AnF oIYmLhr7L8yIP9O4NmhUYawP4AGShi+SpnUcBtMmxk1GgdbtPzPCgm9ctCYtSAsNKk4s K+ThGFMzwTe79V1Vqhd+E7xnha3SmuKBhQ7SaxBpX/NeYoIUdZbQv/gftW7fXwSFQwpt 0GvwVnFyIri5yuJ9Z9AzQG+XL3Xu/FEdNeZlX18GjPwmVLBmLPup3Tg4EIXCoevMHIDs jJx9eaKgjbV+cq9AaRMBrzHjdhu9pbNUPQfKkk14BVbEQKwWpPN5Z8e3hUKaYGR9fgLc 8x9w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=UZ/lwTK4pLq/2tjw19kOxuMxkElR3oYgPcmSmYLv4BI=; b=GLTANSB7ZZas4UjeYAOou1BtnoTdB/Z2VxFLnXEq/UF23RPLrKUE00DwCNXJWza73Z k1IFn1uYBvOz/Z6bSho2SCrxr9xST0GywmOrIlwn9hkUCYU3SsK6jirvViM7MpYp/DoU OaQjscDb/GeUJSK1gC0xZ3cjyIAsEKW/SMOpjuDy9aff6Eu+QjRPhtjQTVjWc16uBL9E +4wkf5xdnziTxqMVdnwZsiNwm8B+ITk2J89f3xlSxZd93aYTk94wDSZdGSt6t7R2Y9I/ L35+C807eBblm1GRXC5ex1b+XiplJSKasJ/Lw8ZJ0NJM2XChcc9OzEqARlzP34VAC367 vvNw==
X-Gm-Message-State: APjAAAVoGF3g2S7BaRnnYqknGPlHND1BNpC1jsPjPb0T5mbMB8f45qDk IefUg8LlpnifPK9YUTCZ/fNH6b9kB2d4hLCHNrRVBTK7
X-Google-Smtp-Source: APXvYqzW4McvEhd2TfeNk4Scorfc9+mue9Pj74+Ibxpdv5+NUNUOXRI3/4GQ3ev1ubR+G1GQIpzQK0Nm3l9uWsk/AVY=
X-Received: by 2002:a05:6102:402:: with SMTP id d2mr32837836vsq.146.1577735207790; Mon, 30 Dec 2019 11:46:47 -0800 (PST)
MIME-Version: 1.0
From: Pascal Urien <pascal.urien@gmail.com>
Date: Mon, 30 Dec 2019 20:46:35 +0100
Message-ID: <CAEQGKXSai8Oc5O2GVyY7TqKaW6Dgr9++ORYPJ+bw5Rm9RPsJFg@mail.gmail.com>
To: core <core@ietf.org>
Content-Type: multipart/alternative; boundary="0000000000009c2c2f059af11a55"
Archived-At: <https://mailarchive.ietf.org/arch/msg/core/BpDzO12LBtASWl_rlHg1z1xOkig>
Subject: [core] bMAC test program for Arduino Nano
X-BeenThere: core@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Constrained RESTful Environments \(CoRE\) Working Group list" <core.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/core>, <mailto:core-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/core/>
List-Post: <mailto:core@ietf.org>
List-Help: <mailto:core-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/core>, <mailto:core-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 30 Dec 2019 19:46:51 -0000

The bijective MAC Time Stamped (bMAC_TS algorithm see
https://tools.ietf.org/html/draft-urien-core-bmac-05) aims at detecting
malicious (corrupted) software in constrained environments.

It works with two pillars, memory space is finite and computing time is
stable.

Memory space is hashed according to a pseudo random order. The computing
time is measured in order to defeat code decompression algorithms.

I have written a test software for arduino nano (33KB space memory for
FLASH + SRAM+EEPROM)

Computing time is about 27s (# 1m/byte), roughly speaking the computing
time follows a normal distribution, the entropy is about 10bits (3 standard
deviation)

The code is here: https://github.com/purien/bMAC

Comments welcome ..

Pascal