Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. smtp server authentication

smtp server authentication

Scheduled Pinned Locked Moved C / C++ / MFC
c++sysadmincloudsecuritytutorial
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    neha agarwal27
    wrote on last edited by
    #1

    i m sending a mail using SMTP... But i want to authenticate my smtp server can anybody just tell me how to use AUTH LOGIN command in vc++ i m sending HELO Command like this..... TCHAR local_host[ 80 ]; gethostname( local_host, 80 ); sHello.Format( "HELO %s\r\n", local_host ); m_wsSMTPServer.Send( (LPCTSTR)sHello, sHello.GetLength() ); if( !get_response( GENERIC_SUCCESS ) ) { m_wsSMTPServer.Close(); return FALSE; } after these lines of code i want to authenticate my server do we paas username n password with AUTH LOGIN command only Can somebody send me the line of code aur just explain me the method of doing so thanxs in advance...

    M 1 Reply Last reply
    0
    • N neha agarwal27

      i m sending a mail using SMTP... But i want to authenticate my smtp server can anybody just tell me how to use AUTH LOGIN command in vc++ i m sending HELO Command like this..... TCHAR local_host[ 80 ]; gethostname( local_host, 80 ); sHello.Format( "HELO %s\r\n", local_host ); m_wsSMTPServer.Send( (LPCTSTR)sHello, sHello.GetLength() ); if( !get_response( GENERIC_SUCCESS ) ) { m_wsSMTPServer.Close(); return FALSE; } after these lines of code i want to authenticate my server do we paas username n password with AUTH LOGIN command only Can somebody send me the line of code aur just explain me the method of doing so thanxs in advance...

      M Offline
      M Offline
      Mila025
      wrote on last edited by
      #2

      Hi, If I remember well when you trying to connect with authenticated server you should use EHLO keyword instead HELO. Perhaps this helps you: rfc2554[^]

      ----------- Mila

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups