Added cryptographically secure state token functionality