C# E-mail Client Mails Not Received

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • cnixuser
    New Member
    • Dec 2006
    • 80

    #16
    Originally posted by Plater
    And I we all keep telling you that you need to use credentials.
    There really shouldn't be anything difficult to grasp on this concept.
    Have you even tried to use valid credentials?
    I tried using credentials from my gmail account yes "username" and "password", and when that didn't work, I tried "username@gmail .com", and "password".

    Comment

    • Plater
      Recognized Expert Expert
      • Apr 2007
      • 7872

      #17
      Ok now I don't know what you were doing.
      You would not be able to send ANY email through gmail's mail servers without authenticating and using SSL, so you are probably using your company's mail server to send the mail. You must provide a valid login for THAT server in order to send emails successfully.

      Comment

      • cnixuser
        New Member
        • Dec 2006
        • 80

        #18
        Originally posted by Plater
        Ok now I don't know what you were doing.
        You would not be able to send ANY email through gmail's mail servers without authenticating and using SSL, so you are probably using your company's mail server to send the mail. You must provide a valid login for THAT server in order to send emails successfully.
        Well, I'm actually sending from the pc that I am running the application from. I set the SmtpClient as the local host (127.0.0.1). The pc is on a network independent from the one at work (a Verizon cellular modem). I do honestly have a misunderstandin g of how to use credentials. With my new description, do you believe still that I need the credentials for the server at my company which I would be sending to and not from?

        Comment

        • cnixuser
          New Member
          • Dec 2006
          • 80

          #19
          Originally posted by cnixuser
          Well, I'm actually sending from the pc that I am running the application from. I set the SmtpClient as the local host (127.0.0.1). The pc is on a network independent from the one at work (a Verizon cellular modem). I do honestly have a misunderstandin g of how to use credentials. With my new description, do you believe still that I need the credentials for the server at my company which I would be sending to and not from?
          It occurs to me that if I had my SmtpClient as the localhost, I would have to alter some settings for my IIS virtual SMTP server, so that it was configured for authentication rather than anonymous access, and then in my code, add the credentials to my localhost's IIS virtual SMTP server. Plater, is this what you were trying to tell me to have authenticated? If so, I apologize for being too dense :)
          Last edited by cnixuser; Aug 12 '08, 07:04 PM. Reason: minus 1 t

          Comment

          • Plater
            Recognized Expert Expert
            • Apr 2007
            • 7872

            #20
            Hmmm no. It had actually not occured to me that you could be using localhost to send the emails. Will the final product be run in the same manor?

            The crenedtials supplied are for the server you are sending mail from. so if you are sending mail from a localhost, I now understand your confusion about what credentials to send.
            That being said there are a number of other things in the SMTP protocol that could cause your emails to be rejected. It's possible that godaddy implents the part of the protocol that says there needs to be a valid MX record for the address that is SENDING the messages.
            i.e. it needs to be able to go -> somename@somedo main.com....che cking the lookup for somedomain.com
            They may also go the next step which would be reverse validation and attempt to verify that someuser is a valid username in somedomain.com

            and it could also be none of those and something else entirely.
            Your best bet might be to get in touch with whoever handles your email and see if they can find anything in the logs about why your messages are rejected

            Comment

            • cnixuser
              New Member
              • Dec 2006
              • 80

              #21
              Originally posted by Plater
              Hmmm no. It had actually not occured to me that you could be using localhost to send the emails. Will the final product be run in the same manor?

              The crenedtials supplied are for the server you are sending mail from. so if you are sending mail from a localhost, I now understand your confusion about what credentials to send.
              That being said there are a number of other things in the SMTP protocol that could cause your emails to be rejected. It's possible that godaddy implents the part of the protocol that says there needs to be a valid MX record for the address that is SENDING the messages.
              i.e. it needs to be able to go -> somename@somedo main.com....che cking the lookup for somedomain.com
              They may also go the next step which would be reverse validation and attempt to verify that someuser is a valid username in somedomain.com

              and it could also be none of those and something else entirely.
              Your best bet might be to get in touch with whoever handles your email and see if they can find anything in the logs about why your messages are rejected
              client.UseDefau ltCredentials = true;
              would send my local host's Credentials correct?

              Comment

              • Plater
                Recognized Expert Expert
                • Apr 2007
                • 7872

                #22
                Originally posted by cnixuser
                client.UseDefau ltCredentials = true;
                would send my local host's Credentials correct?
                Mmm I think it actually looks in either machine.config or web.config (depending on application type) for them. Unsure what it will send if cannot find them.

                Comment

                • cnixuser
                  New Member
                  • Dec 2006
                  • 80

                  #23
                  Originally posted by Plater
                  Mmm I think it actually looks in either machine.config or web.config (depending on application type) for them. Unsure what it will send if cannot find them.
                  I have another question related to this ;however, at this point should I just go ahead and start a new thread?

                  Comment

                  • Curtis Rutland
                    Recognized Expert Specialist
                    • Apr 2008
                    • 3264

                    #24
                    If it isn't directly related, yes.

                    Go ahead and post it. We can merge/split it if we need to.

                    Comment

                    • joedeene
                      Contributor
                      • Jul 2008
                      • 579

                      #25
                      Originally posted by Plater
                      Well technically no, because I built my own SMTPClient as I disliked the built in one.
                      But yes, I *DO* send the authentication information to the mail server, my mail server won't send emails out unless you are a valid user.

                      hey plater, you said you built your own smtpclient class, that has to be awesome, how would you come across doing that? did you implement any of it with the webclient class? just curious

                      Comment

                      • Plater
                        Recognized Expert Expert
                        • Apr 2007
                        • 7872

                        #26
                        I did it with Sockets and the RFCs for the SMTP specs

                        Comment

                        • joedeene
                          Contributor
                          • Jul 2008
                          • 579

                          #27
                          Originally posted by Plater
                          I did it with Sockets and the RFCs for the SMTP specs
                          what are 'RFCs'? i typed it in google with .net nothing relevant came up

                          Comment

                          • Plater
                            Recognized Expert Expert
                            • Apr 2007
                            • 7872

                            #28
                            RFCs are Request For Comments. They are used to define internet standards. They are not related to .NET

                            Comment

                            Working...