I am developing a Django application where a user logs in with Kerberos, and then has accesses to a number of internal applications.
One of these is a file application that connects to a server over SFTP and allows the user to browse their stored files. Because this would result in needing to authenticate with that server several times over the life of the session, I would like the cache the password that a user enters when they first log in to the site in some way but, due to security concerns, I don't want to just save the password as plaintext in the server's database.
My current thought is to use AES, or some other similar cryptographic algorithm, and store half of the data needed to decode the password in a server-side session and the other half in a client-side browser cookie.
Would this be a good idea? Can you suggest any other solutions?