$datetime = [datetime]::Parse('2014-09-12 15:37:40.400').AddTicks(2002)

$salt = '{0:x2}' -f $datetime.Ticks

$imei = 866265033978752

$string = "$imei$salt"

$hashBuilder = New-Object System.Text.StringBuilder

[System.Security.Cryptography.HashAlgorithm]::Create('SHA256').ComputeHash([System.Text.Encoding]::UTF8.GetBytes($string)) | ForEach-Object {
    [void]$hashBuilder.Append($_.ToString('x2'))
}

$hash = $hashBuilder.ToString()