Hi all,
I have a conceptual problem, maybe somebody has an idea how I could
solve it ...
I have an application let's call it MyProxy that is responsible of doing
let's say
email compression (it's more but it's not important). This application
is started as a parameter with the name of the config file
specific to each user. Let's say that a user wants one kind of
compression or some other features,
and another user from the same machine doesn't want it. That is why for
each user there is a
specific config file used by MyProxy.
For all emails sent/recv by an email client to go through MyProxy, I use
an LPS (Layered Service Provider)
that redirects all the connection of ports 25 and 110 to MyProxy which
is listening to port let's say 65000.
The problem I have is related with the Windows XP feature: 'fast
switching' between users!
Let's say user A is having opened an email client and also MyProxy is
running (this runs always in the background),
and now the computer is 'fast switched' to the user B. Now it is tried
the MyProxy application to
be started for the user B, but this will fail with the error 'address
already in use' as seems
that MyProxy for user A is still running.
Problems:
1) If in the scenario above the user B is sending emails those will be
redirected to port 65000
which is the MyProxy of the user A so has the config for user A, so I
get into problem here.
2) I might somehow probably shutdown MyProxy for user A when he tries a
'fast switching'
to another user, so the user B My Proxy can be started and everything
looks fine. But if the user
A let some email clients opened that checks the email from time to time,
those emails
will go again through the MyProxy of user B, so this is not a solution.
3) I could change the MyProxy application: if I get the error 'address
already in use' to use
another port let's say 65001. This will work, but if user B knows the
port where the MyProxy is listening for user
A he could send emails in the name of A if he knows pass and everything
and it will be using the setting
of MyProxy config of user A, which will again be a problem.
So, in other words, how could I have something like a server that is
listening for all
users on the same port, but still on a 'fast switching' of the users to
be still working
with the specific user config file and to not be exploatable?
I don't have this problem with a real log off, because then all the
applications of user A
will be closed before the user B logs in.
Thanks in advance and sorry for the long post,
Viv