Encode password with base64 on client side?

Hi Team,

One of my Security requirement is to encode/encrypt password on the client side itself.

I am aware of the Onvalidate and BeforeInsert options but these are once password has reached server. I would like to encode the password once the user hits the LOGIN/Submit button on the client side (in the browser) itself

Any suggestions or pointers would be appreciated.

Also, I see 2 ajax calls one for user name and one for password being fired before the submit. Any info on these would also be helpful.

Thank you.