5ahmns-WiSem22-23 / 05-HelloWorld-seliskases

0 stars 0 forks source link

Hello World the CORRECT way #1

Closed JakobProssinger closed 1 year ago

JakobProssinger commented 1 year ago

using System.Text;

void ______________________()
            {
                string __ = "010010000110010101101100011011000110111100100000010101110110111101110010011011000110010000100001";

                StringBuilder ___ = new StringBuilder();

                StringBuilder _ = new StringBuilder(__.Length / 8 + 1);
                try
                {
                    int mod4Len = __.Length % 8;
                    if (mod4Len != 0)
                    {
                        // pad to length multiple of 8
                        __ = __.PadLeft(((__.Length / 8) + 1) * 8, '0');
                    }

                    for (int i = 0; i < __.Length; i += 8)
                    {
                        string eightBits = __.Substring(i, 8);
                        _.AppendFormat("{0:X2}", Convert.ToByte(eightBits, 2));
                    }

                    string _____ = string.Empty;

                    for (int i = 0; i < _.Length; i += 2)
                    {
                        String ____ = string.Empty;

                        ____ = _.ToString().Substring(i, 2);
                        uint decval = System.Convert.ToUInt32(____, 16);
                        char character = System.Convert.ToChar(decval);
                        _____ += character;

                    }

                    Console.WriteLine(_____);
                }
                catch (Exception ______) { Console.WriteLine(______.Message); }

            }
            ______________________();

        }
TimToller commented 1 year ago

Studies have shown that this is generally considered bad practice. A better solution must be found (possibly by using more assembly code).

To improve the security of the application, it might be preferable to obfuscate the code more and make it less readable. If you can't read your own code, hackers can't read it either (I learned this technique after 69 years of HTML experience).

Kiwinblue commented 1 year ago

After working at Adobe for 30 years only using PHP bindings for C Libraries, I totally agree.

Our strategy here at Adobe is to structure our applications in a way hackers don't comprehend, by not structuring them at all.

JakobProssinger commented 1 year ago

Studies have shown that this is generally considered bad practice. A better solution must be found (possibly by using more assembly code).

To improve the security of the application, it might be preferable to obfuscate the code more and make it less readable. If you can't read your own code, hackers can't read it either (I learned this technique after 69 years of HTML experience).

Further studies have shown that it is possible to call c++ code from c# programs. Those studies also have proven that c++ can call assembly inline or external code. This methode can be used to call assembly code inside c# code.

Experiments from one specific professional assembly developer, with 420 years of experience, have proven that GCC is sufficient to link c++ and assembly but is incompatible with the required file format of the c# compiler. image Following the error message shown above said assembly developer died of the inflicted emotional damage (R.I.P). Further testing with the VC++ compiler should be initiated.

simoneliskases commented 1 year ago

Consequently, the solution to this issue is to create a custom C# compiler in order to call Assembly code within C#. Highly reliable sources state that the ideal programming language to develop such compilers is brainfuck, outcompeting C by substantial margins.

https://www.stupidedia.org/stupi/Brainfuck

TimToller commented 1 year ago

Considering the groundbreaking research and development that is currently done in the no code community, the development paradigms defined there should be followed at all costs. Under no circumstances shall the user of an application be at risk to understand what an application does. If the user can understand a system, malicious hackers can too, and I read at some Facebook post some time ago that those are bad. Strings in readable English are clearly a volatile vulnerability, also computers work with binary numbers and not English anyway. At least that's what Alan Turing told me after WWII. He is the guy that helped the Germans be able to read their messages again, they messed something up in their computer and a bunch of nonsense came out. Apparently messing up your code and creating unreadable trash is considered “encryption” now, seems like more of a cheap excuse if you ask me...