It's not real "Zend" question. It's more PHP &amp; design patterns question. 

Problem would be that you would need to switch the instances of the Mail Transport - you're looking for Dependency injection, maybe.... or Proxy or Facade design pattern. You need ONE PLACE where you will switch the class and it will change everywhere else. I'd set that in config and have a class that loads propper class name from config and returns new instance... something like this:

TransportSelector::getTransport()-&gt;send($mail);


How to dynamically override functions using Zend?
In case of no TLS/SSL available, why can't I use the hash of the password (SHA512) as the key to encrypt the password (with out any salt) to send through the network ?
MITM attacks I can understand, but what are the other possible attacks ?
