Access SMTP Server Messages & Responses

I have the need to be able to send an email and a fax (via smtp) to two different servers. I've got the email portion set up, but I'm having trouble with the fax. The problem is that the RCPT TO: and the To: portion in the DATA: sections need to be different. I need to be able to see what I'm sending to the server and what the response I get back from the server on each individual line. Is this possible with JavaMail?
Example (first line = message sent to server, second line = server response):
This information was obtained by rolling my own smtp mail app. Please notice the differences between RCPT TO: and To:
=>HELO
=>250 sbfax001.stars-net.com Hello [12.28.86.153]
=>MAIL FROM: [email protected]
=>250 2.1.0 [email protected]...Sender OK
=>RCPT TO: "FAX=/NUM=1-806-345-2713/NAME=Wil Caetano/FROM=Kenan Dalley"@sbfax001.stars-net.com
=>250 2.1.5 "FAX=/NUM=1-806-345-2713/NAME=Wil Caetano/FROM=Kenan Dalley"@sbfax001.stars-net.com
=>DATA
=>354 Start mail input; end with <CRLF>.<CRLF>
=>From: Kenan Dalley <[email protected]>
To: Wil Caetano <[email protected]>
Subject: Test subject
Mime-Version: 1.0
...(etc)...
=>250 2.6.0 <[email protected]> Queued mail for delivery
=>QUIT
=>221 2.0.0 sbfax001.stars-net.com Service closing transmission channel

Ok. I see the getDebug(true) [and with 1.3.0 getDebugOut(InputStream)] to be able to see the messages to and from the server. I guess my remaining question is: Can I set the RCPT TO different from the To: in the DATA section with JavaMail?

