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: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: Test for constant (or "in parameter" in procedure) Date: Thu, 9 Feb 2017 18:17:13 +0100 Organization: Aioe.org NNTP Server Message-ID: References: <8aaa2cef-9ca2-4536-bdf2-1567947b9ab8@googlegroups.com> <24a8808f-dd9e-4fcf-bbe5-226f56a41eb9@googlegroups.com> NNTP-Posting-Host: BYuA7L7MRjuLLjcoGHOBxw.user.gioia.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 X-Notice: Filtered by postfilter v. 0.8.2 Xref: news.eternal-september.org comp.lang.ada:33292 Date: 2017-02-09T18:17:13+01:00 List-Id: On 2017-02-09 17:59, reinkor wrote: > On Thursday, February 9, 2017 at 5:51:46 PM UTC+1, G.B. wrote: >> On 09.02.17 13:46, reinkor wrote: >>> OK, I here try to communicate my intention via this simple example: >>> >>> i : Constant Integer := 5; -- all OK so far (but someone could >>> change this to a variable) >>> >> >> You could try making it more difficult for programmers >> you seemingly need to fight in source text by >> >> - by making i a function; hide its body, >> - make your code depend on compile time static constants. >> >> I'd suggest that it is time, technically, for your boss >> or for yourself to call for discipline, or ask you lawyer >> about what your contracts require you to guarantee if >> someone changes i to be some kind of constness backdoor. > > Maybe SPARK has an answer. Rather the OS. Set the ads file read-only. Calculate its signature (of military-grade length). Store the signature on an encrypted flash drive protected by biometric scanner. Verify the signature each 5 seconds to detect malicious source code modifications by intruders... -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de