Re: Protocol Event sink

From: Peter Karsai (welcome.home_at_[127.0.0.1)
Date: 09/21/04


Date: Tue, 21 Sep 2004 12:56:49 +0200


"Razzie" <razzie@quicknet.nl> wrote in message
news:eQiHfy7nEHA.3392@TK2MSFTNGP15.phx.gbl...
> On a follow-up question:
>
> If I use my own SMTP server and I type a non-existing recipient, for
> example, wrong domainname, I also get a response 'could not relay to
> recipient' or something like that. That is a simple return status as well
> isn't it?

Well, yes...

> How is that accomplished then? Exchange doesn't do that, but
> surely it must be possible in a similar way using SMTP sink for Exchange
> server?

Relay restrictions are managed by the SMTP Service itself, without event
sinks. As far as I know this remains the responsibility of the SMTP Service
even after Exchange hooks it.

Regardless of the above, you can also easily reject any arbitrary recipient
using a protocol event sink which hooks RCPT. Use pContext.SetResponse() to
set the textual response (must include the trailing CRLF!),
pContext.SetSmtpStatusCode() to set the status code to e.g. 550,
pContext.SetCommandStatus() to EXPE_SUCCESS (also
pContext.SetProtocolErrorFlag()) Don't forget to set the return value to
EXPE_S_CONSUMED, otherwise some event sinks may pick up the event.

  Peter Karsai
  http://www.vamsoft.com/orf



Relevant Pages

  • Re: Check that user exists
    ... The key to this whole problem is ensuring that your event sink runs ... have no effect as the SMTP server always accepts the recipient. ... The only other thing i can think of is to use another SMTP ... *before* mail arrives at the drop directory. ...
    (microsoft.public.exchange2000.development)
  • email bouncing
    ... particular outside recipient. ... error message is: ... There was a SMTP communication problem with the recipient's email server. ... but added isp's smtp server. ...
    (microsoft.public.backoffice.smallbiz2000)
  • Re: Check that user exists
    ... I've been trying to do something similar using the OnSmtpInCommand ... have no effect as the SMTP server always accepts the recipient. ... The documentation for event sink interfaces seems lacking as I can't ... The only other thing i can think of is to use another SMTP ...
    (microsoft.public.exchange2000.development)
  • Re: Cant get IMF installed. No Event 7513
    ... I'm using ORF-EE Its an event sink ... that makes sure the host connecting to the SMTP Server is not on a BlackList ... So it should not impact the IMF. ...
    (microsoft.public.exchange2000.setup.installation)
  • Re: Cant get IMF installed. No Event 7513
    ... I'm using ORF-EE Its an event sink ... that makes sure the host connecting to the SMTP Server is not on a BlackList ... So it should not impact the IMF. ...
    (microsoft.public.exchange2000.admin)

Loading