Iis SMTP relay Content-encoding

I am using IIS 6 SMTP Virtual Server to relay messages from our internal network to Exchange Online. This is working correctly except for one minor problem.
When using Task Scheduler to send an email with attachment (using the built in send email function), the attachment cannot be opened. When attempting to open an excel file (.xlsx, or .xlsm) sent by a scheduled task, Excel states "The file is corrupted
and cannot be opened", or "Excel found unreadable content in <filename.xlsm>". 
By monitoring the SMTP queue folder, I can see the Content-Transfer-Encoding is set to base64 for emails with attachments sent by our other automated systems. However, excel files sent by Task Scheduler are
incorrectly set to 8 bit instead. This only seems to happen with Excel files. Files with .pdf or .docx extensions can be opened after being emailed
by Task Scheduler.
My best guess is that this is a failing of the SMTP relay. Is there some way this can be configured to encode Excel attachments as base 64?

I would recommend asking them here: http://forums.iis.net/
This posting is provided AS IS with no warranties or guarantees , and confers no rights.
Ahmed MALEK
My Website Link
My Linkedin Profile
My MVP Profile

Similar Messages

  • IIS SMTP Relay

    We are using windows server 2008 Server R2. We installed IIS and the SMTP relay component. It is setup to relay mail to our exchange 2010 CAS server. All internal mail is relaying properly on this server to the exchange 2010 CAS server to internal email
    addresses. When someone tries to send to a recipient outside the organization such as to domain name hotmail.com, gmail.com microsoft .com, it does not relay the message. When I check the logs it looks like it does not even relay the external email address
    to the cas server.
    The error message we get is below. Please assist in what is wrong.
    Delivery has failed to these recipients or groups:
    [email protected]
    Your message wasn't delivered due to a permission or security issue. It may have been rejected by a moderator, the address may only accept e-mail from certain senders, or another restriction may be preventing delivery.
    Diagnostic information for administrators:
    Generating server:PRI.cross.com
    [email protected]
    #< #5.7.1 smtp;550 5.7.1 Unable to relay> #SMTP#
    Original message headers:
    Received: from HH-DATAserver ([192.111.111.2]) by PRI.cross.com with
    Microsoft SMTPSVC(7.5.7601.17514); Wed, 7 May 2014 20:12:03 -0300
    From: hh-dataserver <[email protected]>
    To: <[email protected]>
    Date: Wed, 7 May 2014 18:12:03 -0500
    Subject: test messase
    X-Mailer: SMTP Mail Component
    MIME-Version: 1.0
    Content-Type: text/plain; charset="us-ascii"
    Return-Path: [email protected]
    Message-ID: <[email protected]>
    X-OriginalArrivalTime: 07 May 2014 23:12:03.0714 (UTC) FILETIME=[C2029620:01CF6A49]

    Hi,
    Is there any update on this thread?
    Thanks,
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Simon Wu
    TechNet Community Support

  • Messages queueing usng IIS SMTP Relay server for Office 365

    We have SMTP relay server in IIS for office 365. We followed the setup provided by Microsoft but messages are stuck inside the queue folder.
    Any help? 

    Hi,
    Anything updates now?
    Which sutup you have followed? Did you mean that SMTP server didn't deliver the mail? If yes, please check the -delivery report -delivery report would be created in the C:\InetPub\MailRoot\BadMail folder.
    In addition, since it is related to IIS, you can also ask in IIS forum below for professional assistance:
    http://forums.iis.net/
    Best regards,
    Susie

  • IIS SMTP Unable to relay 2012 R2 Essentials

    I stopped receiving server health reports from all the Server 2012 Essentials R2 servers that I support. This is due to daylight savings. I will defer to the other post. I've been on the phone with office 365 support and confirmed that SMTP relay in IIS
    is functioning so it looks to be a problem with the snap-in to manage server 2012 essentials that emails health reports.

    Hi,
    Please logon Windows Server 2012 R2 Essentials and open Dashboard, select HOME tab and click Health Report.
    Would you please let me know the Status of this problematic report? Meanwhile, please click this problematic report and check
    General information about this Health Report (at the bottom of the panel) if find more clues.
    Meanwhile, please open Services panel and navigate to
    Windows Server Essentials Management Service, then check if this service ran as normal. Please restart
    Windows Server Essentials Management Service and check if this issue still exists.
    If any update, please feel free to let me know.
    Hope this helps.
    Best regards,
    Justin Gu

  • Cannot get db mail to work via SMTP Relay for Office 365 in SQL Server 2014 on Windows Server 2012 R2

    Our company recently moved to Office 365 which mean our on premise exchange server went away as well with the move.  I am trying to configure my new sql server (OS-Windows Server 2012 R2, DBMS- SQL 2014 Std Edtion).  After some searching I found
    this article (http://blogs.technet.com/b/meamcs/archive/2013/02/25/how-to-configure-sql-database-mail-so-send-emails-using-office-365-exchange-online-a-walkthrough.aspx) and have followed these steps exactly, but to no avail.  I did some further research
    on the SMTP relay I setup and found a way to test it (listed here http://technet.microsoft.com/en-us/library/dn592151(v=exchg.150).aspx at the bottom of the article).  If I drop the email.txt file in the pickup folder, it gets sent out no problem.
     I have configured my db email exactly as describe here(http://blogs.technet.com/b/meamcs/archive/2013/02/25/how-to-configure-sql-database-mail-so-send-emails-using-office-365-exchange-online-a-walkthrough.aspx).  But keep getting an unable to connect
    to SMTP server error.  I have even tried completely shutting down firewall to see if that is the issue and multiple restarts.  Any ideas how to get this to work on Office 365?
    DB Mail error log:
    Date 6/10/2014 10:28:41 PM
    Log Database Mail (Database Mail Log)
    Log ID 46
    Process ID 2196
    Mail Item ID 19
    Last Modified 6/10/2014 10:28:41 PM
    Last Modified By xx
    Message
    The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 2 (2014-06-10T22:28:41). Exception Message: Cannot send mails to mail server. (Failure sending mail.).

    Hi,
    I followed this blog and got the below error message in the Database Mail Log.
    “The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 2 (2014-06-11T19:34:00). Exception Message: Cannot send mails to mail server. (Mailbox unavailable. The server response was: 5.7.1 Unable to relay
    for [email protected]).”
    If you are getting the same error message, you can try the below steps to resolve the issue.
    1. Open the IIS 6.0 management console. Right click on the SMTP server and open the properties window.
    2. Click on the Access tab, click Relay button under Relay restrictions. loopback IP address (i.e 127.0.0.1).
    Then the email should be sent out from Database Mail without problem.
    Thanks.
    Tracy Cai
    TechNet Community Support

  • Smtp relay on osx 10.9.5 and server 3.2.2

    What we have
    We have a mac mini setup using 10.9.5 and server 3.2.2.    The mail server is OFF but we have a Relay Outgoing Mail through ISP checked (and the proper credentials for the outgoing relay (FQDN) and the authorization credentials.
    What we are trying to do
    Our mac mini runs a php script to generate an email that needs to be sent to users.   The mail has to use a smtp relay and we are trying to use the smtp relay provided by our email vendor.
    Settings required by our email vendor
    Instructions for configuring an email client can be found here
    https://www.namecheap.com/support/knowledgebase/article.aspx/1179/2175/general-c onfiguration-for-mail-clients-and-mobile-devices
    We set up the relay in Mail on the Server 3.2.2 to use SSL and port 465.  In our particular case the relay is configured as shown below.  Obviously the [email protected] is the proper username for our authorization.
    When we try to send mail (we test this function by sending mail from terminal by using the following command (sending mail to myself from myself)
    printf "Subject: TestnHello" | sendmail -f [email protected] [email protected]
    and then watch the mail logs the smtp server rejects our mail due to authorization issues.  The mail log text is shown below (email addresses replaced with [email protected] and IP addresses modified)
    Dec 22 11:57:03 109-218-164-81.lightspeed.austtx.sbcglobal.net postfix/pickup[16825]: 5545383231: uid=501 from=<[email protected]>
    Dec 22 11:57:03 109-218-164-81.lightspeed.austtx.sbcglobal.net postfix/cleanup[16827]: 5545383231: message-id=<[email protected]bal.net>
    Dec 22 11:57:03 109-218-164-81.lightspeed.austtx.sbcglobal.net postfix/qmgr[16826]: 5545383231: from=<[email protected]>, size=340, nrcpt=1 (queue active)
    Dec 22 11:57:03 109-218-164-81.lightspeed.austtx.sbcglobal.net postfix/error[16838]: 5545383231: to=<[email protected]>, relay=none, delay=0.04, delays=0.02/0/0/0.02, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to eforwardct3.name-services.com[216.163.176.39]:465: Connection refused)
    Dec 22 11:57:05 109-218-164-81.lightspeed.austtx.sbcglobal.net postfix/master[16824]: master exit time has arrived
    We find many self help pages on the internet that talk about modifying the main.cf file located at /Library/Server/Mail/Config/postfix.   Some even talk about modifying settings in the master.cf file in /ect/postfix.  I have tried several and none seem to work.
    Can anyone provide some guidance?
    Regards!

    The Server GUI doesn't provide for this use case.
    Take the following steps to configure Postfix to relay mail to a remote SMTP server with password authentication over SSL. Substitute as required for strings in italics below. Address is the fully-qualified domain name of the relay host. The value of port is usually either 25, 465, or 587. Username and password refer to your credentials on the relay host.
    In the current version of OS X Server (but not necessarily in older versions), Steps 1 and 3 should be done for you when you enable relaying and relay authentication in the Server application.
    1. If necessary, create or update the relayhost directive in
         /Library/Server/Mail/Config/postfix/main.cf
    It should look like this:
         relayhost = [address]:port
    2. Add these lines, above the section at the end that begins with the comment "# Mac OS X Server":
         smtp_sasl_security_options =
         smtp_tls_CAfile = /etc/certificates/relayhost.pem
         smtp_tls_session_cache_database = btree:$data_directory/smtp_tls_session_cache
         smtp_use_tls = yes
    3. If it doesn't already exist, create the password file
         /Library/Server/Mail/Config/postfix/sasl/passwd
    with this content:
         [address]:port
         username:password
    Here address must match $relayhost.
    Then create the password database:
    sudo postmap /Library/Server/Mail/Config/postfix/sasl/passwd
    This action creates the file
         /Library/Server/Mail/Config/postfix/sasl/passwd.db
    The two password files should be readable by root only.
    4. Create the file
         /etc/certificates/relayhost.pem
    with the CA certificate(s) to be trusted for authentication of the remote host. You get those certificates from the service provider. If you can't find a link to download them, try this:
    openssl s_client -connect address:port -showcerts < /dev/null | sed -n '/-BEGIN /,/-END /p' | sudo sh -c 'cat > /etc/certificates/relayhost.pem'
    The command may produce an error message that isn't necessarily significant. For servers that use the older STARTTLS protocol, rather than straight TLS or SSL, this command may need to be modified.
    5. Restart the Mail service.

  • IIS SMTP instead of Exchange 2007 on SBS 2008

    We have recently moved a client from Exchange 2007 on a 2008 Small Business Server over to Office 365. We would like to disable Exchange 2007 altogether in order to free up resources on an already overworked server. However, we have a couple of multifunction
    devices that require an unauthenticated SMTP relay for email. I believe the easiest solution available to us is to enable SMTP in IIS and limit the relay to certain internal IPs. Assuming Exchange is fully disabled, would this be a viable solution? Given that
    we are still running IIS internally, I would see this as a net gain in terms of system resources.

    It is not possible.

  • IIS/SMTP - emails are stuck in mailroot/Queue

    we are using exchange 2010 for our messaging solutions. we also have once of our web server,  for some our requirements our web application server need to send  mails  through our exchange server.  to do that we had enabled the smtp
    virtual server in IIS 6.0 , created the receive connector in exchange, I am trying from the website and all the mails  which I am sending  was stored in iis mail root queue folder.  if any body help me to send that mails
    to that recipients.
    Best Regards
    Jaga
    Jags

    Hi Jaga,
    I would absolutely not install IIS SMTP on your Exchange Server, Exchange uses its own SMTP engine since Exchange 2007 and does not rely on IIS anymore. You may find it is not working because it is trying to listen on the same port and IP address that the
    Exchange Transport service is already running on.
    Remove IIS SMTP from your Exchange 2010 Server. Then:
    1. Either configure your web application to authenticate against your Exchange server, or
    2. Allow the web application to be able to anonymously relay through your Exchange servers Receive Connector.
    "Allow Anonymous Relay on a Receive Connector"
    https://technet.microsoft.com/en-us/library/bb232021%28v=exchg.141%29.aspx?f=255&MSPPError=-2147217396
    Oliver Moazzezi | Exchange MVP, MCSA:M, MCITP:Exchange 2010,Exchange 2013, BA (Hons) Anim | http://www.exchange2010.com | http://www.cobweb.com | http://twitter.com/OliverMoazzezi

  • How to use multiple mail sending address in SMTP relay for exchange online

    We have one SMTP relay configured with [email protected] credentials. one oracle application automatically shoots mail to users using this [email protected] to users. So if recipient reply on auto-generated mail it goes to mailbox of [email protected] (so that application
    team see and reply to any query raised by recipient). 
    Now my requirement is, I want to notify users about their password expiry before 10  days (something like that) I have made the script and tested it in lab. But the main requirement is I want to use [email protected] mail ID for sending mail. And if any recipient
    reply on the auto-generated mail it goes to [email protected] mailbox (which is managed by different team).  
    So the query How can I use two different mailbox enabled IDs for sending mails on a single SMTP Relay server
    Thanks
    Pankaj Sharma

    Thanks Ed and Mavis for the reply and suggestion, but here scenario is different. 
    We have one SMTP relay configured with [email protected] credentials. one oracle application automatically shoots mail to users using this [email protected] to users. So if recipient reply on auto-generated mail it goes to mailbox of [email protected] (so that
    application team see and reply to any query raised by recipient). 
    Now my requirement is, I want to notify users about their password expiry before 10  days (something like that) I have made the script and tested it in lab. But the main requirement is I want to use [email protected] mail ID for sending mail. And if any recipient
    reply on the auto-generated mail it goes to [email protected] mailbox (which is managed by different team).  
    So the query is can I use two different mailbox enabled IDs on a single SMTP Relay, If yes then how..
    Thanks
    Pankaj

  • How do I set up an account to receive email from my SMTP relay Server. Have I made a SMTP Server config error?

    Hi,
    How do I set up an account to receive email from my SMTP Relay Server?
    I've setup the SMTP feature and set my Server to use anonymous authentication.
    Things appear to look ok.
    But I can't connect make a test connection to it when I am trying to add an email account in Outlook.
    I could be doing something wrong here.
    This is my process.
    1. I have setup my SMTP Server.
    2. Created a user account in AD and given it an email address.
    3. Opened Outlook and tried to manually add a POP3 account by specifying the incoming and outgoing Server details.
    But when I go to test the connection on the email setup it keeps failing.
    Please help.
    Thanks

    Hi Midi25,
    As Florent suggested, please use Telnet to test SMTP Communication. For more details, please refer to following articles.
    How to Use Telnet to Test SMTP Communication
    XFOR: Telnet to Port 25 to Test SMTP Communication
    In addition, please also refer to following article and check if can help you.
    How to Configure a Windows Server 2003 Server as a Relay Server or Smart Host
    Best regards,
    Justin Gu
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact [email protected]

  • Firefox gives "content encoding error" for multiple sites (mostly forums), however, wget can open those sites just fine

    I am working under a corporate proxy server, so this might influence the problem. From home i can access the sites just fine. From here - it gives "content encoding error" on different kinds of forums. For example, http://www.freeallegiance.org/forums/index.php?act=home
    I tried to download wget and could download the website htm file just fine!

    I also have this problem. I believe it is caused by being connected through a proxy which is adding a second compression to the data. (I think IF uses gzip compression already).
    Added details:
    * Opera also works.
    * I can view the IF admin section on FF
    * I can view the forum if I go through a web proxy.

  • Mail Receiver Adapter Attachment Content Encoding

    Hello to all,
    we use a mail receiver adapter to sent XI messages as email. Everything works fine but the content encoding of the  attachment is set to UTF-8. I need ISO-8859-1 instead of UTF-8. How could I achieve this ?
    Thanks Christian

    Hello Stefan,
    we've tried this too (content type to: text/plain;charset="ISO-8859-1"), but it didn't work.
    This is our output structure
    <?xml version="1.0" encoding="ISO-8859-1"?><ns:Mail xmlns:ns="http://sap.com/xi/XI/Mail/30"><Subject>Daten von 01.07.2008 12:20</Subject><From>mail(at)dummy.de</From><To>max.muster(at)web.de</To><Content_Type>multipart/mixed; boundary="--AaZz"</Content_Type><Content>----AaZz
    Content-Type: text/html; charset=ISO-8859-1
    Content-Disposition: inline
    Mit freundlichen Grüßen
    ----AaZz
    Content-Type: text/plain; charset=ISO-8859-1; name=Daten 01.07.2008 1220.txt
    Content-Disposition: attachment; filename=Daten 01.07.2008 1220.txt
    "N";2000000003;"1234123412341234";1234500009;000000000000;01;"L";"OKDAU";1;"Prof. Dr.";"Max";"Mustermann";"";"Musterstraße";"";000000;"PLZ45";"Musterhausen";"";19990101;"max.mustermann(at)muster.com";"";"";"";"";"1";"Titel";"Vorname";"Name";"20000101";"";"0";"Max Mustermann";"L";"BLZ";"100000001";"Musterbank";00;;01;000000;;;00;1;0;0;1;0;"ForumNr";1;1;0;1;0;1;0;0;20080620;0;;0;20080620;0;20080620;0002;STANDARD
    "N";2000000004;"5678567856785678";1234567009;000000000000;01;"L";"OKDAU";1;"Prof. Dr.";"Stefan";"Maier";"";"Teststraße";"";000000;"PLZ65";"Testhausen";"";19991201;"stefan.maier(at)test.de";"";"";"";"";"1";"Titel";"Vorname";"Name";"20001201";"";"0";"Stefan Maier";"L";"BLZ";"100000001";"Testbank";00;;01;000000;;;00;1;0;0;1;0;"ForumENr";1;1;0;1;0;1;0;0;20080620;0;;0;20080620;0;20080620;0002;STANDARD</Content></ns:Mail>
    But the attachment is UTF-8
    Thanks for your help.
    Christian

  • Have to add 0.0.0.0/0 to "Accept SMTP relays only from these"?

    To reach the server via vpn I had to add a virtual IP (192.168.1.1) to the ethernet port. Since then mail acts a bit strange: I have to add 0.0.0.0/0 to "Accept SMTP relays only from these" in SA. Otherwise i get a "[/var/imap/socket/lmtp]: Connection refused" in the smtp log and the server does not accept any delivery of mails from the internets.
    I'm not quite sure if it's a good idea. Can anyone please tell if this is still a security risk (while having access restrictions on the mail service)?

    After a few telnet tests I can answer my own question: It makes an open relay server to spammers! But to solve the former issue with the connection refuse, I had to switch to virtual hosting in the advanced tab of the mail service and add my own domains.

  • Using CUE as SMTP relay

    Hello world...
    I hope someone has an answer to this - i have gone through the CUE CLI documentation looking to config it up as an SMTP relay, and this idea does not seem like it will work.
    System is UC540 on 8.6.5
    I have a PRI with a DID block for the client - they want individual fax numbers for each person.  That part is easy enough.  They do NOT want to store it in their vociemail box.  They just want it sent to their email inbox.  They do not want to use the "listen" mode where fax and voice comes in on the same DID because the delay for the customer calling in is too great in their opinion.  This is fine.  I get it.
    However I am having a dickens of a time using the CUE to send the emails based upon the DID to the user mailbox.  I am talking about configuring a separate ephone-dn and an account on the CUE for the fax email user.  when i go this route, The sending fax machine just hangs and never successfully transmits.
    IF, however, I set the "mta send server" to my test-bench smtp relay by IP address, it all works.  Fax as email attachment comes through like greased lightning.
    I try to do it via the extension and have CUE submit it out, things just hang.
    IS THERE A WAY to configure the CUE to act as a simple SMTP relay for all things internal?
    This is the config that works for me:
    mta send server 192.168.110.25 port 25 <IP addess of my bench smtp server>
    mta send server 10.10.10.1 port 25
    mta send with-subject both
    mta send mail-from hostname LAB-UC540.lab.org
    mta send mail-from username $s$
    mta receive aliases 10.10.10.2
    mta receive maximum-recipients 7
    For the MMOIP, I have:
    dial-peer voice 3020 pots
    translation-profile incoming Lab_Fax_T37_Called_26
    service onramp
    incoming called-number 4627
    direct-inward-dial
    port 0/2/0:23
    dial-peer voice 1801 mmoip
    service fax_on_vfc_onramp_app out-bound
    destination-pattern 4627
    information-type fax
    session target mailto:[email protected]
    The above works remarkably well
    This (generic CCA config) is broken:
    dial-peer voice 3020 pots
    translation-profile incoming Lab_Fax_T37_Called_26
    service onramp
    incoming called-number 4627
    direct-inward-dial
    port 0/2/0:23
    dial-peer voice 1800 mmoip
    description ** fax onramp for outbound faxmail to CUE **
    service fax_on_vfc_onramp_app out-bound
    destination-pattern ^....$
    information-type fax
    session target mailto:[email protected]
    fax receive called-subscriber $d$
    fax interface-type fax-mail
    mta send server 10.10.10.1 port 25
    mta send with-subject both
    mta send mail-from hostname 10.10.10.2
    mta send mail-from username $s$
    mta receive aliases 10.10.10.2
    mta receive maximum-recipients 7
    Any suggestions?  Or do I build a small internal LAN smtp relay server?

    Hello,
    The CUE is used with the script for t37 - there are two approaches with fax to email.
    One is using the CUE and the other is not using CUE just to add the right information.
    For more information:
    http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/unity_exp/rel3_1/administration/guide/voicemail/fxgatewy.html
    https://supportforums.cisco.com/docs/DOC-9718
    HTH,
    Alex

  • How can solve the problem in email " SMTP Relay "Message rejected" ", how can solve the problem in email " SMTP Relay "Message rejected" "

    Dear sirs,
    how to solve the mail problem which occurs while I am abroad; bearing in mind that I use HOTSPOT and sometime it's sending emails sometime getting the below messages " SMTP Relay "Message rejected"

    The outgoing mail server is rejecting mail from your network address. Typically that happens when your mail service provider is also your ISP, and you connect to it from another network. The SMTP server will allow connections without a password from anywhere, but it will only relay mail from within the ISP's network. It could also be that your account on the server has expired or been suspended.
    If you need to send mail from outside your ISP's network, use an independent mail service provider. I don't have a specific recommendation.

Maybe you are looking for