Forum Discussion
Mike_Pimlott_61
Nimbostratus
Nov 28, 2006SMTP response code checking
Hi (again)
why is it that first forays into coding always happen to be the difficult things to get your head around?
I need to see if there is a way in which I can query an SMTP packet to get the response code to query for a 5xx error, to then pass this to a pool with a very low connection limit?
the pool will have members which are attributed to another pool for all email, so I need to make it simpler I think. so. check all SMTP traffic to look for an SMTP error code (550 etc.) to limit connections to the mail server, whilst letting the other SMTP traffic pass through unlimited to the "proper" mail pool.
any suggestions? I have tried the following as the first pass;
when CLIENT_ACCEPTED {
log local0. "this is the TCP payload: [TCP::payload]"
if {[TCP::local_port] == 25} {
TCP::collect 200
}
}
when CLIENT_DATA {
if { [TCP::payload] contains "550 " } {
pool no_NDR_allowed}
else {pool IMWW_Pool}
TCP::release
}
but it just stops all mail - any help appreciated.
- hoolio
Cirrostratus
Hello,
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects