Yes, It can be done, it's just a question about understanding the question right.
Is the arrangment like this:
There is a lan segment that is connected to internet via two sme servers running in server gateway mode.
There is also (already) two external ip's, one for each server.
Gateway server A should work as a gateway/(proxy) (only).
"Gatway server" B should actually not be working as a gateway, but as an external and internal web and mail server allowing mail and web clients, but it should not be allowed to work as an gateway, allowing traffic to pass out to internet, is this correct understood ?
What is the network address to the lan segment ? (10.0.0.0/255.255.255.0 192.168.0.0/255.255.255.0 etc)