Port Forwarding SDK 1.5: By using our Port Forwarding SDK, your software can easily get the function of port forwarding. What you need to do is just three functions call, then your software magically have the function of tcp redirect and udp redirect.
If you want your software have the function of port forwarding, then our Port Forwarding SDK is exactly what you are looking for.
Below is the header file of our SDK and you can tell what you need to do is just three functions call.
#ifndef _PF_SDK_H
#define _PF_SDK_H
#ifdef __cplusplus
extern "C"{
#endif
/************
* Desc: init function call of port forwarding
* license: your license code
* return: 0:successful; -1:failed
***********/
int __declspec (dllexport) pf_init(char *license);
/************
* Desc: start a port forwarding
* ptype: protocol type of port forwarding. tcp or udp
* listen_port: the listen port of port forwarding
* destination_ip: the destination ip address of port forwrding
* destination_port: the destination port of port forwarding
* return: 0:successful; -1:failed
***********/
int __declspec (dllexport) pf_start(char *ptype, int listen_port, char *destination_ip, int destination_port);
/************
* Desc: stop a port forwarding
* listen_port: which listen port you want to stop
***********/
void __declspec (dllexport) pf_stop(int listen_port);
#ifdef __cplusplus
}
#endif
#endif
Our Port Forwarding SDK include a example source file that let you know how to use this sdk without learning.