Similar Messages

  • Howto access smtp server on-the-go

    Typically, I use outgoing.verizon.net as my smtp server for sending mail with my FIOS email address. Is there another server/port I can use to send mail from my verizon account when I'm away from home?

    You're meant to use the outgoing mail server supplied by the ISP of the machine you are using.  Using the Verizon outgoing server may work but typically will get rejected for "relaying".  You can use the Verizon webmail interface which will work or the webmail interface for the isp who handles your mail box or you could get a free gmail account that supplies you with a gmail smtp server that always appears to work.

  • Programatically access Unity server messages [unity 7x]

    Hi,
        Using Curl is it posible to access the inbox data from the unity server or using some Soap API's
    or is there any direct access to the database of the unity server ?
    I am using the version 7.1.2.20000 .
    Please help me on this.
    thanks/Chandar

    You can easily get the number of subscribers (users with voice mail boxes stored in Exchange or Domino) out of the Unity database -
    a couple of examples on the old samples page referenced above have that - connect to the UnityDirDB and get a count of users in the vw_Subscriber view that have a subscriber type of 1 or 3 (Exchange or Domino respectively).  Other subscriber types are remote users that don't have mailstores attached to Unity (i.e. SMTP/VPIM/Bridge/AMIS users).
    To get at the mailstore, as noted, you have to go through whatever storage Unity is attached to (Exchange 55/2000/2003/Domino).  With Exchange the most common method is IMAP - Unity uses MAPI for access to additional properties not offered via IMAP but for your purposes either would work.  Exchange does have the concept of a super user account (an account with rights to the mailstore) - There are numerous articles and samples on the web talking about how to get information from Exchange mailstores - the vw_Subscriber view noted above includes the SMTP address and DirctoryID (GUID pointing to the user's AD record) - everything you need for mailbox identification.
    Short version is you wont get things like message count (read/unread/deleted/total size etc...) from the Unity database in SQL - we don't keep that kind of information around.  All that's kept in SQL is that the user has at least one unread voice mail message or not (their MWI is on or off accordingly - a flag is kept for this in the DB) - but for more detailed mailbox info you'll have to go directly to the store.
    -J

  • Accessing application server

    Hi all
    I want to access the Application Server(10g)(9.0.4) from the client machine.To access the server i entered URL.But,there is no error and no application out put.Can you suggest me what the reason is?
    URL is http://system16:8891/forms90/f90servlet)
    Thanks
    Reddy

    Reddy,
    you see at least something. What about a blank screen? Or do you see the client trying to access the server without response, in which case you could have a proxy problem.
    Frank

  • Cannot send messages since updating to Thunderbird V 31.3.0. The message could not be sent using SMTP server for an unknown reason. Help?!?

    Mail provider - Network Solutions
    ISP - Comcast
    Anti-Virus - Kaspersky Internet Security 2013
    OS - Windows 7 Home Premium, Service Pack 1
    Outgoing Server SMTP settings attached.
    I can receive messages and can send them directly from Network Solutions just unable to send now from Thunderbird. Was working fine until the newest version installed. Haven't changed any settings...

    That anti virus? is it Nortons security suite? I think that is what comcast give their xfinity customers but I am not sure what everyone else gets.
    Assuming is is the Norton's product go into the firewall component and explicitly allow Thunderbird unrestricted access to the internet. Norton's product have a long history of blocking new releases of mail programs because the version number changed.
    Go onto the SMTP setting you have in the image and make sure each has a description entered.
    Now check in the account settings by clicking the account name in the list so you select the item about Server settings for each account and make sure the selected SMTP server is what you think it is. Now there is a description that will show in the list.

  • The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.5.1 Authentication Required.

     try
                    MailMessage mail = new MailMessage();
                    SmtpClient SmtpServer = new SmtpClient("smtp.gmail.com");
                    mail.From = new MailAddress("[email protected]");
                    mail.To.Add("[email protected]");
                    mail.Subject = "Test Mail..!!!!";
                    mail.Body = "mail with attachment";
                    System.Net.Mail.Attachment attachment;
                    attachment = new System.Net.Mail.Attachment(@"C:\Attachment.txt");
                    mail.Attachments.Add(attachment);
                    SmtpServer.Port = 587;
                    SmtpServer.UseDefaultCredentials = true;
                    SmtpServer.Credentials = new System.Net.NetworkCredential("userid", "Password");
                    SmtpServer.EnableSsl = true;
                    SmtpServer.Send(mail);
    Catch(Exception exception)
    When i m run this part of code it throw an Ecxeption                                                          
            Given Below is the Error.. 
        The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.5.1 Authentication Required.
    Bikky Kumar

     try
                    MailMessage mail = new MailMessage();
                    SmtpClient SmtpServer = new SmtpClient("smtp.gmail.com");
                    mail.From = new MailAddress("[email protected]");
                    mail.To.Add("[email protected]");
                    mail.Subject = "Test Mail..!!!!";
                    mail.Body = "mail with attachment";
                    System.Net.Mail.Attachment attachment;
                    attachment = new System.Net.Mail.Attachment(@"C:\Attachment.txt");
                    mail.Attachments.Add(attachment);
                    SmtpServer.Port = 587;
    SmtpServer.UseDefaultCredentials = true;    ///Set it to false, or remove this line
                    SmtpServer.Credentials = new System.Net.NetworkCredential("userid", "Password");
                    SmtpServer.EnableSsl = true;
                    SmtpServer.Send(mail);
    Catch(Exception exception)
    Given Below is the Error..      The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.5.1 Authentication Required.
    Solution:
    The error might occur due to following cases.
    case 1: when the password is wrong
    case 2: when you try to login from some App
    case 3: when you try to login from the domain other than your time zone/domain/computer (This
    is the case in most of scenarios when sending mail from code)
    There is a solution for each
    solution for case 1: Enter the correct password.
    Recomended: solution for case 2: go to
    security settings at the following link https://www.google.com/settings/security/lesssecureapps and
    enable less secure apps . So that you will be able to login from all apps.
    solution 1 for case 3: (This might be helpful) you need to review the activity. but reviewing the activity will not be helpful due to latest security
    standards the link will not be useful. So try the below case.
    solution 2 for case 3: If you have hosted your code somewhere on production server and if you have access to the production server, than take remote
    desktop connection to the production server and try to login once from the browser of the production server. This will add exception for login to google and you will be allowed to login from code.
    But what if you don't have access to the production server. try
    the solution 3
    solution 3 for case 3: You have to enable
    login from other timezone / ip for your google account.
    to do this follow the link https://g.co/allowaccess and
    allow access by clicking the continue button.
    And that's it. Here you go. Now you will be able to login from any of the computer and by any means of app to your google account.
    Regards,
    Nabeel Arif

  • SMTP server error message

    My scan to email feature has suddenly quit working.  When I try to scan a document, the scan feature trys to connect to smtp.aol.com, as it always has.  After approximately 5 seconds, I receive the following error message:  "Cannot resolve the SMTP server".  I tried correcting by following an earlier post dated 3-1-2014, by accessing the printer's Embedded Web Server and performing the below tasks:
    Click the Network tab, then click on IP4 config on the left side.   
    Click on Network Address (IP)
    Select Manual.
    Type in the printer's information and IP address.
    Set the DNS Address Configuration as Manual.
    This did not work for me.  As stated before, this feature has worked flawlessly for the past year.  Not sure what happened.
    Any help would be appreciated.
    Thanks, Brian

    Hi brianw8602,
    I believe this should be most of the settings you need.
    AOL Mail SMTP server address: smtp.aol.com
    AOL Mail SMTP user name: Your AOL Mail screen name (what comes before "@aol.com" in your AOL Mail address; if your address is [email protected], for example, the corresponding screen name is "me")
    AOL Mail SMTP password: Your AOL Mail password
    AOL Mail SMTP port: 587 (alternative: 465)
    AOL Mail SMTP TLS/SSL required: yes
    Delete the Scan to Email settings and run the Setup Wizard again.
    You might need to contact AOL to lower the security settings, since it was working and now it isn't.
    Hope this helps.
    Thank You.
    Please click “Accept as Solution ” if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos Thumbs Up" on the right to say “Thanks” for helping!
    Gemini02
    I work on behalf of HP

  • SMTP Server setup / XS855 error message

    Hi Experts,
    I try to send E-mail messages to external recipients, but getting following error message:
    SMTP server setup:
    Host: 192.168.3.3
    Port: 25
    Any suggestions?
    Thank you, Denis.

    Hi Harshal,
    Thanks for the quick response.
    When I try to ping from my SAP system server to SMTP server host it is connecting and services are running fine.
    Even though, I should request mail admin people to register my SAP system server hostname and IP address into SMTP mail host server's host entry ??
    Thanks again.
    Venkata Madhan

  • Understanding smtp server response

    Hi,
    I like to check with anyone who might be able to advise me on the problem below.
    I have a servlet which uses JavaMail to send out emails to a smtp server. During our peak access hours, we have many requests to send out emails, after a while my application went into CLOSE WAIT accumulation and finally my application server stops processing.
    When i did a thread dump, i found quite a number of threads still occupied with the process below. Does it mean that this is a symptom of network bottleneck where the smtp server is not responding as fast to the client and hence holding up the rest of the threads ? Is JavaMail send() method a synchronous call that has to wait for a server response before the thread is released ? Or is this a case of my network problem ?
    "ExecuteThread: '11' for queue: 'default'" daemon prio=5 tid=0x39fb28 nid=0x18 runnable [0xbf980000..0xbf981a38]
    at java.net.SocketInputStream.socketRead(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:85)
    at java.io.BufferedInputStream.fill(BufferedInputStream.java:181)
    at java.io.BufferedInputStream.read(BufferedInputStream.java:199)
    at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:56)
    at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:929)
    at com.sun.mail.smtp.SMTPTransport.issueCommand(SMTPTransport.java:878)
    at com.sun.mail.smtp.SMTPTransport.finishData(SMTPTransport.java:820)
    at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:322)
    at javax.mail.Transport.send0(Transport.java:164)
    at javax.mail.Transport.send(Transport.java:81)

    Thank you very much for the advise. It has helped me a lot.
    Do you mind if i ask a few more questions on smtp ?
    I do not know why i keep getting the error below when trying to send email to external email addresses like yahoo.com ?
    nested exception is:
         javax.mail.SendFailedException: Invalid Addresses;
    nested exception is:
         javax.mail.SendFailedException: 550 Relaying is prohibited
    I checked the firewall setting and it has already been granted for my server to reach the smtp server via port 25 when i check using telnet command. Do you have any idea what else i need to do ?
    Thanks

  • Exchange messages departing via SMTP server from prior account

    We've just deployed Exchange 2010 in our organization, replacing a hosted POP/IMAP/SMTP solution. The hosted solution remains available so that IMAP users are able to access their pre-Exchange messages. Consequently, iOS4 users have both an Exchange account and either a POP or IMAP account with a corresponding SMTP server.
    The problem we're encountering involves which mail server is used when replying to messages with iOS4 devices. The president of our company has an iPhone 4 and an iPad 2: any message he replies to goes out via the SMTP server in use with our old solution.
    So if I send him a message which arrives in his Exchange mailbox, if he replies to me with either of those devices, the reply ends up in my POP/IMAP mailbox on the previous mail server. This is a problem as people are not monitoring their old account inboxes now that the bulk of mail is received via Exchange, and this has resulted in a number of important messages missed or ignored.
    I have been able to reproduce this.
    Once again in a nutshell:
    I send a message is to president. Arrives in his Exchange inbox. He replies via iPad or iPhone. Message arrives in old POP/IMAP inbox.
    I can verify this behavior via message headers.
    As a workaround, we've attempted to reconfigure the SMTP settings associated with the old account to use the SMTP service on the Exchange server. This works fine inside our firewall, but remote performance has been very inconsistent . And we really would like to block SMTP at the firewall.
    I believe this issue has been discussed before, but in my review of the pertinent discussions, it doesn't look like there has been a solution.
    Has anyone found a solution for this problem?

    users will remain on the domain.  decommissioning or altering access to the old mailboxes until some point post-migration would be unwanted so there's a fallback method in case anything goes wrong.  until testing reveals a better method, the strategy
    for Exchange 2003 / Server 2003 environment will remain as is for now using ldifde export of select user object attributes followed by ldifde import of select attributes to contact objects, followed by admodify.net / admodcmd updating of the necessary mail/exchange
    attributes via %’mailNickName’% similar to what's described below to forward internal mail to the external host.
    Using ADModify to Change Exchange Specific AD User Attributes in Bulk
    Using ADModify – A real world example

  • Hi, i am having trouble with my mac mail account, i cannot send or receive any emails because of the server connection problems. Message says it could not be connected to SMTP server. Thanks in advance for your help.

    Hi, i am having trouble with my mac mail account, i cannot send or receive any emails because of the server connection problems. Message says it could not be connected to SMTP server. Thanks in advance for your help.

    Hello Sue,
    I have an iPad 3, iPad Mini and iPhone 5S and they are all sluggish on capitalisation using shift keys. I hope that Apple will solve the problem because it is driving me crazy.
    I find using a Microsoft Surface and Windows 8 phone, which I also have, work as well as all the ios devices before the ios 7 upgrade.
    It has something to do with the length of time that you need to hold the shift key down. The shift key needs to be held longer than the letter key for the capitalisation to work. For some reason, this is a major change in the way we have learnt to touch type on computers. I am having to relearn how to type!
    Michael

  • How can i access gmail's smtp server using java mail api

    i m using java mail api to access gmails pop and smtp service to receive and send mail from ur gmail account. I m able to access gmails pop server using the ssl and port 995 , but i can not use its smtp server to which i m connecting using ssl on 465 port. It requires authentication code.
    if anybody can help me in this regard i m thnkful to him/her.
    thnks in advance.
    jogin desai

    Here's an example of using SSL + Authentication
    http://onesearch.sun.com/search/onesearch/index.jsp?qt=ssl+authentication&subCat=siteforumid%3Ajava43&site=dev&dftab=siteforumid%3Ajava43&chooseCat=javaall&col=developer-forums

  • How do i solve - cannot access web server - error message when creating a project in 4.5 with PHP

    How do i solve - cannot access web server - error message when creating a project in 4.5 with PHP

    Screenshot of how it looks when i try to show a ms access form inside a iframe:
    http://oi58.tinypic.com/2vj4ish.jpg

  • How do I set up a mail server and SMTP server to send messages to other mail servers at mavericks

    How do I set up a mail server and SMTP server to send messages to other mail servers at mavericks

    You need to get the settings for your email from your email provider and enter them in Internet Accounts (System Preferences). Many of the common systems are already available, all you need is a password and an email address to set them up.

  • Can Mail access the sent messages on my POP3 server (webmail)?

    Hi there,
    I recently got a blackberry, mainly for the email etc. It's all great, but I have stumbled on an issue that I can't figure out:
    When I send an email from it, it somehow gets a copy of the sent email into the sent items on my webmail server. But how can I get a copy of my sent messages into my Mac Mail?
    In the Mail preferences, I see that there are settings regarding the inbox, but nothing that I have found lets me import messages that I have sent via webmail - or that are in my different webmail "sent items" folders.
    Any ideas?
    Thanks!!

    Blackberry/RIM has their own proprietary email service, so assuming you could access your sent messages, you would need to find out from them how you would do it. Normally, POP mail is not stored on servers, that is when you receive mail it's immediately downloaded to your computer unless you set a flag in your email application to save a copy on the server. Sent mail doesn't originate from your email server, so it's all stored locally. I would presume storing sent mail on a Blackberry wouldn't make a great deal of sense because it would eat a lot of memory space of which there's not a great deal on a cell phone.
    Perhaps RIM's mail is IMAP rather than POP where everything is on the server.

Maybe you are looking for