Example: /Encryption/SHA/SHA 256

Online Documentation   -   Statistics   -   FAQ   -   Plugin Parts (All, Dependencies)   -   Class hierarchy

New in Version 22.2 22.3 22.4 22.5 23.0 23.1 23.2 23.3 23.4 23.5 24.0 24.1

The list of the   topics,   classes,   interfaces,   controls,   modules,   global methods by category,   global methods by name,   screenshots,   licenses   and   examples.

Platforms to show: All Mac Windows Linux Cross-Platform

/Encryption/SHA/SHA 256


Required plugins for this example: MBS Util Plugin, MBS Encryption Plugin

You find this example project in your Plugins Download as a Xojo project file within the examples folder: /Encryption/SHA/SHA 256

This example is the version from Sun, 17th Mar 2012.

Project "SHA 256.xojo_binary_project"
Class App Inherits Application
Const kEditClear = "&Löschen"
Const kFileQuit = "Beenden"
Const kFileQuitShortcut = ""
EventHandler Sub Open() dim s1 as string = SHA256MBS.HashText("Franz jagt im komplett verwahrlosten Taxi quer durch Bayern") if s1 = "d32b568cd1b96d459e7291ebf4b25d007f275c9f13149beeb782fac0716613f8" then // ok else MsgBox "Failed" end if dim s2 as string = SHA256MBS.Hash("Frank jagt im komplett verwahrlosten Taxi quer durch Bayern") dim e2 as string = EncodingToHexMBS(s2) if e2 = "78206a866dbb2bf017d8e34274aed01a8ce405b69d45db30bafa00f5eeed7d5e" then // ok else MsgBox "Failed" end if dim s3 as string = SHA256MBS.Hash("") dim e3 as string = EncodingToHexMBS(s3) if e3 = "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" then // ok else MsgBox "Failed" end if dim s as new SHA256MBS s.Add "Franz jagt im komplett" s.Add " verwahrlosten Taxi quer" s.Add " durch Bayern" dim r as string = s.ResultText if r = "d32b568cd1b96d459e7291ebf4b25d007f275c9f13149beeb782fac0716613f8" then ' MsgBox "OK" else MsgBox "Failed" end if MsgBox "OK" End EventHandler
End Class
MenuBar MenuBar1
MenuItem FileMenu = "&Ablage"
MenuItem FileQuit = "#App.kFileQuit"
MenuItem EditMenu = "&Bearbeiten"
MenuItem EditUndo = "&Rückgängig"
MenuItem UntitledMenu1 = "-"
MenuItem EditCut = "&Ausschneiden"
MenuItem EditCopy = "&Kopieren"
MenuItem EditPaste = "&Einfügen"
MenuItem EditClear = "#App.kEditClear"
MenuItem UntitledMenu0 = "-"
MenuItem EditSelectAll = "&Alles auswählen"
End MenuBar
End Project

See also:

The items on this page are in the following plugins: MBS Encryption Plugin.


💬 Ask a question or report a problem