comp.lang.ada
 help / color / mirror / Atom feed
From: Austin Obyrne <austin.obyrne@hotmail.com>
Subject: Re: Will Ada-95 Programs Written in MS Windows Run in MacOS and Linux Without Some Tweaking.
Date: Wed, 11 Dec 2013 02:35:00 -0800 (PST)
Date: 2013-12-11T02:35:00-08:00	[thread overview]
Message-ID: <87776124-a842-4b29-a094-e78a54cb7d49@googlegroups.com> (raw)
In-Reply-To: <l8829j$cs6$1@loke.gir.dk>

On Tuesday, December 10, 2013 9:49:36 PM UTC, Randy Brukardt wrote: > "Austin Obyrne" <austin.obyrne@hotmail.com> wrote in message news:2b6dc37f-4aa6-4c18-be59-8c09f6f37f01@googlegroups.com... On Tuesday, December 10, 2013 6:37:28 AM UTC, Randy Brukardt wrote: ... >Please consider this procedure in the program that gave trouble, > >This is the defacto stripped down procedure > >EXIT when EOF; > EXIT when EOL; > > FOR I IN 1 .. 3 LOOP > Ada.Integer_Text_IO.Get(File => InData, Item => W(I)); > --Ada.Integer_Text_IO.Put(Item => W(I), Width => 8); > END LOOP; > >LOOP; >LOOP; I presume that there is a New_Line in there somewhere so that the line endings aren't lost completely. But this isn't going to work, as Get for a character is defined as follows: "After skipping any line terminators and any page terminators, reads the next character from the specified input file and returns the value of this character in the out parameter Item." So if you have any line endings in between the 1st and 2nd characters (or between the 2nd and 3rd characters), you'll end up ignoring them. I doubt that's what you want. (Ada abstracts the line, page, and file terminators so you don't have to worry about how they're represented. The problem being that you *can't* see how they're represented if you are using Text_IO.) Using Text_IO without losing line endings and the like is tricky. I generally don't bother, just reading a line at a time with Get_Line and then process whatever I get. (And I just ignore page terminators, which are rarely used anyway.) But if I was writing this sort of code, I wouldn't worry about line endings at all, and simply encrypt the file as binary data, using Stream_IO to read it in and out. Randy.

 Hi Randy, I am not in that league of theoretical Ada that I can debate with any of you guys. For your info there are lots of New_Lines in the sample I submitted but I think there are other instances where there may be only one. My Ada programs have NEVER failed in thousands of runs - in fact they have never failed for any language syntax reason in about 10 years!. I am taking on board what you say is a definition of GET for pondering later. Can I tell you where I am coming from, Forget about programming my ciphers in the Ada language or any language. The cryptographic strength of the cipher depends on the veracity of the mathematical proof of the cipher algorithm alone. That in my case is written in stone. Demonstrating the cipher in Ada is the language I happen to greatly favour because of the workmanlike transparency of this langauge but the fact of my using gnat 311.p is merely a token and other updated gnat evrsions will always need to tested like right now 2013 version of MAC. Fundamentally, the crypto strength is both insured and assured beforehand regardless of how it runs in programs and if it fails for programmimg language reasons that is something that can be fixed and it is not as serious as being broken by cryptanalysis. 


I am of the belief there are always going to be problems to be expected when changing platforms like this. Up to now the programs to hand are very, very solid and even surprise me at the things they seem to shake off like encrypting source code so accurately where the smallest lack of fidelity could cause it to not run later on the decrypted sourcecode. I think that in the future each implementation on whatever platform is going to need tweaking initially but once that is done the natural stability of Ada will take over thereafter and when the cipher is wrtten it is there for all time. 

*It is hugely important for me to establish the fact that the cryptographic strength of my ciphers is ring-fenced independently of any langauge and may even be done in longhand fashion of push came to shove.

The class of these ciphers is demonstrably the ultimate clas of "Theoretically Unbreakable" and must not be undermined ever by whatever language is used - that is merely a conveyance - achieving cryptographic of perfect secercy is so difficult it is almost like a Greek Classic.

adacrypt.

  parent reply	other threads:[~2013-12-11 10:35 UTC|newest]

Thread overview: 57+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-07 12:24 Will Ada-95 Programs Written in MS Windows Run in MacOS and Linux Without Some Tweaking Austin Obyrne
2013-12-07 13:16 ` Simon Wright
2013-12-07 14:01   ` Austin Obyrne
2013-12-07 17:18     ` Simon Wright
2013-12-07 18:26       ` Austin Obyrne
2013-12-08 17:17         ` Simon Wright
2013-12-08 18:17           ` Jeffrey Carter
2013-12-08 20:00             ` Simon Wright
2013-12-08 21:20               ` Jeffrey Carter
2013-12-08 18:44           ` Austin Obyrne
2013-12-08 20:10             ` Simon Wright
2013-12-08 20:31               ` Austin Obyrne
2013-12-08 22:39               ` Austin Obyrne
2013-12-16 11:46                 ` Simon Wright
2013-12-16 19:00                   ` Austin Obyrne
2013-12-16 21:19                     ` Simon Wright
2013-12-16 21:40                       ` Austin Obyrne
2013-12-18  4:44                       ` Austin Obyrne
2013-12-18  8:35                         ` Simon Wright
2013-12-18  9:54                           ` Austin Obyrne
2013-12-18  4:57                       ` Austin Obyrne
2013-12-18  8:55                         ` Simon Wright
2013-12-18  5:38                       ` Austin Obyrne
2013-12-18  9:02                         ` Simon Wright
2013-12-18 13:02                           ` Austin Obyrne
2013-12-16 19:24                   ` Austin Obyrne
2013-12-17  9:06                   ` Austin Obyrne
2013-12-08 20:01           ` Simon Wright
2013-12-10  6:37           ` Randy Brukardt
2013-12-10 10:14             ` Austin Obyrne
2013-12-10 11:39             ` Austin Obyrne
2013-12-10 21:49               ` Randy Brukardt
2013-12-10 23:08                 ` Binary versus text and compiler versions, was: " Simon Clubley
2013-12-11  8:35                   ` Dmitry A. Kazakov
2013-12-11 12:50                     ` Simon Clubley
2013-12-11 13:29                       ` Dmitry A. Kazakov
2013-12-11 14:20                         ` Simon Wright
2013-12-11 18:25                           ` Simon Clubley
2013-12-11 14:53                     ` G.B.
2013-12-11 15:14                       ` Eryndlia Mavourneen
2013-12-11 16:07                         ` Austin Obyrne
2013-12-11 16:26                           ` Eryndlia Mavourneen
2013-12-11 17:37                             ` Austin Obyrne
2013-12-11 17:54                               ` Eryndlia Mavourneen
2013-12-12  1:55                                 ` Austin Obyrne
2013-12-11 16:54                         ` G.B.
2013-12-11 11:37                   ` Austin Obyrne
2013-12-12 19:23                     ` erlo
2013-12-11 10:35                 ` Austin Obyrne [this message]
2013-12-11  0:34             ` Simon Wright
2013-12-11  1:01               ` Jeffrey Carter
2013-12-11  8:38                 ` Simon Wright
2013-12-11 17:07                   ` Simon Wright
2013-12-11  8:49               ` Simon Wright
2013-12-07 22:49       ` Austin Obyrne
2013-12-07 14:08   ` Austin Obyrne
2013-12-08 20:06 ` Stephen Leake
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox