home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 1998 May / Pcwk5b98.iso / WEBSERVE / SAMBAR / DATA.1 / login.h < prev    next >
C/C++ Source or Header  |  1997-08-19  |  3KB  |  90 lines

  1. /*
  2. ** LOGIN.H
  3. **
  4. **      This header file contains the public HTTP interfaces used by the
  5. **        Sambar Server for interfacing with User Login/Logout/Profile
  6. **        Management.
  7. **
  8. **        Confidential Property of Tod Sambar
  9. **        (c) Copyright Tod Sambar 1996-1997
  10. **        All rights reserved.
  11. **
  12. **
  13. ** History:
  14. ** Chg#    Date    Description                                                Resp
  15. ** ----    -------    -------------------------------------------------------    ----
  16. **        27JAN97    Created                                                    sambar
  17. **        25MAR97    Added FTP support                                        sambar
  18. */
  19.  
  20. #if     !defined(__LOGIN_H__)
  21. #define __LOGIN_H__
  22.  
  23. #include    <sambar.h>
  24.  
  25. /*
  26. ** Login/Logout/Profile Management Defines
  27. */
  28. #define LOGIN_PROFILE_KEY        "Profile"
  29.  
  30. /*
  31. ** User Profile Structure
  32. */
  33. typedef struct    login__profile
  34. {
  35.     SA_CHAR        name[SA_MAX_NAME + 1];
  36.     SA_CHAR        group[SA_MAX_NAME + 1];
  37.     SA_CHAR        username[SA_MAX_NAME + 1];
  38.  
  39. } LOGIN_PROFILE;
  40.  
  41.  
  42. /*
  43. ** Sambar Server/User Login/Logout/Profile DLL Function Prototypes
  44. */
  45. #if defined(__cplusplus)
  46. extern "C" {
  47. #endif /* defined(__cplusplus) */
  48.  
  49. extern SA_RETCODE SA_EXPORT        login_init(SA_CTX *sactx);
  50.  
  51. extern SA_RETCODE SA_EXPORT        user_login(SA_CTX *sactx, SA_CONN *saconn,
  52.                                     SA_CHAR *username, SA_INT usernamelen,
  53.                                     SA_CHAR *password, SA_INT passwordlen,
  54.                                     SA_INT *infop);
  55.  
  56. extern SA_RETCODE SA_EXPORT        user_logout(SA_CTX *sactx, SA_CONN *saconn);
  57.  
  58. extern SA_RETCODE SA_EXPORT        user_profile(SA_CTX *sactx, SA_CONN *saconn,
  59.                                     SA_CHAR *buffer, SA_INT buflen,
  60.                                     SA_CHAR *data);
  61.  
  62. /*
  63. ** User Management
  64. */
  65. extern SA_RETCODE SA_PUBLIC        user_add(SA_CTX *sactx, SA_CONN *saconn,
  66.                                     SA_PARAMS *saparams, SA_INT *infop);
  67. extern SA_RETCODE SA_PUBLIC        user_delete(SA_CTX *sactx, SA_CONN *saconn,
  68.                                     SA_PARAMS *saparams, SA_INT *infop);
  69. extern SA_RETCODE SA_PUBLIC        user_update(SA_CTX *sactx, SA_CONN *saconn,
  70.                                     SA_PARAMS *saparams, SA_INT *infop);
  71. extern SA_RETCODE SA_PUBLIC        user_list(SA_CTX *sactx, SA_CONN *saconn,
  72.                                     SA_PARAMS *saparams, SA_INT *infop);
  73. extern SA_RETCODE SA_PUBLIC        user_select(SA_CTX *sactx, SA_CONN *saconn,
  74.                                     SA_PARAMS *saparams, SA_INT *infop);
  75. extern SA_RETCODE SA_PUBLIC        user_prop(SA_CTX *sactx, SA_CONN *saconn,
  76.                                     SA_PARAMS *saparams, SA_INT *infop);
  77.  
  78. /*
  79. ** FTP Connect
  80. */
  81. extern SA_RETCODE SA_EXPORT        ftp_connect(SA_CTX *sactx, SA_CHAR *user,
  82.                                     SA_INT userlen, SA_CHAR *passwd, 
  83.                                     SA_INT passwdlen, SA_FTP *ftp);
  84.  
  85. #if defined(__cplusplus)
  86. }
  87. #endif /* defined(__cplusplus) */
  88.  
  89. #endif /* __LOGIN_H__ */
  90.