Tag Archives: authentication

HMAC summary

This article is the summary of a HMAC video: https://www.youtube.com/watch?v=KglnT_KwO0M Below is the tradition private / public key applicaiton. Mostly, they are for encrypting data and signing signature: The problem is that encrypting/decryptingcomputation takes a lot of CPU. It is slow. Instead, we can choose a symmetric key, like below: x is the message,  it could be large.… Read More »

Google Oauth 2.0

Finally got my google oauth 2.0 worked. It took me 2 weeks researching on it. One suggestion is that we don’t use the provided google packages. I’ve been trying so many java examples, but they always has this or that problem. In the end, I turned back to the pure GET, POST, ajax to test it.… Read More »

JWT sample, and implementation in node.js and java

This is quoted from here link. The following example JOSE Header declares that the encoded object is a JSON Web Token (JWT) and the JWT is a JWS that is MACed using the HMAC SHA-256 algorithm: {“typ”:”JWT”, “alg”:”HS256″} To remove potential ambiguities in the representation of the JSON object above, the octet sequence for the… Read More »