Files
waf-platform/HttpDNSSDK/sdk/ios/NewHttpDNS/Config/HttpdnsInternalConstant.h
2026-03-05 02:44:43 +08:00

61 lines
2.3 KiB
C
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//
// HttpdnsInternalConstant.h
// NewHttpDNS
//
// Created by xuyecan on 2025/03/10.
// Copyright © 2024 trustapp.com. All rights reserved.
//
#ifndef HTTPDNS_INTERNAL_CONSTANT_H
#define HTTPDNS_INTERNAL_CONSTANT_H
static const int HTTPDNS_MAX_REQUEST_RETRY_TIME = 1;
static const int HTTPDNS_MAX_MANAGE_HOST_NUM = 100;
static const int HTTPDNS_PRE_RESOLVE_BATCH_SIZE = 5;
static const int HTTPDNS_DEFAULT_REQUEST_TIMEOUT_INTERVAL = 3;
static const NSUInteger HTTPDNS_DEFAULT_AUTH_TIMEOUT_INTERVAL = 10 * 60;
static NSString *const NEW_HTTPDNS_VALID_SERVER_CERTIFICATE_IP = @"203.107.1.1";
// 在iOS14åŒiOS16,ç½ç»œä¿¡æ<C2A1>¯çš„获å<C2B7>æ<E28093>ƒé™<C3A9>å<EFBFBD>—到越æ<C5A0>¥è¶Šç´§çš„é™<C3A9>åˆ?
// 除é<C2A4>žç”¨æˆ·ä¸»åŠ¨å£°æ˜Žéœ€è¦<C3A8>ç¸å…³entitlement,ä¸<C3A4>ç„¶å<C2B6>ªèƒ½æ¿åˆ°ç©ºä¿¡æ<C2A1>¯
// 考è™å¤§å¤šæ•°ç”¨æˆ·å¹¶ä¸<C3A4>ä¼šç”³è¯·è¿™äºæ<E280BA>ƒé™<C3A9>,æˆä»¬æ”¾å¼ƒéˆå¯¹ç»†èŠçš„ç½ç»œä¿¡æ<C2A1>¯å<C2AF>šç¼“å­˜ç²åº¦éš”ç¦?
// 出于兼容性考è™ï¼Œç½ç»œè¿<C3A8>è<EFBFBD>¥å•†å<E280A0>ªæœ‰default一ç§<C3A7>ç±»åž?
#define HTTPDNS_DEFAULT_NETWORK_CARRIER_NAME @"default"
// 调度地å<C2B0>€ç¤ºä¾ï¼šhttp://106.11.90.200/sc/httpdns_config?account_id=153519&platform=ios&sdk_version=1.6.1
static NSString *const NEW_HTTPDNS_SCHEDULE_CENTER_REQUEST_HOST = @"httpdns-sc.NewAPPcs.com";
static NSString *const NEW_HTTPDNS_ERROR_MESSAGE_KEY = @"ErrorMessage";
static NSString *const kNewHttpdnsRegionConfigV4HostKey = @"service_ip";
static NSString *const kNewHttpdnsRegionConfigV6HostKey = @"service_ipv6";
static NSString *const kNewHttpdnsRegionKey = @"HttpdnsRegion";
#define SECONDS_OF_ONE_YEAR 365 * 24 * 60 * 60
static NSString *const NEW_HTTPDNS_ERROR_DOMAIN = @"HttpdnsErrorDomain";
static NSInteger const NEW_HTTPDNS_HTTPS_COMMON_ERROR_CODE = 10003;
static NSInteger const NEW_HTTPDNS_HTTP_COMMON_ERROR_CODE = 10004;
static NSInteger const NEW_HTTPDNS_HTTPS_TIMEOUT_ERROR_CODE = 10005;
static NSInteger const NEW_HTTPDNS_HTTP_TIMEOUT_ERROR_CODE = 10006;
static NSInteger const NEW_HTTPDNS_HTTP_OPEN_STREAM_ERROR_CODE = 10007;
static NSInteger const NEW_HTTPDNS_HTTPS_NO_DATA_ERROR_CODE = 10008;
static NSInteger const NEW_HTTP_UNSUPPORTED_STATUS_CODE = 10013;
static NSInteger const NEW_HTTP_PARSE_JSON_FAILED = 10014;
// 加密错误�
static NSInteger const NEW_HTTPDNS_ENCRYPT_INVALID_PARAMS_ERROR_CODE = 10021;
static NSInteger const NEW_HTTPDNS_ENCRYPT_RANDOM_IV_ERROR_CODE = 10022;
static NSInteger const NEW_HTTPDNS_ENCRYPT_FAILED_ERROR_CODE = 10023;
#endif