
/**
 *  BSPHP 网络验证 — 配置与 NetTool
 *  加解密与 POST 格式与仓库内 bsphp.app.demo.card（BSPHPCardConfig + BSPHPClient）一致。
 *  切换后台时仅改下列宏；勿将商业密钥提交到公开仓库。
 */

#import <Foundation/Foundation.h>

/// 激活弹窗内「公告下方」固定说明；**公告正文**由运行时请求 `api=gg.in` 拉取后拼在上方（与 verify.macos / Swift 演示一致）
#define BSPHP_ACTIVATION_ALERT_FOOTER @"首次激活成功后会保存卡密；再次打开将自动静默验证，验证通过则不再显示本窗口。\n\n请在下方输入授权码："

/// AppEn 完整入口 URL（与 Swift 演示 `BSPHPCardConfig.url` 一致）
#define BSPHP_HOST @"https://demo.bsphp.com/AppEn.php?appid=66666666&m=3a9d8b17c0a10b1b77f0544d35e835fa&lang=0"

/// mutualkey（与 Swift `BSPHPCardConfig.mutualKey` 一致）
#define BSPHP_MUTUALKEY @"417a696c5ee663c14bc6fa48b3f53d51"

/// 服务器私钥 Base64 DER PKCS#8（解密响应 RSA 段；与 Swift `serverPrivateKey` 一致）
#define BSPHP_SERVER_PRIVATE_KEY @"MIIEqQIBADANBgkqhkiG9w0BAQEFAASCBJMwggSPAgEAAoH+DZkOodN4q3IMn6momlnOTRSQS86cbHQBxePy3gyIxpayPnm11Y0sYbWyFJhDuTSAZYHbzQLRLRZvgQ1Nk1UmEQRxzUCp5Hkhig53CVfoQA5lgXln0Qgyhe5oOXAbeiLdqwkLIw27cOQyico+s2HniSHxPEl0ikqkXj+AWu5/z18x7PmDiSDRDf26cDteSwLv4on7uYWYsQCv+r8RF63l0ZkjjjCe91Z90aEI0ZTiZT6m0yIabHOHWHN4jhI2b++s8AQRDrN4uD317o9Z7gLeBtC+XDt5kvtJFeOfb9U8+wuneiIZkOhMybqnv1/8OzVfomPvub3Rs8+4q6OeEK8CAwEAAQKB/gG+LHHxePYAmD2esU2XVSnsCNKumL4N4GxM20Q6tw09I3t+fh/xCE89yqV5HrUOVaatDk8onUb6KTCRU/AeadKkjzGPqDbwj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FlbvkoAdCoOYqBxyPpbdT5ouDpek"

/// 客户端公钥 Base64 DER（加密请求 RSA 段；与 Swift `clientPublicKey` 一致）
#define BSPHP_CLIENT_PUBLIC_KEY @"MIIBHjANBgkqhkiG9w0BAQEFAAOCAQsAMIIBBgKB/gu5s9VMT323+6PzHKyNyESY0oBHdDgaq7rT5VyG7ETJZtI/Q9gaILfOv+ciobZA0WGlQHi/7ri/TDA1cEszg4uvPDEMw9lCLrY9kof5m3JJhLbJAov072oevMUdDcu92Szyl1qZXQ400zYXNVJDs95JNvvyK5OBIdGVsHi0JbczWMQF9QWYrn8dF8n3WWu8a3abslHV7W/JewBhYLlEgys1SkQqe7eIZfeTGi8elbVoXPwn2Bs+FSzViH9kxp4Out9eDjr/AeCDeuqFR39UfMLPDgXAKKv7HdskCWgZYDJSVk5CM3hpNj6RDBYNor83iurU3Y3+o/EDHNKyvRI3AgMBAAE="

@interface NetTool : NSObject

/**
 *  异步 POST：内部先 bootstrap（internet.in + BSphpSeSsL.in），再按 Swift 协议 AES+RSA 加密。
 *  appendURL 保留兼容，实际请求地址为 Config 中 BSPHP_HOST（与 Swift 单 URL 一致）。
 *  success 返回根 JSON 的 NSData（含 response），与旧版 NSJSONSerialization 解析方式兼容。
 */
+ (NSURLSessionDataTask *)__attribute__((optnone))Post_AppendURL:(NSString *)appendURL
                                                    myparameters:(NSDictionary *)param
                                                       mysuccess:(void (^)(id responseObject))success
                                                       myfailure:(void (^)(NSError *error))failure;
@end
