From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: border1.nntp.dca1.giganews.com!nntp.giganews.com!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!feeder.erje.net!eu.feeder.erje.net!news.swapon.de!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Natasha Kerensikova Newsgroups: comp.lang.ada Subject: Should Ada runtime provide special primitives for cryptography? Date: Wed, 1 Oct 2014 08:42:17 +0000 (UTC) Organization: A noiseless patient Spider Message-ID: Injection-Date: Wed, 1 Oct 2014 08:42:17 +0000 (UTC) Injection-Info: mx05.eternal-september.org; posting-host="76a49b86bc3e16725b7cfca3d85cb4c8"; logging-data="27052"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/IpH6Xq56r/R9CPrzTnk3T" User-Agent: slrn/1.0.1 (FreeBSD) Cancel-Lock: sha1:MIo9rcP8gm+JjiWtLh18qSpbn4A= Xref: number.nntp.giganews.com comp.lang.ada:189267 Date: 2014-10-01T08:42:17+00:00 List-Id: Hello, I recently thought that Ada general strictness and integration with proof systems would make it a good language for cryptographic primitives. However, when actually implementing cryptographic stuff, cleverness from compiler and optimizer are often enemies. For example, overwriting a buffer with zeroes might be optimized out when the buffer is not accessed again. I believe it would not be difficult for a compiler vendor to provide, as part of the runtime, a zeroing procedure guaranteed to not be optimized away, a (generic) array comparison guaranteed to execute in a constant number of operations and/or branches, etc. And such subprograms would be difficult to write externally, and the guarantees difficult to make without tight compiler integration. Would it be useful to propose an AI for the addition of such subprograms to Ada standard library? Natasha