i have 2 portal, one and two. The portal one have all apis, and the portal Two have the interfaces, Here just i am doing enter the username and password in the login page so that will go the method of Portal Two. Then it will pass the username and password of a method of Portal One, this is am doing here. My question is how to do the basic authorization for encrypt the username and password
res = RestClient::Resource.new url, :user_name => params[:name], :password => params[:password]
Bcz now here the username and password is plain text. How to do the Basic Authorization here…Any help would be appreciated: please give one clarification of that.
This is just a simple custom solution I created. I also went back and
built my own image verification system and tied it into this custom
solution.
But, I provided you the basics for handling authentication.
In my DB schema, my password field is called :password_digest. You
could feasibly name your password field in your DB to anything you
wanted. You just have to edit the methods I provided in the gist.
I also copied much of this initial code right from Rails when I first
started using Bcrypt.
This is just a simple custom solution I created. I also went back and
built my own image verification system and tied it into this custom
solution.
basically my doubt is the HTTP BASIC authentications says… Example…if the username is “user” and password is “password”. “user:password” it will converted into via basic64 ecoding, then we will get like this