• Hi guest! As you can see, the new Wizard Forums has been revived, and we are glad to have you visiting our site! However, it would be really helpful, both to you and us, if you registered on our website! Registering allows you to see all posts, and make posts yourself, which would be great if you could share your knowledge and opinions with us! You could also make posts to ask questions!

Unix script algorithm analysis

Joined
Sep 9, 2021
Messages
9,697
Reaction score
5,256
Awards
33
Has anyone ever done this, and if so what is the process? I know general algorithm analysis of code from high level languages. I have an algebra background with promise, but no math beyond that. However, I understand the geometric series as a for loop, however we are talking about the Unix operating system itself, which has kernel, memory, clock, and other activities running constantly, so if I were to do stack traces, that may help. I guess what I'm saying is that for every command, there is unknown code which makes algorithm analysis extremely difficult. This is my next concern of my scripts, what holes exist, configuration is most important, I know that as well.

This is in reference to my security monitor suite of scripts I wrote, which I would paste the code, but if I were to do so, that may be a security risk for us, so I could post pseudocode, although it would be covered here in reference to this post:
and
[Help] - Writing scripts to act as a security monitor (which I think I solved)
Post automatically merged:

In hindsight, I recalled The Unix Programmers Manual, by Kernhigan or Ritchie, as well as The C Programming Language and the Standard C Library, which contain code and data structures in unix programming using the C language.
With C, it is possible and much more preferable than tracing stack threads, system calls and the like.
So that may be the solution, trace the outer algorithm and make it as clean and logical as possible, then trace for each command the runtime values using algorithm analysis for each command, then combine them, come to the final runtime value.
 
Last edited:
Top