Jump to content
Sign in to follow this  

Using the _crypt library

Recommended Posts

Hi everyone,

i have a question, can somebody tell me how this code from c# would look like in autoit:

SymmetricAlgorithm crypto = new AesCryptoServiceProvider(); // Verfahren
      crypto.BlockSize = 128; // Blocklänge in Bits 
      crypto.KeySize = 128; // Key Länge in Bits 
      crypto.Key = Encoding.UTF8.GetBytes("xxxxxxxx"); // Key im Klartext 
      crypto.Mode = CipherMode.ECB; // Cipher Modus
      crypto.Padding = PaddingMode.ANSIX923; // Padding Modus 

      byte[] src = Encoding.UTF8.GetBytes(portaldata); // Convert string to byte array 
      using (ICryptoTransform encrypt = crypto.CreateEncryptor()) // encryption
        byte[] dest = encrypt.TransformFinalBlock(src, 0, src.Length); // Convert byte array to Base64 strings
        portaldata = "linkbisher.......&ck_portaldata=" + BitConverter.ToString(dest).Replace("-", "");

i'm not a programer, so this goes way beyond my knowledge in autoit. also i havn't found options for the cyphermode or padding.

one thing i've found is a base64.au3 for converting it to base

hope somebody can help me

greets georg

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...