Secure Directory access

design

#1

We currently have an hta secured directory on our site.
In the past I have only needed this for one customer.
I now need to do it for multiple customers.
I realize I can secure their individual directories with hta and give
them a direct link to the page but we also want to use a “Customer
Portal” link from the web site, have them enter credentials and based upon those credentials redirect to the appropriate directory and file.
Is there any way I can do this using the HTA functionality or will this
have to done via a database that can compare the credentials and
redirect?
Any help or ideas would be greatly appreciated.