I want to encrypt a URL variable so that the user can\'t see or modify the information when it is passed in jsp.
This is an example URL:
localhost/somew
Always use POST
method.
And even in POST
method, user can see the id
and can change it in browser console network tab.So that, user can see other's email attachment since you mentioned in your comment like that.
So, try to set id
in jsp session and get the id in the java servlet code.
it is really good practice.