I am using DNS load balancing in my centOs 5 server.The mail sent to the load balancer server are balanced by sending them to 4 more servers who then pass the mails to their destinations in the network.The mails are generated by a Php script which gives all the mail to the load balancer server. Now i want sasl and tls authentication in the load balancer server so that i can prevent the mail server from spammers,Can anyone tell me how to do this. The load balancer pass the mails to other servers based on equal mx record preference,so i want sasl authentication with Dns load balancing.
Your description is confusing. Are you using DNS-based load balancing or using a dedicated server as load balancer which receives the emails and forwards them to other email servers?
Anyway, the load balancer can not implement authentication mechanisms unless it understands email protocols (SMTP). So, you need to implement the authentication mechanisms on the real SMTP servers.
For TLS, it also depends on your load balancer capabilities. If you are using just a TCP-level load balancing, you should be implement it on the email servers side. The load balancer should be able to just forwards the traffic it receives. If the load balancer can understand SMTP and SMTP over SSL/TLS, you should be able to find a way to configure it on the load balancer itself.