Hash

Syntaxes

Version

%texts% hash[ed] with (MD5|SHA-256)

2.0, 2.2-dev32 (SHA-256 algorithm)

Hashes the given text using the MD5 or SHA-256 algorithms. Each algorithm is suitable for different use cases. MD5 is provided mostly for backwards compatibility, as it is outdated and not secure. SHA-256 is more secure, and can used to hash somewhat confidental data like IP addresses and even passwords. It is not that secure out of the box, so please consider using salt when dealing with passwords! When hashing data, you must specify algorithms that will be used for security reasons!

Please note that a hash cannot be reversed under normal circumstanses. You will not be able to get original value from a hash with Skript.

Exemples:

command /setpass :
    trigger:
        set {password::%uuid of player%} to text-argument hashed with SHA-256
command /login :
    trigger:
        if text-argument hashed with SHA-256 is {password::%uuid of player%}:
            message "Connexion réussie !."
        else:
            message "Mauvais mot de passe!"

Last updated

Was this helpful?