| ne_auth.h | | ne_auth.h | |
| | | | |
| skipping to change at line 85 | | skipping to change at line 85 | |
| | | | |
| /* NE_AUTH_NEGOTIATE: Negotiate uses GSSAPI/SSPI, or NTLM, to | | /* NE_AUTH_NEGOTIATE: Negotiate uses GSSAPI/SSPI, or NTLM, to | |
| * authenticate the user; an active attacker can modify any of the | | * authenticate the user; an active attacker can modify any of the | |
| * request/response at will, so this must not be used over an | | * request/response at will, so this must not be used over an | |
| * unsecured channel. NE_AUTH_NEGOTIATE is currently equivalent to | | * unsecured channel. NE_AUTH_NEGOTIATE is currently equivalent to | |
| * use of (NE_AUTH_GSSAPI | NE_AUTH_NTLM). */ | | * use of (NE_AUTH_GSSAPI | NE_AUTH_NTLM). */ | |
| #define NE_AUTH_NEGOTIATE (0x0004) | | #define NE_AUTH_NEGOTIATE (0x0004) | |
| | | | |
| /* NE_AUTH_GSSAPI: Use GSSAPI or SSPI to authenticate the user; an | | /* NE_AUTH_GSSAPI: Use GSSAPI or SSPI to authenticate the user; an | |
| * active attacker can modify any of the request/response at will, so | | * active attacker can modify any of the request/response at will, so | |
|
| * this must not be used over an unsecured channel. */ | | * this must not be used over an unsecured channel. NE_AUTH_GSSAPI | |
| | | * is currently equivalent to (NE_AUTH_GSSAPI_ONLY | NE_AUTH_SSPI). */ | |
| #define NE_AUTH_GSSAPI (0x0008) | | #define NE_AUTH_GSSAPI (0x0008) | |
| | | | |
| /* NE_AUTH_NTLM: Use NTLM to authenticate the user; an active attacker | | /* NE_AUTH_NTLM: Use NTLM to authenticate the user; an active attacker | |
| * can modify any of the request/response at will, so this must not be | | * can modify any of the request/response at will, so this must not be | |
| * used over an unsecured channel. */ | | * used over an unsecured channel. */ | |
| #define NE_AUTH_NTLM (0x0010) | | #define NE_AUTH_NTLM (0x0010) | |
| | | | |
|
| | | /* NE_AUTH_SSPI: Use SSPI to authenticate the user; an | |
| | | * active attacker can modify any of the request/response at will, so | |
| | | * this must not be used over an unsecured channel. */ | |
| | | #define NE_AUTH_SSPI (0x0020) | |
| | | | |
| | | /* NE_AUTH_GSSAPI_ONLY: Use GSSAPI to authenticate the user; an | |
| | | * active attacker can modify any of the request/response at will, so | |
| | | * this must not be used over an unsecured channel. */ | |
| | | #define NE_AUTH_GSSAPI_ONLY (0x0040) | |
| | | | |
| /* The default set of supported protocols, as deemed appropriate for | | /* The default set of supported protocols, as deemed appropriate for | |
| * the given session scheme. */ | | * the given session scheme. */ | |
| #define NE_AUTH_DEFAULT (0x1000) | | #define NE_AUTH_DEFAULT (0x1000) | |
| | | | |
| /* All protocols supported by the library. */ | | /* All protocols supported by the library. */ | |
| #define NE_AUTH_ALL (0x2000) | | #define NE_AUTH_ALL (0x2000) | |
| | | | |
| /* Add a callback to provide credentials for server and proxy | | /* Add a callback to provide credentials for server and proxy | |
| * authentication using a particular auth protocol or set of | | * authentication using a particular auth protocol or set of | |
| * protocols. The protocol is supplied as a bitmask of NE_AUTH_* | | * protocols. The protocol is supplied as a bitmask of NE_AUTH_* | |
| | | | |
End of changes. 2 change blocks. |
| 1 lines changed or deleted | | 12 lines changed or added | |
|
| ne_basic.h | | ne_basic.h | |
| | | | |
| skipping to change at line 99 | | skipping to change at line 99 | |
| int ne_get_content_type(ne_request *req, ne_content_type *ctype); | | int ne_get_content_type(ne_request *req, ne_content_type *ctype); | |
| | | | |
| /* DEPRECATED: Server capabilities. */ | | /* DEPRECATED: Server capabilities. */ | |
| typedef struct { | | typedef struct { | |
| unsigned int dav_class1; /* True if Class 1 WebDAV server */ | | unsigned int dav_class1; /* True if Class 1 WebDAV server */ | |
| unsigned int dav_class2; /* True if Class 2 WebDAV server */ | | unsigned int dav_class2; /* True if Class 2 WebDAV server */ | |
| unsigned int dav_executable; /* True if supports the 'executable' | | unsigned int dav_executable; /* True if supports the 'executable' | |
| * property a. la. mod_dav */ | | * property a. la. mod_dav */ | |
| } ne_server_capabilities; | | } ne_server_capabilities; | |
| | | | |
|
| /* DEPRECATED: Determines server capabilities (using OPTIONS). */ | | /* DEPRECATED: Determines server capabilities (using OPTIONS). Use | |
| | | * ne_options2() instead. */ | |
| int ne_options(ne_session *sess, const char *path, | | int ne_options(ne_session *sess, const char *path, | |
| ne_server_capabilities *caps); | | ne_server_capabilities *caps); | |
| | | | |
| #define NE_CAP_DAV_CLASS1 (0x0001) /* Class 1 WebDAV (RFC 2518) */ | | #define NE_CAP_DAV_CLASS1 (0x0001) /* Class 1 WebDAV (RFC 2518) */ | |
| #define NE_CAP_DAV_CLASS2 (0x0002) /* Class 2 WebDAV (RFC 2518) */ | | #define NE_CAP_DAV_CLASS2 (0x0002) /* Class 2 WebDAV (RFC 2518) */ | |
| #define NE_CAP_DAV_CLASS3 (0x0004) /* Class 3 WebDAV (RFC 4918) */ | | #define NE_CAP_DAV_CLASS3 (0x0004) /* Class 3 WebDAV (RFC 4918) */ | |
| #define NE_CAP_MODDAV_EXEC (0x0008) /* mod_dav "executable" property */ | | #define NE_CAP_MODDAV_EXEC (0x0008) /* mod_dav "executable" property */ | |
| #define NE_CAP_DAV_ACL (0x0010) /* WebDAV ACL (RFC 3744) */ | | #define NE_CAP_DAV_ACL (0x0010) /* WebDAV ACL (RFC 3744) */ | |
| #define NE_CAP_VER_CONTROL (0x0020) /* DeltaV version-control */ | | #define NE_CAP_VER_CONTROL (0x0020) /* DeltaV version-control */ | |
| #define NE_CAP_CO_IN_PLACE (0x0040) /* DeltaV checkout-in-place */ | | #define NE_CAP_CO_IN_PLACE (0x0040) /* DeltaV checkout-in-place */ | |
| #define NE_CAP_VER_HISTORY (0x0080) /* DeltaV version-history */ | | #define NE_CAP_VER_HISTORY (0x0080) /* DeltaV version-history */ | |
| #define NE_CAP_WORKSPACE (0x0100) /* DeltaV workspace */ | | #define NE_CAP_WORKSPACE (0x0100) /* DeltaV workspace */ | |
| #define NE_CAP_UPDATE (0x0200) /* DeltaV update */ | | #define NE_CAP_UPDATE (0x0200) /* DeltaV update */ | |
| #define NE_CAP_LABEL (0x0400) /* DeltaV label */ | | #define NE_CAP_LABEL (0x0400) /* DeltaV label */ | |
| #define NE_CAP_WORK_RESOURCE (0x0800) /* DeltaV working-resouce */ | | #define NE_CAP_WORK_RESOURCE (0x0800) /* DeltaV working-resouce */ | |
| #define NE_CAP_MERGE (0x1000) /* DeltaV merge */ | | #define NE_CAP_MERGE (0x1000) /* DeltaV merge */ | |
| #define NE_CAP_BASELINE (0x2000) /* DeltaV baseline */ | | #define NE_CAP_BASELINE (0x2000) /* DeltaV baseline */ | |
| #define NE_CAP_ACTIVITY (0x4000) /* DeltaV activity */ | | #define NE_CAP_ACTIVITY (0x4000) /* DeltaV activity */ | |
| #define NE_CAP_VC_COLLECTION (0x8000) /* DeltaV version-controlled-collecti
on */ | | #define NE_CAP_VC_COLLECTION (0x8000) /* DeltaV version-controlled-collecti
on */ | |
|
| | | #define NE_CAP_EXT_MKCOL (0x10000) /* extended-mkcol (RFC 5689) */ | |
| | | | |
| /* Determines resource capailities, using an OPTIONS request. On | | /* Determines resource capailities, using an OPTIONS request. On | |
| * return, *caps is set to a bit-mask of the above NE_CAP_* constants | | * return, *caps is set to a bit-mask of the above NE_CAP_* constants | |
| * describing the advertised resource capabilities. */ | | * describing the advertised resource capabilities. */ | |
| int ne_options2(ne_session *sess, const char *path, unsigned int *caps); | | int ne_options2(ne_session *sess, const char *path, unsigned int *caps); | |
| | | | |
| /* Defines a range of bytes, starting at 'start' and ending | | /* Defines a range of bytes, starting at 'start' and ending | |
| * at 'end'. 'total' is the number of bytes in the range. | | * at 'end'. 'total' is the number of bytes in the range. | |
| */ | | */ | |
| typedef struct { | | typedef struct { | |
| | | | |
End of changes. 2 change blocks. |
| 1 lines changed or deleted | | 3 lines changed or added | |
|
| ne_request.h | | ne_request.h | |
| | | | |
| skipping to change at line 81 | | skipping to change at line 81 | |
| * For a call with buflen > 0, the callback must return: | | * For a call with buflen > 0, the callback must return: | |
| * <0 : error, abort request; session error string must be
set. | | * <0 : error, abort request; session error string must be
set. | |
| * 0 : ignore 'buffer' contents, end of body. | | * 0 : ignore 'buffer' contents, end of body. | |
| * 0 < x <= buflen : buffer contains x bytes of body data. */ | | * 0 < x <= buflen : buffer contains x bytes of body data. */ | |
| typedef ssize_t (*ne_provide_body)(void *userdata, | | typedef ssize_t (*ne_provide_body)(void *userdata, | |
| char *buffer, size_t buflen); | | char *buffer, size_t buflen); | |
| | | | |
| /* Install a callback which is invoked as needed to provide the | | /* Install a callback which is invoked as needed to provide the | |
| * request body, a block at a time. The total size of the request | | * request body, a block at a time. The total size of the request | |
| * body is 'length'; the callback must ensure that it returns no more | | * body is 'length'; the callback must ensure that it returns no more | |
|
| * than 'length' bytes in total. */ | | * than 'length' bytes in total. If 'length' is set to -1, then the | |
| | | * total size of the request is unknown by the caller and chunked | |
| | | * tranfer will be used. */ | |
| void ne_set_request_body_provider(ne_request *req, ne_off_t length, | | void ne_set_request_body_provider(ne_request *req, ne_off_t length, | |
|
| ne_provide_body provider, void *userdata); | | ne_provide_body provider, void *userdata)
; | |
| | | | |
| /* Handling response bodies; two callbacks must be provided: | | /* Handling response bodies; two callbacks must be provided: | |
| * | | * | |
| * 1) 'acceptance' callback: determines whether you want to handle the | | * 1) 'acceptance' callback: determines whether you want to handle the | |
| * response body given the response-status information, e.g., if you | | * response body given the response-status information, e.g., if you | |
| * only want 2xx responses, say so here. | | * only want 2xx responses, say so here. | |
| * | | * | |
| * 2) 'reader' callback: passed blocks of the response-body as they | | * 2) 'reader' callback: passed blocks of the response-body as they | |
| * arrive, if the acceptance callback returned non-zero. */ | | * arrive, if the acceptance callback returned non-zero. */ | |
| | | | |
| | | | |
End of changes. 2 change blocks. |
| 2 lines changed or deleted | | 4 lines changed or added | |
|
| ne_session.h | | ne_session.h | |
| | | | |
| skipping to change at line 49 | | skipping to change at line 49 | |
| ne_session *ne_session_create(const char *scheme, | | ne_session *ne_session_create(const char *scheme, | |
| const char *hostname, unsigned int port); | | const char *hostname, unsigned int port); | |
| | | | |
| /* Finish an HTTP session */ | | /* Finish an HTTP session */ | |
| void ne_session_destroy(ne_session *sess); | | void ne_session_destroy(ne_session *sess); | |
| | | | |
| /* Prematurely force the connection to be closed for the given | | /* Prematurely force the connection to be closed for the given | |
| * session. */ | | * session. */ | |
| void ne_close_connection(ne_session *sess); | | void ne_close_connection(ne_session *sess); | |
| | | | |
|
| /* Set the proxy server to be used for the session. This function | | /* Configure an HTTP proxy server for the session. This function will | |
| * will override (remove) any proxy servers previously configured, and | | * override (remove) any proxy servers previously configured, and must | |
| * must be called before any requests are created using this | | * be called before any requests are created using this session. */ | |
| * session. */ | | | |
| void ne_session_proxy(ne_session *sess, | | void ne_session_proxy(ne_session *sess, | |
| const char *hostname, unsigned int port); | | const char *hostname, unsigned int port); | |
| | | | |
| /* Configure a SOCKS proxy server which will be used for the session. | | /* Configure a SOCKS proxy server which will be used for the session. | |
| * The SOCKS protocol version 'vers' will be used to contact the | | * The SOCKS protocol version 'vers' will be used to contact the | |
| * proxy at given 'hostname' and 'port'. | | * proxy at given 'hostname' and 'port'. | |
| * | | * | |
| * If SOCKSv4 or v4a are used, username must be non-NULL. For v5, | | * If SOCKSv4 or v4a are used, username must be non-NULL. For v5, | |
| * username may be NULL, in which case, password is ignored. If | | * username may be NULL, in which case, password is ignored. If | |
| * username is non-NULL, password must also be non-NULL. | | * username is non-NULL, password must also be non-NULL. | |
| | | | |
| skipping to change at line 122 | | skipping to change at line 121 | |
| int ne_get_session_flag(ne_session *sess, ne_session_flag flag); | | int ne_get_session_flag(ne_session *sess, ne_session_flag flag); | |
| | | | |
| /* Bypass the normal name resolution; force the use of specific set of | | /* Bypass the normal name resolution; force the use of specific set of | |
| * addresses for this session, addrs[0]...addrs[n-1]. The 'addrs' | | * addresses for this session, addrs[0]...addrs[n-1]. The 'addrs' | |
| * array and pointed-to objects must remain valid until the session is | | * array and pointed-to objects must remain valid until the session is | |
| * destroyed. This function will override (remove) any proxy servers | | * destroyed. This function will override (remove) any proxy servers | |
| * previously configured, and must be called before any requests are | | * previously configured, and must be called before any requests are | |
| * created using this session. */ | | * created using this session. */ | |
| void ne_set_addrlist(ne_session *sess, const ne_inet_addr **addrs, size_t n
); | | void ne_set_addrlist(ne_session *sess, const ne_inet_addr **addrs, size_t n
); | |
| | | | |
|
| | | /* Bypass the normal name resolution; force the use of specific set of | |
| | | * addresses for this session, addrs[0]...addrs[n-1]. The 'addrs' | |
| | | * array and pointed-to objects must remain valid until the session is | |
| | | * destroyed. This function will override (remove) any proxy servers | |
| | | * previously configured, and must be called before any requests are | |
| | | * created using this session. Port number 'port' will be used | |
| | | * instead of the "real" session port, to connect to the proxy. */ | |
| | | void ne_set_addrlist2(ne_session *sess, unsigned int port, | |
| | | const ne_inet_addr **addrs, size_t n); | |
| | | | |
| /* Bind connections to the specified local address. If the address | | /* Bind connections to the specified local address. If the address | |
| * determined for the remote host has a different family (type) to | | * determined for the remote host has a different family (type) to | |
| * 'addr', 'addr' will be ignored. The 'addr' object must remain | | * 'addr', 'addr' will be ignored. The 'addr' object must remain | |
| * valid until the session is destroyed. */ | | * valid until the session is destroyed. */ | |
| void ne_set_localaddr(ne_session *sess, const ne_inet_addr *addr); | | void ne_set_localaddr(ne_session *sess, const ne_inet_addr *addr); | |
| | | | |
| /* DEPRECATED: Progress callback. */ | | /* DEPRECATED: Progress callback. */ | |
| typedef void (*ne_progress)(void *userdata, ne_off_t progress, ne_off_t tot
al); | | typedef void (*ne_progress)(void *userdata, ne_off_t progress, ne_off_t tot
al); | |
| | | | |
| /* DEPRECATED API: Set a progress callback for the session; this is | | /* DEPRECATED API: Set a progress callback for the session; this is | |
| | | | |
End of changes. 2 change blocks. |
| 4 lines changed or deleted | | 13 lines changed or added | |
|
| ne_socket.h | | ne_socket.h | |
| | | | |
| skipping to change at line 65 | | skipping to change at line 65 | |
| | | | |
| /* Perform process-global initialization of any libraries in use. | | /* Perform process-global initialization of any libraries in use. | |
| * Returns non-zero on error. */ | | * Returns non-zero on error. */ | |
| int ne_sock_init(void); | | int ne_sock_init(void); | |
| | | | |
| /* Perform process-global shutdown of any libraries in use. This | | /* Perform process-global shutdown of any libraries in use. This | |
| * function only has effect when it has been called an equal number of | | * function only has effect when it has been called an equal number of | |
| * times to ne_sock_init() for the process. */ | | * times to ne_sock_init() for the process. */ | |
| void ne_sock_exit(void); | | void ne_sock_exit(void); | |
| | | | |
|
| /* Resolve the given hostname. 'flags' must be zero. Hex | | #define NE_ADDR_CANON (0x01) | |
| * string IPv6 addresses (e.g. `::1') may be enclosed in brackets | | /* Resolve the given hostname. Hex string IPv6 addresses (e.g. `::1') | |
| * (e.g. `[::1]'). */ | | * may be enclosed in brackets (e.g. `[::1]'). 'flags' should be | |
| | | * zero, or if NE_ADDR_CANON is passed, the canonical name for the | |
| | | * hostname will be determind. */ | |
| ne_sock_addr *ne_addr_resolve(const char *hostname, int flags); | | ne_sock_addr *ne_addr_resolve(const char *hostname, int flags); | |
| | | | |
| /* Returns zero if name resolution was successful, non-zero on | | /* Returns zero if name resolution was successful, non-zero on | |
| * error. */ | | * error. */ | |
| int ne_addr_result(const ne_sock_addr *addr); | | int ne_addr_result(const ne_sock_addr *addr); | |
| | | | |
| /* Returns the first network address associated with the 'addr' | | /* Returns the first network address associated with the 'addr' | |
| * object. Undefined behaviour if ne_addr_result returns non-zero for | | * object. Undefined behaviour if ne_addr_result returns non-zero for | |
| * 'addr'; otherwise, never returns NULL. */ | | * 'addr'; otherwise, never returns NULL. */ | |
| const ne_inet_addr *ne_addr_first(ne_sock_addr *addr); | | const ne_inet_addr *ne_addr_first(ne_sock_addr *addr); | |
| | | | |
| skipping to change at line 91 | | skipping to change at line 93 | |
| const ne_inet_addr *ne_addr_next(ne_sock_addr *addr); | | const ne_inet_addr *ne_addr_next(ne_sock_addr *addr); | |
| | | | |
| /* NB: the pointers returned by ne_addr_first and ne_addr_next are | | /* NB: the pointers returned by ne_addr_first and ne_addr_next are | |
| * valid until ne_addr_destroy is called for the corresponding | | * valid until ne_addr_destroy is called for the corresponding | |
| * ne_sock_addr object. They must not be passed to ne_iaddr_free. */ | | * ne_sock_addr object. They must not be passed to ne_iaddr_free. */ | |
| | | | |
| /* If name resolution fails, copies the error string into 'buffer', | | /* If name resolution fails, copies the error string into 'buffer', | |
| * which is of size 'bufsiz'. 'buffer' is returned. */ | | * which is of size 'bufsiz'. 'buffer' is returned. */ | |
| char *ne_addr_error(const ne_sock_addr *addr, char *buffer, size_t bufsiz); | | char *ne_addr_error(const ne_sock_addr *addr, char *buffer, size_t bufsiz); | |
| | | | |
|
| | | /* Returns the canonical name of the host as a NUL-terminated string, | |
| | | * if NE_ADDR_CANON was used, and name resolution was successful. | |
| | | * Otherwise, returns NULL. */ | |
| | | const char *ne_addr_canonical(const ne_sock_addr *addr); | |
| | | | |
| /* Destroys an address object created by ne_addr_resolve. */ | | /* Destroys an address object created by ne_addr_resolve. */ | |
| void ne_addr_destroy(ne_sock_addr *addr); | | void ne_addr_destroy(ne_sock_addr *addr); | |
| | | | |
| /* Network address type; IPv4 or IPv6 */ | | /* Network address type; IPv4 or IPv6 */ | |
| typedef enum { | | typedef enum { | |
| ne_iaddr_ipv4 = 0, | | ne_iaddr_ipv4 = 0, | |
| ne_iaddr_ipv6 | | ne_iaddr_ipv6 | |
| } ne_iaddr_type; | | } ne_iaddr_type; | |
| | | | |
| /* Create a network address object from raw byte representation (in | | /* Create a network address object from raw byte representation (in | |
| | | | |
End of changes. 2 change blocks. |
| 3 lines changed or deleted | | 10 lines changed or added | |
|
| ne_ssl.h | | ne_ssl.h | |
| | | | |
| skipping to change at line 124 | | skipping to change at line 124 | |
| const ne_ssl_certificate *c2); | | const ne_ssl_certificate *c2); | |
| | | | |
| /* Deallocate memory associated with certificate. */ | | /* Deallocate memory associated with certificate. */ | |
| void ne_ssl_cert_free(ne_ssl_certificate *cert); | | void ne_ssl_cert_free(ne_ssl_certificate *cert); | |
| | | | |
| /* A client certificate (and private key). A client certificate | | /* A client certificate (and private key). A client certificate | |
| * object has state; the object is either in the "encrypted" or | | * object has state; the object is either in the "encrypted" or | |
| * "decrypted" state. */ | | * "decrypted" state. */ | |
| typedef struct ne_ssl_client_cert_s ne_ssl_client_cert; | | typedef struct ne_ssl_client_cert_s ne_ssl_client_cert; | |
| | | | |
|
| /* Read a client certificate and private key from a PKCS12 file; | | /* Read a client certificate (and private key) in PKCS#12 format from | |
| * returns NULL if the file could not be parsed, or otherwise | | * file 'filename'; returns NULL if the file could not be parsed, or | |
| * returning a client certificate object. The returned object may be | | * otherwise returning a client certificate object. The returned | |
| * in either the encrypted or decrypted state. */ | | * object may be in either the encrypted or decrypted state. */ | |
| ne_ssl_client_cert *ne_ssl_clicert_read(const char *filename); | | ne_ssl_client_cert *ne_ssl_clicert_read(const char *filename); | |
| | | | |
|
| | | /* Read a client certificate (and private key) in PKCS#12 format from | |
| | | * 'buffer', of length 'buflen', returning NULL if the certificate | |
| | | * could not be parsed, or otherwise returning a client certificate | |
| | | * object. The returned object may be in either the encrypted or | |
| | | * decrypted state. */ | |
| | | ne_ssl_client_cert *ne_ssl_clicert_import(const unsigned char *buffer, | |
| | | size_t buflen); | |
| | | | |
| /* Returns non-zero if client cert is in the encrypted state. */ | | /* Returns non-zero if client cert is in the encrypted state. */ | |
| int ne_ssl_clicert_encrypted(const ne_ssl_client_cert *ccert); | | int ne_ssl_clicert_encrypted(const ne_ssl_client_cert *ccert); | |
| | | | |
| /* Returns the "friendly name" given for the client cert, or NULL if | | /* Returns the "friendly name" given for the client cert, or NULL if | |
| * none given. Returns a NUL-terminated, UTF-8-encoded string. This | | * none given. Returns a NUL-terminated, UTF-8-encoded string. This | |
| * function may be used on a ccert object in either encrypted or | | * function may be used on a ccert object in either encrypted or | |
| * decrypted state. */ | | * decrypted state. */ | |
| const char *ne_ssl_clicert_name(const ne_ssl_client_cert *ccert); | | const char *ne_ssl_clicert_name(const ne_ssl_client_cert *ccert); | |
| | | | |
| /* Decrypt the encrypted client cert using the given password. | | /* Decrypt the encrypted client cert using the given password. | |
| | | | |
| skipping to change at line 184 | | skipping to change at line 192 | |
| /* Server mode: set client cert verification options: required is non-zero
if | | /* Server mode: set client cert verification options: required is non-zero
if | |
| * a client cert is required, if ca_names is non-NULL it is a filename cont
aining | | * a client cert is required, if ca_names is non-NULL it is a filename cont
aining | |
| * a set of PEM certs from which CA names are sent in the ccert request. */ | | * a set of PEM certs from which CA names are sent in the ccert request. */ | |
| int ne_ssl_context_set_verify(ne_ssl_context *ctx, int required, | | int ne_ssl_context_set_verify(ne_ssl_context *ctx, int required, | |
| const char *ca_names, const char *verify_cas)
; | | const char *ca_names, const char *verify_cas)
; | |
| | | | |
| #define NE_SSL_CTX_SSLv2 (0) | | #define NE_SSL_CTX_SSLv2 (0) | |
| /* Set a flag for the SSL context. */ | | /* Set a flag for the SSL context. */ | |
| void ne_ssl_context_set_flag(ne_ssl_context *ctx, int flag, int value); | | void ne_ssl_context_set_flag(ne_ssl_context *ctx, int flag, int value); | |
| | | | |
|
| | | /* Return flag value. */ | |
| | | int ne_ssl_context_get_flag(ne_ssl_context *ctx, int flag); | |
| | | | |
| /* Destroy an SSL context. */ | | /* Destroy an SSL context. */ | |
| void ne_ssl_context_destroy(ne_ssl_context *ctx); | | void ne_ssl_context_destroy(ne_ssl_context *ctx); | |
| | | | |
| NE_END_DECLS | | NE_END_DECLS | |
| | | | |
| #endif | | #endif | |
| | | | |
End of changes. 3 change blocks. |
| 4 lines changed or deleted | | 15 lines changed or added | |
|
| ne_utils.h | | ne_utils.h | |
| | | | |
| skipping to change at line 57 | | skipping to change at line 57 | |
| int ne_version_match(int major, int minor); | | int ne_version_match(int major, int minor); | |
| | | | |
| /* Feature codes: */ | | /* Feature codes: */ | |
| #define NE_FEATURE_SSL (1) /* SSL/TLS support */ | | #define NE_FEATURE_SSL (1) /* SSL/TLS support */ | |
| #define NE_FEATURE_ZLIB (2) /* zlib compression in compress interface */ | | #define NE_FEATURE_ZLIB (2) /* zlib compression in compress interface */ | |
| #define NE_FEATURE_IPV6 (3) /* IPv6 is supported in resolver */ | | #define NE_FEATURE_IPV6 (3) /* IPv6 is supported in resolver */ | |
| #define NE_FEATURE_LFS (4) /* large file support */ | | #define NE_FEATURE_LFS (4) /* large file support */ | |
| #define NE_FEATURE_SOCKS (5) /* SOCKSv5 support */ | | #define NE_FEATURE_SOCKS (5) /* SOCKSv5 support */ | |
| #define NE_FEATURE_TS_SSL (6) /* Thread-safe SSL/TLS support */ | | #define NE_FEATURE_TS_SSL (6) /* Thread-safe SSL/TLS support */ | |
| #define NE_FEATURE_I18N (7) /* i18n error message support */ | | #define NE_FEATURE_I18N (7) /* i18n error message support */ | |
|
| | | #define NE_FEATURE_SSPI (8) /* NTLM/Negotiate authentication protocol via S
SPI */ | |
| | | | |
| /* Returns non-zero if library is built with support for the given | | /* Returns non-zero if library is built with support for the given | |
| * NE_FEATURE_* feature code 'code'. */ | | * NE_FEATURE_* feature code 'code'. */ | |
| int ne_has_support(int feature); | | int ne_has_support(int feature); | |
| | | | |
| /* Debugging macro to allow code to be optimized out if debugging is | | /* Debugging macro to allow code to be optimized out if debugging is | |
| * disabled at build time. */ | | * disabled at build time. */ | |
| #ifndef NE_DEBUGGING | | #ifndef NE_DEBUGGING | |
| #define NE_DEBUG if (0) ne_debug | | #define NE_DEBUG if (0) ne_debug | |
| #else /* DEBUGGING */ | | #else /* DEBUGGING */ | |
| | | | |
End of changes. 1 change blocks. |
| 0 lines changed or deleted | | 1 lines changed or added | |
|