代码拉取完成,页面将自动刷新
同步操作将从 CFYYWCC/ngrok-c 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
#pragma GCC diagnostic ignored "-Wwrite-strings"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#ifdef _WIN32
#include <windows.h>
#elif _LINUX
#include <sys/socket.h>
#elif __FreeBSD__
#include <sys/socket.h>
#include <netinet/in.h>
#include <netdb.h>
#include <arpa/inet.h>
#else
#error Platform not suppoted.
#endif
#include <errno.h>
#include<cstring>
#ifdef __cplusplus
#include <locale>
#endif
#include "sslbio.h"
#if WIN32
size_t strnlen (const char *str, size_t maxlen);
#endif
/*str*/
int str_contains(const char *haystack, const char *needle);
char *str_replace(char *search , char *replace , char *subject);
char* get_until(char *haystack, char *until);
char *str_ndup (const char *str, size_t max);
char* base64_encode(char *clrstr);
int str_index_of(const char *a, char *b);
int strpos(const char *haystack,const char *needle, int ignorecase);
/*url*/
struct parsed_url *parse_url(const char *url);
void parsed_url_free(struct parsed_url *purl);
/*
Prototype functions
*/
struct http_response* http_req(char *http_headers, struct parsed_url *purl);
struct http_response* http_get(char *url, char *custom_headers);
struct http_response* http_head(char *url, char *custom_headers);
struct http_response* http_post(char *url, char *custom_headers, char *post_data);
/*
Represents an HTTP html response
*/
struct http_response
{
struct parsed_url *request_uri;
char *body;
char *status_code;
int status_code_int;
char *status_text;
char *request_headers;
char *response_headers;
};
struct parsed_url
{
char *uri; /* mandatory */
char *scheme; /* mandatory */
char *host; /* mandatory */
char *ip; /* mandatory */
char *port; /* optional */
char *path; /* optional */
char *query; /* optional */
char *fragment; /* optional */
char *username; /* optional */
char *password; /* optional */
};
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。