├── release_note.txt ├── sdk └── extract-lib-subproject-to-here.txt ├── demo ├── WedprDemo │ ├── Assets.xcassets │ │ ├── Contents.json │ │ └── AppIcon.appiconset │ │ │ └── Contents.json │ ├── ViewController.h │ ├── AppDelegate.h │ ├── SceneDelegate.h │ ├── main.m │ ├── OpenSSL │ │ └── include │ │ │ └── openssl │ │ │ ├── ebcdic.h │ │ │ ├── whrlpool.h │ │ │ ├── comp.h │ │ │ ├── pem2.h │ │ │ ├── cmac.h │ │ │ ├── ui_compat.h │ │ │ ├── ssl23.h │ │ │ ├── rc4.h │ │ │ ├── pqueue.h │ │ │ ├── mdc2.h │ │ │ ├── opensslv.h │ │ │ ├── conf_api.h │ │ │ ├── ripemd.h │ │ │ ├── rc2.h │ │ │ ├── stack.h │ │ │ ├── hmac.h │ │ │ ├── cast.h │ │ │ ├── txt_db.h │ │ │ ├── idea.h │ │ │ ├── md4.h │ │ │ ├── md5.h │ │ │ └── buffer.h │ ├── Wedpr │ │ ├── WedprKtb.h │ │ ├── WedprCrypto.h │ │ ├── WedprCommon.h │ │ ├── WedprVcl.h │ │ └── WedprScd.h │ ├── AppDelegate.m │ ├── Base.lproj │ │ ├── Main.storyboard │ │ └── LaunchScreen.storyboard │ ├── Common.pbobjc.h │ ├── Info.plist │ ├── SceneDelegate.m │ ├── Hdk.pbobjc.h │ ├── Vcl.pbobjc.h │ └── Common.pbobjc.m ├── Pods │ ├── Target Support Files │ │ ├── Pods-WedprDemo │ │ │ ├── Pods-WedprDemo-frameworks-Debug-output-files.xcfilelist │ │ │ ├── Pods-WedprDemo-frameworks-Release-output-files.xcfilelist │ │ │ ├── Pods-WedprDemo.modulemap │ │ │ ├── Pods-WedprDemo-dummy.m │ │ │ ├── Pods-WedprDemo-frameworks-Debug-input-files.xcfilelist │ │ │ ├── Pods-WedprDemo-frameworks-Release-input-files.xcfilelist │ │ │ ├── Pods-WedprDemo-umbrella.h │ │ │ ├── Pods-WedprDemo.debug.xcconfig │ │ │ ├── Pods-WedprDemo.release.xcconfig │ │ │ ├── Pods-WedprDemo-Info.plist │ │ │ ├── Pods-WedprDemo-acknowledgements.markdown │ │ │ └── Pods-WedprDemo-acknowledgements.plist │ │ └── Protobuf │ │ │ ├── Protobuf.modulemap │ │ │ ├── Protobuf-dummy.m │ │ │ ├── Protobuf-prefix.pch │ │ │ ├── Protobuf.debug.xcconfig │ │ │ ├── Protobuf.release.xcconfig │ │ │ ├── Protobuf-Info.plist │ │ │ └── Protobuf-umbrella.h │ └── Protobuf │ │ ├── LICENSE │ │ └── objectivec │ │ ├── GPBProtocolBuffers_RuntimeSupport.h │ │ ├── GPBRootObject_PackagePrivate.h │ │ ├── GPBUnknownField_PackagePrivate.h │ │ ├── GPBRootObject.h │ │ ├── google │ │ └── protobuf │ │ │ ├── Empty.pbobjc.h │ │ │ ├── SourceContext.pbobjc.h │ │ │ ├── Empty.pbobjc.m │ │ │ ├── FieldMask.pbobjc.m │ │ │ ├── SourceContext.pbobjc.m │ │ │ ├── Duration.pbobjc.m │ │ │ ├── Timestamp.pbobjc.m │ │ │ ├── Any.pbobjc.m │ │ │ └── Duration.pbobjc.h │ │ ├── GPBExtensionInternals.h │ │ ├── GPBUnknownFieldSet_PackagePrivate.h │ │ ├── GPBUnknownFieldSet.h │ │ ├── GPBWireFormat.h │ │ ├── GPBProtocolBuffers.h │ │ ├── GPBUnknownField.h │ │ ├── GPBExtensionRegistry.h │ │ ├── GPBWireFormat.m │ │ └── GPBArray_PackagePrivate.h ├── WedprDemo.xcodeproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ └── IDEWorkspaceChecks.plist │ └── xcshareddata │ │ └── xcschemes │ │ └── WedprDemo.xcscheme ├── WedprDemo.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist └── Podfile ├── README.md └── .gitignore /release_note.txt: -------------------------------------------------------------------------------- 1 | v0.3.0 2 | -------------------------------------------------------------------------------- /sdk/extract-lib-subproject-to-here.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /demo/WedprDemo/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-frameworks-Debug-output-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/protobuf.framework -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-frameworks-Release-output-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/protobuf.framework -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Protobuf/Protobuf.modulemap: -------------------------------------------------------------------------------- 1 | framework module protobuf { 2 | umbrella header "Protobuf-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Protobuf/Protobuf-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Protobuf : NSObject 3 | @end 4 | @implementation PodsDummy_Protobuf 5 | @end 6 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_WedprDemo { 2 | umbrella header "Pods-WedprDemo-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_WedprDemo : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_WedprDemo 5 | @end 6 | -------------------------------------------------------------------------------- /demo/WedprDemo/ViewController.h: -------------------------------------------------------------------------------- 1 | // Copyright 2020 WeDPR Lab Project Authors. Licensed under Apache-2.0. 2 | 3 | #import 4 | 5 | @interface ViewController : UIViewController 6 | 7 | 8 | @end 9 | 10 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-frameworks-Debug-input-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${PODS_ROOT}/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-frameworks.sh 2 | ${BUILT_PRODUCTS_DIR}/Protobuf/protobuf.framework -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-frameworks-Release-input-files.xcfilelist: -------------------------------------------------------------------------------- 1 | ${PODS_ROOT}/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-frameworks.sh 2 | ${BUILT_PRODUCTS_DIR}/Protobuf/protobuf.framework -------------------------------------------------------------------------------- /demo/WedprDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /demo/WedprDemo/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // Copyright 2020 WeDPR Lab Project Authors. Licensed under Apache-2.0. 2 | 3 | #import 4 | 5 | @interface AppDelegate : UIResponder 6 | 7 | 8 | @end 9 | 10 | -------------------------------------------------------------------------------- /demo/WedprDemo/SceneDelegate.h: -------------------------------------------------------------------------------- 1 | // Copyright 2020 WeDPR Lab Project Authors. Licensed under Apache-2.0. 2 | 3 | #import 4 | 5 | @interface SceneDelegate : UIResponder 6 | 7 | @property (strong, nonatomic) UIWindow * window; 8 | 9 | @end 10 | 11 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Protobuf/Protobuf-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /demo/WedprDemo.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /demo/WedprDemo.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /demo/WedprDemo.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double Pods_WedprDemoVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char Pods_WedprDemoVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /demo/Podfile: -------------------------------------------------------------------------------- 1 | # Uncomment the next line to define a global platform for your project 2 | # platform :ios, '9.0' 3 | #source 'https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git' 4 | 5 | target 'WedprDemo' do 6 | # Comment the next line if you don't want to use dynamic frameworks 7 | use_frameworks! 8 | 9 | # Pods for WedprDemo 10 | # pod 'SwiftProtobuf', '~> 1.0' 11 | pod "Protobuf",' ~> 3.11.3' 12 | # :git => "https://github.com/google/protobuf.git" 13 | 14 | end 15 | -------------------------------------------------------------------------------- /demo/WedprDemo/main.m: -------------------------------------------------------------------------------- 1 | // Copyright 2020 WeDPR Lab Project Authors. Licensed under Apache-2.0. 2 | 3 | #import 4 | #import "AppDelegate.h" 5 | 6 | int main(int argc, char * argv[]) { 7 | NSString * appDelegateClassName; 8 | @autoreleasepool { 9 | // Setup code that might create autoreleased objects goes here. 10 | appDelegateClassName = NSStringFromClass([AppDelegate class]); 11 | } 12 | return UIApplicationMain(argc, argv, nil, appDelegateClassName); 13 | } 14 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Protobuf/Protobuf.debug.xcconfig: -------------------------------------------------------------------------------- 1 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/Protobuf 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 $(inherited) GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1 3 | PODS_BUILD_DIR = ${BUILD_DIR} 4 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 5 | PODS_ROOT = ${SRCROOT} 6 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/Protobuf 7 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 8 | SKIP_INSTALL = YES 9 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 10 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Protobuf/Protobuf.release.xcconfig: -------------------------------------------------------------------------------- 1 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/Protobuf 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 $(inherited) GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1 3 | PODS_BUILD_DIR = ${BUILD_DIR} 4 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 5 | PODS_ROOT = ${SRCROOT} 6 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/Protobuf 7 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 8 | SKIP_INSTALL = YES 9 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 10 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # WeDPR-Lab-iOS-SDK 2 | 3 | ## 如何体验WeDPR-Lab-iOS-SDK 4 | 5 | WeDPR-Lab-iOS-SDK是WeDPR-Lab的iOS客户端。 6 | 7 | ## 环境依赖 8 | 9 | WeDPR Lab iOS SDK 依赖如下: 10 | 11 | | 依赖软件 | 支持版本 | 12 | | :-: | :-: | 13 | | xcode-toolchain | 12.1 | 14 | 15 | ## 快速体验 16 | 17 | 编译项目前,需要准备好`xcode、安装cocoapods,并注册ios开发者账号`。 18 | 19 | - 下载仓库 20 | 21 | ```bash 22 | git clone https://github.com/WeBankBlockchain/WeDPR-Lab-iOS-SDK.git && cd ./WeDPR-Lab-iOS-SDK 23 | ``` 24 | 25 | - 获取静态库:访问[依赖库地址](https://github.com/WeBankBlockchain/WeDPR-Lab-Core/releases/tag/v1.1.0)页面下载ios_sdk_static_lib.tar.gz 与 OpenSSL.tar.gz 26 | 27 | - 添加静态库至xcode:将libffi_c_crypto.a与libffi_c_vcl.a添加至xcode 28 | - 查看demo:查看ViewController.m了解demo调用页面 29 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/ebcdic.h: -------------------------------------------------------------------------------- 1 | /* crypto/ebcdic.h */ 2 | 3 | #ifndef HEADER_EBCDIC_H 4 | # define HEADER_EBCDIC_H 5 | 6 | # include 7 | 8 | #ifdef __cplusplus 9 | extern "C" { 10 | #endif 11 | 12 | /* Avoid name clashes with other applications */ 13 | # define os_toascii _openssl_os_toascii 14 | # define os_toebcdic _openssl_os_toebcdic 15 | # define ebcdic2ascii _openssl_ebcdic2ascii 16 | # define ascii2ebcdic _openssl_ascii2ebcdic 17 | 18 | extern const unsigned char os_toascii[256]; 19 | extern const unsigned char os_toebcdic[256]; 20 | void *ebcdic2ascii(void *dest, const void *srce, size_t count); 21 | void *ascii2ebcdic(void *dest, const void *srce, size_t count); 22 | 23 | #ifdef __cplusplus 24 | } 25 | #endif 26 | #endif 27 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo.debug.xcconfig: -------------------------------------------------------------------------------- 1 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/Protobuf" 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 $(inherited) GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1 3 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/Protobuf/protobuf.framework/Headers" 4 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 5 | OTHER_LDFLAGS = $(inherited) -framework "protobuf" 6 | PODS_BUILD_DIR = ${BUILD_DIR} 7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 9 | PODS_ROOT = ${SRCROOT}/Pods 10 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 11 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo.release.xcconfig: -------------------------------------------------------------------------------- 1 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/Protobuf" 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 $(inherited) GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1 3 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/Protobuf/protobuf.framework/Headers" 4 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 5 | OTHER_LDFLAGS = $(inherited) -framework "protobuf" 6 | PODS_BUILD_DIR = ${BUILD_DIR} 7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 9 | PODS_ROOT = ${SRCROOT}/Pods 10 | USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES 11 | -------------------------------------------------------------------------------- /demo/WedprDemo/Wedpr/WedprKtb.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | 6 | /** 7 | * C interface for 'wedpr_ktb_hdk_create_master_key_en'. 8 | */ 9 | char *wedpr_ktb_hdk_create_master_key_en(char *password_cstring, char *mnemonic_cstring); 10 | 11 | /** 12 | * C interface for 'wedpr_ktb_hdk_create_mnemonic_en'. 13 | */ 14 | char *wedpr_ktb_hdk_create_mnemonic_en(unsigned char word_count); 15 | 16 | /** 17 | * C interface for 'wedpr_ktb_hdk_derive_extended_key'. 18 | */ 19 | char *wedpr_ktb_hdk_derive_extended_key(char *master_key_cstring, 20 | int purpose_type, 21 | int asset_type, 22 | int account, 23 | int change, 24 | int address_index); 25 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Protobuf/Protobuf-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 3.11.4 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /demo/WedprDemo/Wedpr/WedprCrypto.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | 6 | /** 7 | * C interface for 'wedpr_secp256k1_ecies_encrypt'. 8 | */ 9 | char *wedpr_secp256k1_ecies_encrypt(char *encoded_public_key, char *encoded_plaintext); 10 | 11 | /** 12 | * C interface for 'wedpr_secp256k1_ecies_decrypt'. 13 | */ 14 | char *wedpr_secp256k1_ecies_decrypt(char *encoded_private_key, char *encoded_ciphertext); 15 | 16 | /** 17 | * C interface for 'wedpr_secp256k1_gen_key_pair'. 18 | */ 19 | char *wedpr_secp256k1_gen_key_pair(void); 20 | 21 | /** 22 | * C interface for 'wedpr_secp256k1_sign'. 23 | */ 24 | char *wedpr_secp256k1_sign(char *encoded_private_key, char *encoded_message_hash); 25 | 26 | /** 27 | * C interface for 'wedpr_secp256k1_verify'. 28 | */ 29 | int8_t wedpr_secp256k1_verify(char *encoded_public_key, 30 | char *encoded_message_hash, 31 | char *encoded_signature); 32 | 33 | /** 34 | * C interface for 'wedpr_keccak256_hash'. 35 | */ 36 | char *wedpr_keccak256_hash(char *encoded_message); 37 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ### Common section ### 2 | 3 | */.DS_Store 4 | **/.vscode/ 5 | **/.idea/* 6 | *.lock 7 | *.a 8 | *.tar.gz 9 | *.docx 10 | .DS_Store 11 | */target 12 | */OpenSSL 13 | 14 | ### Objective-C ### 15 | 16 | ## User settings 17 | **/xcuserdata/ 18 | 19 | ## compatibility with Xcode 8 and earlier (ignoring not required starting Xcode 9) 20 | *.xcscmblueprint 21 | *.xccheckout 22 | 23 | ## compatibility with Xcode 3 and earlier (ignoring not required starting Xcode 4) 24 | **/build/ 25 | **/DerivedData/ 26 | *.moved-aside 27 | *.pbxuser 28 | !default.pbxuser 29 | *.mode1v3 30 | !default.mode1v3 31 | *.mode2v3 32 | !default.mode2v3 33 | *.perspectivev3 34 | !default.perspectivev3 35 | 36 | ## Obj-C/Swift specific 37 | *.hmap 38 | 39 | ## App packaging 40 | *.ipa 41 | *.dSYM.zip 42 | *.dSYM 43 | 44 | ## Gcc Patch 45 | **/*.gcno 46 | 47 | ### Xcode Patch ### 48 | **/*.xcodeproj/* 49 | !**/*.xcodeproj/project.pbxproj 50 | !**/*.xcodeproj/xcshareddata/ 51 | !**/*.xcworkspace/contents.xcworkspacedata 52 | **/xcshareddata/WorkspaceSettings.xcsettings 53 | 54 | # End of https://www.toptal.com/developers/gitignore/api/xcode,objective-c -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/whrlpool.h: -------------------------------------------------------------------------------- 1 | #ifndef HEADER_WHRLPOOL_H 2 | # define HEADER_WHRLPOOL_H 3 | 4 | # include 5 | # include 6 | 7 | #ifdef __cplusplus 8 | extern "C" { 9 | #endif 10 | 11 | # define WHIRLPOOL_DIGEST_LENGTH (512/8) 12 | # define WHIRLPOOL_BBLOCK 512 13 | # define WHIRLPOOL_COUNTER (256/8) 14 | 15 | typedef struct { 16 | union { 17 | unsigned char c[WHIRLPOOL_DIGEST_LENGTH]; 18 | /* double q is here to ensure 64-bit alignment */ 19 | double q[WHIRLPOOL_DIGEST_LENGTH / sizeof(double)]; 20 | } H; 21 | unsigned char data[WHIRLPOOL_BBLOCK / 8]; 22 | unsigned int bitoff; 23 | size_t bitlen[WHIRLPOOL_COUNTER / sizeof(size_t)]; 24 | } WHIRLPOOL_CTX; 25 | 26 | # ifndef OPENSSL_NO_WHIRLPOOL 27 | # ifdef OPENSSL_FIPS 28 | int private_WHIRLPOOL_Init(WHIRLPOOL_CTX *c); 29 | # endif 30 | int WHIRLPOOL_Init(WHIRLPOOL_CTX *c); 31 | int WHIRLPOOL_Update(WHIRLPOOL_CTX *c, const void *inp, size_t bytes); 32 | void WHIRLPOOL_BitUpdate(WHIRLPOOL_CTX *c, const void *inp, size_t bits); 33 | int WHIRLPOOL_Final(unsigned char *md, WHIRLPOOL_CTX *c); 34 | unsigned char *WHIRLPOOL(const void *inp, size_t bytes, unsigned char *md); 35 | # endif 36 | 37 | #ifdef __cplusplus 38 | } 39 | #endif 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /demo/WedprDemo/Wedpr/WedprCommon.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | 6 | typedef struct backtrace_state backtrace_state; 7 | 8 | typedef void (*backtrace_error_callback)(void *data, const char *msg, int errnum); 9 | 10 | typedef void (*backtrace_syminfo_callback)(void *data, uintptr_t pc, const char *symname, uintptr_t symval, uintptr_t symsize); 11 | 12 | typedef int (*backtrace_full_callback)(void *data, uintptr_t pc, const char *filename, int lineno, const char *function); 13 | 14 | backtrace_state *__rbt_backtrace_create_state(const char *_filename, 15 | int _threaded, 16 | backtrace_error_callback _error, 17 | void *_data); 18 | 19 | int __rbt_backtrace_syminfo(backtrace_state *_state, 20 | uintptr_t _addr, 21 | backtrace_syminfo_callback _cb, 22 | backtrace_error_callback _error, 23 | void *_data); 24 | 25 | int __rbt_backtrace_pcinfo(backtrace_state *_state, 26 | uintptr_t _addr, 27 | backtrace_full_callback _cb, 28 | backtrace_error_callback _error, 29 | void *_data); 30 | -------------------------------------------------------------------------------- /demo/WedprDemo/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // Copyright 2020 WeDPR Lab Project Authors. Licensed under Apache-2.0. 2 | 3 | #import "AppDelegate.h" 4 | 5 | @interface AppDelegate () 6 | 7 | @end 8 | 9 | @implementation AppDelegate 10 | 11 | 12 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 13 | // Override point for customization after application launch. 14 | return YES; 15 | } 16 | 17 | 18 | #pragma mark - UISceneSession lifecycle 19 | 20 | 21 | - (UISceneConfiguration *)application:(UIApplication *)application configurationForConnectingSceneSession:(UISceneSession *)connectingSceneSession options:(UISceneConnectionOptions *)options { 22 | // Called when a new scene session is being created. 23 | // Use this method to select a configuration to create the new scene with. 24 | return [[UISceneConfiguration alloc] initWithName:@"Default Configuration" sessionRole:connectingSceneSession.role]; 25 | } 26 | 27 | 28 | - (void)application:(UIApplication *)application didDiscardSceneSessions:(NSSet *)sceneSessions { 29 | // Called when the user discards a scene session. 30 | // If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions. 31 | // Use this method to release any resources that were specific to the discarded scenes, as they will not return. 32 | } 33 | 34 | 35 | @end 36 | -------------------------------------------------------------------------------- /demo/WedprDemo/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /demo/WedprDemo/Wedpr/WedprVcl.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | 6 | /** 7 | * C interface for 'wedpr_vcl_make_credit'. 8 | */ 9 | char *wedpr_vcl_make_credit(unsigned long value); 10 | 11 | /** 12 | * C interface for 'wedpr_vcl_prove_sum_balance'. 13 | */ 14 | char *wedpr_vcl_prove_sum_balance(char *c1_secret_cstring, 15 | char *c2_secret_cstring, 16 | char *c3_secret_cstring); 17 | 18 | /** 19 | * C interface for 'wedpr_vcl_verify_sum_balance'. 20 | */ 21 | int8_t wedpr_vcl_verify_sum_balance(char *c1_credit_cstring, 22 | char *c2_credit_cstring, 23 | char *c3_credit_cstring, 24 | char *proof_cstring); 25 | 26 | /** 27 | * C interface for 'wedpr_vcl_prove_product_balance'. 28 | */ 29 | char *wedpr_vcl_prove_product_balance(char *c1_secret_cstring, 30 | char *c2_secret_cstring, 31 | char *c3_secret_cstring); 32 | 33 | /** 34 | * C interface for 'wedpr_vcl_verify_product_balance'. 35 | */ 36 | int8_t wedpr_vcl_verify_product_balance(char *c1_credit_cstring, 37 | char *c2_credit_cstring, 38 | char *c3_credit_cstring, 39 | char *proof_cstring); 40 | 41 | /** 42 | * C interface for 'wedpr_vcl_prove_range'. 43 | */ 44 | char *wedpr_vcl_prove_range(char *secret_cstring); 45 | 46 | /** 47 | * C interface for 'wedpr_vcl_verify_range'. 48 | */ 49 | int8_t wedpr_vcl_verify_range(char *credit_cstring, char *proof_cstring); 50 | -------------------------------------------------------------------------------- /demo/WedprDemo/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Protobuf/Protobuf-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | #import "GPBArray.h" 14 | #import "GPBArray_PackagePrivate.h" 15 | #import "GPBBootstrap.h" 16 | #import "GPBCodedInputStream.h" 17 | #import "GPBCodedInputStream_PackagePrivate.h" 18 | #import "GPBCodedOutputStream.h" 19 | #import "GPBCodedOutputStream_PackagePrivate.h" 20 | #import "GPBDescriptor.h" 21 | #import "GPBDescriptor_PackagePrivate.h" 22 | #import "GPBDictionary.h" 23 | #import "GPBDictionary_PackagePrivate.h" 24 | #import "GPBExtensionInternals.h" 25 | #import "GPBExtensionRegistry.h" 26 | #import "GPBMessage.h" 27 | #import "GPBMessage_PackagePrivate.h" 28 | #import "GPBProtocolBuffers.h" 29 | #import "GPBProtocolBuffers_RuntimeSupport.h" 30 | #import "GPBRootObject.h" 31 | #import "GPBRootObject_PackagePrivate.h" 32 | #import "GPBRuntimeTypes.h" 33 | #import "GPBUnknownField.h" 34 | #import "GPBUnknownFieldSet.h" 35 | #import "GPBUnknownFieldSet_PackagePrivate.h" 36 | #import "GPBUnknownField_PackagePrivate.h" 37 | #import "GPBUtilities.h" 38 | #import "GPBUtilities_PackagePrivate.h" 39 | #import "GPBWellKnownTypes.h" 40 | #import "GPBWireFormat.h" 41 | #import "Any.pbobjc.h" 42 | #import "Api.pbobjc.h" 43 | #import "Duration.pbobjc.h" 44 | #import "Empty.pbobjc.h" 45 | #import "FieldMask.pbobjc.h" 46 | #import "SourceContext.pbobjc.h" 47 | #import "Struct.pbobjc.h" 48 | #import "Timestamp.pbobjc.h" 49 | #import "Type.pbobjc.h" 50 | #import "Wrappers.pbobjc.h" 51 | 52 | FOUNDATION_EXPORT double protobufVersionNumber; 53 | FOUNDATION_EXPORT const unsigned char protobufVersionString[]; 54 | 55 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2008 Google Inc. All rights reserved. 2 | 3 | Redistribution and use in source and binary forms, with or without 4 | modification, are permitted provided that the following conditions are 5 | met: 6 | 7 | * Redistributions of source code must retain the above copyright 8 | notice, this list of conditions and the following disclaimer. 9 | * Redistributions in binary form must reproduce the above 10 | copyright notice, this list of conditions and the following disclaimer 11 | in the documentation and/or other materials provided with the 12 | distribution. 13 | * Neither the name of Google Inc. nor the names of its 14 | contributors may be used to endorse or promote products derived from 15 | this software without specific prior written permission. 16 | 17 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 18 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 19 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 20 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 21 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 22 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 23 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 24 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 25 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 27 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 | 29 | Code generated by the Protocol Buffer compiler is owned by the owner 30 | of the input file used when generating it. This code is not 31 | standalone and requires a support library to be linked with it. This 32 | support library is itself covered by the above license. 33 | -------------------------------------------------------------------------------- /demo/WedprDemo/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "scale" : "2x", 6 | "size" : "20x20" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "scale" : "3x", 11 | "size" : "20x20" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "scale" : "2x", 16 | "size" : "29x29" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "scale" : "3x", 21 | "size" : "29x29" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "scale" : "2x", 26 | "size" : "40x40" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "scale" : "3x", 31 | "size" : "40x40" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "scale" : "2x", 36 | "size" : "60x60" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "scale" : "3x", 41 | "size" : "60x60" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "scale" : "1x", 46 | "size" : "20x20" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "scale" : "2x", 51 | "size" : "20x20" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "scale" : "1x", 56 | "size" : "29x29" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "scale" : "2x", 61 | "size" : "29x29" 62 | }, 63 | { 64 | "idiom" : "ipad", 65 | "scale" : "1x", 66 | "size" : "40x40" 67 | }, 68 | { 69 | "idiom" : "ipad", 70 | "scale" : "2x", 71 | "size" : "40x40" 72 | }, 73 | { 74 | "idiom" : "ipad", 75 | "scale" : "1x", 76 | "size" : "76x76" 77 | }, 78 | { 79 | "idiom" : "ipad", 80 | "scale" : "2x", 81 | "size" : "76x76" 82 | }, 83 | { 84 | "idiom" : "ipad", 85 | "scale" : "2x", 86 | "size" : "83.5x83.5" 87 | }, 88 | { 89 | "idiom" : "ios-marketing", 90 | "scale" : "1x", 91 | "size" : "1024x1024" 92 | } 93 | ], 94 | "info" : { 95 | "author" : "xcode", 96 | "version" : 1 97 | } 98 | } 99 | -------------------------------------------------------------------------------- /demo/WedprDemo/Common.pbobjc.h: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: common.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers.h" 14 | #endif 15 | 16 | #if GOOGLE_PROTOBUF_OBJC_VERSION < 30002 17 | #error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources. 18 | #endif 19 | #if 30002 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION 20 | #error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources. 21 | #endif 22 | 23 | // @@protoc_insertion_point(imports) 24 | 25 | #pragma clang diagnostic push 26 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 27 | 28 | CF_EXTERN_C_BEGIN 29 | 30 | NS_ASSUME_NONNULL_BEGIN 31 | 32 | #pragma mark - CommonRoot 33 | 34 | /** 35 | * Exposes the extension registry for this file. 36 | * 37 | * The base class provides: 38 | * @code 39 | * + (GPBExtensionRegistry *)extensionRegistry; 40 | * @endcode 41 | * which is a @c GPBExtensionRegistry that includes all the extensions defined by 42 | * this file and all files that it depends on. 43 | **/ 44 | @interface CommonRoot : GPBRootObject 45 | @end 46 | 47 | #pragma mark - Keypair 48 | 49 | typedef GPB_ENUM(Keypair_FieldNumber) { 50 | Keypair_FieldNumber_PublicKey = 1, 51 | Keypair_FieldNumber_PrivateKey = 2, 52 | }; 53 | 54 | @interface Keypair : GPBMessage 55 | 56 | @property(nonatomic, readwrite, copy, null_resettable) NSString *publicKey; 57 | 58 | @property(nonatomic, readwrite, copy, null_resettable) NSString *privateKey; 59 | 60 | @end 61 | 62 | NS_ASSUME_NONNULL_END 63 | 64 | CF_EXTERN_C_END 65 | 66 | #pragma clang diagnostic pop 67 | 68 | // @@protoc_insertion_point(global_scope) 69 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-acknowledgements.markdown: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | This application makes use of the following third party libraries: 3 | 4 | ## Protobuf 5 | 6 | Copyright 2008 Google Inc. All rights reserved. 7 | 8 | Redistribution and use in source and binary forms, with or without 9 | modification, are permitted provided that the following conditions are 10 | met: 11 | 12 | * Redistributions of source code must retain the above copyright 13 | notice, this list of conditions and the following disclaimer. 14 | * Redistributions in binary form must reproduce the above 15 | copyright notice, this list of conditions and the following disclaimer 16 | in the documentation and/or other materials provided with the 17 | distribution. 18 | * Neither the name of Google Inc. nor the names of its 19 | contributors may be used to endorse or promote products derived from 20 | this software without specific prior written permission. 21 | 22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 23 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 24 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 25 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 26 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 27 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 28 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 29 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 30 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 31 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 32 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 33 | 34 | Code generated by the Protocol Buffer compiler is owned by the owner 35 | of the input file used when generating it. This code is not 36 | standalone and requires a support library to be linked with it. This 37 | support library is itself covered by the above license. 38 | 39 | Generated by CocoaPods - https://cocoapods.org 40 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBProtocolBuffers_RuntimeSupport.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | // This header is meant to only be used by the generated source, it should not 32 | // be included in code using protocol buffers. 33 | 34 | #import "GPBBootstrap.h" 35 | 36 | #import "GPBDescriptor_PackagePrivate.h" 37 | #import "GPBExtensionInternals.h" 38 | #import "GPBMessage_PackagePrivate.h" 39 | #import "GPBRootObject_PackagePrivate.h" 40 | #import "GPBUtilities_PackagePrivate.h" 41 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBRootObject_PackagePrivate.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | #import "GPBRootObject.h" 34 | 35 | @class GPBExtensionDescriptor; 36 | 37 | @interface GPBRootObject () 38 | 39 | // Globally register. 40 | + (void)globallyRegisterExtension:(GPBExtensionDescriptor *)field; 41 | 42 | @end 43 | 44 | // Returns YES if the selector was resolved and added to the class, 45 | // NO otherwise. 46 | BOOL GPBResolveExtensionClassMethod(Class self, SEL sel); 47 | -------------------------------------------------------------------------------- /demo/WedprDemo/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | $(PRODUCT_BUNDLE_PACKAGE_TYPE) 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | UIApplicationSceneManifest 24 | 25 | UIApplicationSupportsMultipleScenes 26 | 27 | UISceneConfigurations 28 | 29 | UIWindowSceneSessionRoleApplication 30 | 31 | 32 | UISceneConfigurationName 33 | Default Configuration 34 | UISceneDelegateClassName 35 | SceneDelegate 36 | UISceneStoryboardFile 37 | Main 38 | 39 | 40 | 41 | 42 | UILaunchStoryboardName 43 | LaunchScreen 44 | UIMainStoryboardFile 45 | Main 46 | UIRequiredDeviceCapabilities 47 | 48 | armv7 49 | 50 | UISupportedInterfaceOrientations 51 | 52 | UIInterfaceOrientationPortrait 53 | UIInterfaceOrientationLandscapeLeft 54 | UIInterfaceOrientationLandscapeRight 55 | 56 | UISupportedInterfaceOrientations~ipad 57 | 58 | UIInterfaceOrientationPortrait 59 | UIInterfaceOrientationPortraitUpsideDown 60 | UIInterfaceOrientationLandscapeLeft 61 | UIInterfaceOrientationLandscapeRight 62 | 63 | 64 | 65 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBUnknownField_PackagePrivate.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | #import "GPBUnknownField.h" 34 | 35 | @class GPBCodedOutputStream; 36 | 37 | @interface GPBUnknownField () 38 | 39 | - (void)writeToOutput:(GPBCodedOutputStream *)output; 40 | - (size_t)serializedSize; 41 | 42 | - (void)writeAsMessageSetExtensionToOutput:(GPBCodedOutputStream *)output; 43 | - (size_t)serializedSizeAsMessageSetExtension; 44 | 45 | - (void)mergeFromField:(GPBUnknownField *)other; 46 | 47 | @end 48 | -------------------------------------------------------------------------------- /demo/WedprDemo/SceneDelegate.m: -------------------------------------------------------------------------------- 1 | // Copyright 2020 WeDPR Lab Project Authors. Licensed under Apache-2.0. 2 | 3 | #import "SceneDelegate.h" 4 | 5 | @interface SceneDelegate () 6 | 7 | @end 8 | 9 | @implementation SceneDelegate 10 | 11 | 12 | - (void)scene:(UIScene *)scene willConnectToSession:(UISceneSession *)session options:(UISceneConnectionOptions *)connectionOptions { 13 | // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`. 14 | // If using a storyboard, the `window` property will automatically be initialized and attached to the scene. 15 | // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead). 16 | } 17 | 18 | 19 | - (void)sceneDidDisconnect:(UIScene *)scene { 20 | // Called as the scene is being released by the system. 21 | // This occurs shortly after the scene enters the background, or when its session is discarded. 22 | // Release any resources associated with this scene that can be re-created the next time the scene connects. 23 | // The scene may re-connect later, as its session was not neccessarily discarded (see `application:didDiscardSceneSessions` instead). 24 | } 25 | 26 | 27 | - (void)sceneDidBecomeActive:(UIScene *)scene { 28 | // Called when the scene has moved from an inactive state to an active state. 29 | // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive. 30 | } 31 | 32 | 33 | - (void)sceneWillResignActive:(UIScene *)scene { 34 | // Called when the scene will move from an active state to an inactive state. 35 | // This may occur due to temporary interruptions (ex. an incoming phone call). 36 | } 37 | 38 | 39 | - (void)sceneWillEnterForeground:(UIScene *)scene { 40 | // Called as the scene transitions from the background to the foreground. 41 | // Use this method to undo the changes made on entering the background. 42 | } 43 | 44 | 45 | - (void)sceneDidEnterBackground:(UIScene *)scene { 46 | // Called as the scene transitions from the foreground to the background. 47 | // Use this method to save data, release shared resources, and store enough scene-specific state information 48 | // to restore the scene back to its current state. 49 | } 50 | 51 | 52 | @end 53 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBRootObject.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | @class GPBExtensionRegistry; 34 | 35 | NS_ASSUME_NONNULL_BEGIN 36 | 37 | /** 38 | * Every generated proto file defines a local "Root" class that exposes a 39 | * GPBExtensionRegistry for all the extensions defined by that file and 40 | * the files it depends on. 41 | **/ 42 | @interface GPBRootObject : NSObject 43 | 44 | /** 45 | * @return An extension registry for the given file and all the files it depends 46 | * on. 47 | **/ 48 | + (GPBExtensionRegistry *)extensionRegistry; 49 | 50 | @end 51 | 52 | NS_ASSUME_NONNULL_END 53 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/Empty.pbobjc.h: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/empty.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #import 13 | #import 14 | #else 15 | #import "GPBDescriptor.h" 16 | #import "GPBMessage.h" 17 | #import "GPBRootObject.h" 18 | #endif 19 | 20 | #if GOOGLE_PROTOBUF_OBJC_VERSION < 30002 21 | #error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources. 22 | #endif 23 | #if 30002 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION 24 | #error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources. 25 | #endif 26 | 27 | // @@protoc_insertion_point(imports) 28 | 29 | #pragma clang diagnostic push 30 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 31 | 32 | CF_EXTERN_C_BEGIN 33 | 34 | NS_ASSUME_NONNULL_BEGIN 35 | 36 | #pragma mark - GPBEmptyRoot 37 | 38 | /** 39 | * Exposes the extension registry for this file. 40 | * 41 | * The base class provides: 42 | * @code 43 | * + (GPBExtensionRegistry *)extensionRegistry; 44 | * @endcode 45 | * which is a @c GPBExtensionRegistry that includes all the extensions defined by 46 | * this file and all files that it depends on. 47 | **/ 48 | @interface GPBEmptyRoot : GPBRootObject 49 | @end 50 | 51 | #pragma mark - GPBEmpty 52 | 53 | /** 54 | * A generic empty message that you can re-use to avoid defining duplicated 55 | * empty messages in your APIs. A typical example is to use it as the request 56 | * or the response type of an API method. For instance: 57 | * 58 | * service Foo { 59 | * rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); 60 | * } 61 | * 62 | * The JSON representation for `Empty` is empty JSON object `{}`. 63 | **/ 64 | @interface GPBEmpty : GPBMessage 65 | 66 | @end 67 | 68 | NS_ASSUME_NONNULL_END 69 | 70 | CF_EXTERN_C_END 71 | 72 | #pragma clang diagnostic pop 73 | 74 | // @@protoc_insertion_point(global_scope) 75 | -------------------------------------------------------------------------------- /demo/WedprDemo/Wedpr/WedprScd.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | 6 | /** 7 | * C interface for 'wedpr_scd_blind_certificate_signature'. 8 | */ 9 | char *wedpr_scd_blind_certificate_signature(char *certificate_signature_cstring, 10 | char *attribute_dict_cstring, 11 | char *certificate_template_cstring, 12 | char *user_private_key_cstring, 13 | char *certificate_secrets_blinding_factors_cstring, 14 | char *issuer_nonce_cstring); 15 | 16 | /** 17 | * C interface for 'wedpr_scd_fill_certificate'. 18 | */ 19 | char *wedpr_scd_fill_certificate(char *attribute_dict_cstring, char *certificate_template_cstring); 20 | 21 | /** 22 | * C interface for 'wedpr_scd_get_revealed_attributes'. 23 | */ 24 | char *wedpr_scd_get_revealed_attributes(char *verify_request_cstring); 25 | 26 | /** 27 | * C interface for 'wedpr_scd_get_verification_nonce'. 28 | */ 29 | char *wedpr_scd_get_verification_nonce(void); 30 | 31 | /** 32 | * C interface for 'wedpr_scd_make_certificate_template'. 33 | */ 34 | char *wedpr_scd_make_certificate_template(char *schema_cstring); 35 | 36 | /** 37 | * C interface for 'wedpr_scd_prove_selective_disclosure'. 38 | */ 39 | char *wedpr_scd_prove_selective_disclosure(char *rule_set_cstring, 40 | char *certificate_signature_cstring, 41 | char *attribute_dict_cstring, 42 | char *certificate_template_cstring, 43 | char *user_private_key_cstring, 44 | char *verification_nonce_cstring); 45 | 46 | /** 47 | * C interface for 'wedpr_scd_sign_certificate'. 48 | */ 49 | char *wedpr_scd_sign_certificate(char *certificate_template_cstring, 50 | char *template_private_key_cstring, 51 | char *sign_request_cstring, 52 | char *user_id_cstring, 53 | char *user_nonce_cstring); 54 | 55 | /** 56 | * C interface for 'wedpr_scd_verify_selective_disclosure'. 57 | */ 58 | char *wedpr_scd_verify_selective_disclosure(char *rule_set_cstring, char *verify_request_cstring); 59 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/SourceContext.pbobjc.h: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/source_context.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #import 13 | #import 14 | #else 15 | #import "GPBDescriptor.h" 16 | #import "GPBMessage.h" 17 | #import "GPBRootObject.h" 18 | #endif 19 | 20 | #if GOOGLE_PROTOBUF_OBJC_VERSION < 30002 21 | #error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources. 22 | #endif 23 | #if 30002 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION 24 | #error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources. 25 | #endif 26 | 27 | // @@protoc_insertion_point(imports) 28 | 29 | #pragma clang diagnostic push 30 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 31 | 32 | CF_EXTERN_C_BEGIN 33 | 34 | NS_ASSUME_NONNULL_BEGIN 35 | 36 | #pragma mark - GPBSourceContextRoot 37 | 38 | /** 39 | * Exposes the extension registry for this file. 40 | * 41 | * The base class provides: 42 | * @code 43 | * + (GPBExtensionRegistry *)extensionRegistry; 44 | * @endcode 45 | * which is a @c GPBExtensionRegistry that includes all the extensions defined by 46 | * this file and all files that it depends on. 47 | **/ 48 | @interface GPBSourceContextRoot : GPBRootObject 49 | @end 50 | 51 | #pragma mark - GPBSourceContext 52 | 53 | typedef GPB_ENUM(GPBSourceContext_FieldNumber) { 54 | GPBSourceContext_FieldNumber_FileName = 1, 55 | }; 56 | 57 | /** 58 | * `SourceContext` represents information about the source of a 59 | * protobuf element, like the file in which it is defined. 60 | **/ 61 | @interface GPBSourceContext : GPBMessage 62 | 63 | /** 64 | * The path-qualified name of the .proto file that contained the associated 65 | * protobuf element. For example: `"google/protobuf/source_context.proto"`. 66 | **/ 67 | @property(nonatomic, readwrite, copy, null_resettable) NSString *fileName; 68 | 69 | @end 70 | 71 | NS_ASSUME_NONNULL_END 72 | 73 | CF_EXTERN_C_END 74 | 75 | #pragma clang diagnostic pop 76 | 77 | // @@protoc_insertion_point(global_scope) 78 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBExtensionInternals.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | #import "GPBDescriptor.h" 34 | 35 | @class GPBCodedInputStream; 36 | @class GPBCodedOutputStream; 37 | @class GPBExtensionRegistry; 38 | 39 | void GPBExtensionMergeFromInputStream(GPBExtensionDescriptor *extension, 40 | BOOL isPackedOnStream, 41 | GPBCodedInputStream *input, 42 | GPBExtensionRegistry *extensionRegistry, 43 | GPBMessage *message); 44 | 45 | size_t GPBComputeExtensionSerializedSizeIncludingTag( 46 | GPBExtensionDescriptor *extension, id value); 47 | 48 | void GPBWriteExtensionValueToOutputStream(GPBExtensionDescriptor *extension, 49 | id value, 50 | GPBCodedOutputStream *output); 51 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/comp.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef HEADER_COMP_H 3 | # define HEADER_COMP_H 4 | 5 | # include 6 | 7 | #ifdef __cplusplus 8 | extern "C" { 9 | #endif 10 | 11 | typedef struct comp_ctx_st COMP_CTX; 12 | 13 | typedef struct comp_method_st { 14 | int type; /* NID for compression library */ 15 | const char *name; /* A text string to identify the library */ 16 | int (*init) (COMP_CTX *ctx); 17 | void (*finish) (COMP_CTX *ctx); 18 | int (*compress) (COMP_CTX *ctx, 19 | unsigned char *out, unsigned int olen, 20 | unsigned char *in, unsigned int ilen); 21 | int (*expand) (COMP_CTX *ctx, 22 | unsigned char *out, unsigned int olen, 23 | unsigned char *in, unsigned int ilen); 24 | /* 25 | * The following two do NOTHING, but are kept for backward compatibility 26 | */ 27 | long (*ctrl) (void); 28 | long (*callback_ctrl) (void); 29 | } COMP_METHOD; 30 | 31 | struct comp_ctx_st { 32 | COMP_METHOD *meth; 33 | unsigned long compress_in; 34 | unsigned long compress_out; 35 | unsigned long expand_in; 36 | unsigned long expand_out; 37 | CRYPTO_EX_DATA ex_data; 38 | }; 39 | 40 | COMP_CTX *COMP_CTX_new(COMP_METHOD *meth); 41 | void COMP_CTX_free(COMP_CTX *ctx); 42 | int COMP_compress_block(COMP_CTX *ctx, unsigned char *out, int olen, 43 | unsigned char *in, int ilen); 44 | int COMP_expand_block(COMP_CTX *ctx, unsigned char *out, int olen, 45 | unsigned char *in, int ilen); 46 | COMP_METHOD *COMP_rle(void); 47 | COMP_METHOD *COMP_zlib(void); 48 | void COMP_zlib_cleanup(void); 49 | 50 | # ifdef HEADER_BIO_H 51 | # ifdef ZLIB 52 | BIO_METHOD *BIO_f_zlib(void); 53 | # endif 54 | # endif 55 | 56 | /* BEGIN ERROR CODES */ 57 | /* 58 | * The following lines are auto generated by the script mkerr.pl. Any changes 59 | * made after this point may be overwritten when the script is next run. 60 | */ 61 | void ERR_load_COMP_strings(void); 62 | 63 | /* Error codes for the COMP functions. */ 64 | 65 | /* Function codes. */ 66 | # define COMP_F_BIO_ZLIB_FLUSH 99 67 | # define COMP_F_BIO_ZLIB_NEW 100 68 | # define COMP_F_BIO_ZLIB_READ 101 69 | # define COMP_F_BIO_ZLIB_WRITE 102 70 | 71 | /* Reason codes. */ 72 | # define COMP_R_ZLIB_DEFLATE_ERROR 99 73 | # define COMP_R_ZLIB_INFLATE_ERROR 100 74 | # define COMP_R_ZLIB_NOT_SUPPORTED 101 75 | 76 | #ifdef __cplusplus 77 | } 78 | #endif 79 | #endif 80 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBUnknownFieldSet_PackagePrivate.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | #import "GPBUnknownFieldSet.h" 34 | 35 | @class GPBCodedOutputStream; 36 | @class GPBCodedInputStream; 37 | 38 | @interface GPBUnknownFieldSet () 39 | 40 | + (BOOL)isFieldTag:(int32_t)tag; 41 | 42 | - (NSData *)data; 43 | 44 | - (size_t)serializedSize; 45 | - (size_t)serializedSizeAsMessageSet; 46 | 47 | - (void)writeToCodedOutputStream:(GPBCodedOutputStream *)output; 48 | - (void)writeAsMessageSetTo:(GPBCodedOutputStream *)output; 49 | 50 | - (void)mergeUnknownFields:(GPBUnknownFieldSet *)other; 51 | 52 | - (void)mergeFromCodedInputStream:(GPBCodedInputStream *)input; 53 | - (void)mergeFromData:(NSData *)data; 54 | 55 | - (void)mergeVarintField:(int32_t)number value:(int32_t)value; 56 | - (BOOL)mergeFieldFrom:(int32_t)tag input:(GPBCodedInputStream *)input; 57 | - (void)mergeMessageSetMessage:(int32_t)number data:(NSData *)messageData; 58 | 59 | - (void)addUnknownMapEntry:(int32_t)fieldNum value:(NSData *)data; 60 | 61 | @end 62 | -------------------------------------------------------------------------------- /demo/WedprDemo/Hdk.pbobjc.h: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: hdk.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers.h" 14 | #endif 15 | 16 | #if GOOGLE_PROTOBUF_OBJC_VERSION < 30002 17 | #error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources. 18 | #endif 19 | #if 30002 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION 20 | #error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources. 21 | #endif 22 | 23 | // @@protoc_insertion_point(imports) 24 | 25 | #pragma clang diagnostic push 26 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 27 | 28 | CF_EXTERN_C_BEGIN 29 | 30 | @class ExtendedKeyPair; 31 | 32 | NS_ASSUME_NONNULL_BEGIN 33 | 34 | #pragma mark - HdkRoot 35 | 36 | /** 37 | * Exposes the extension registry for this file. 38 | * 39 | * The base class provides: 40 | * @code 41 | * + (GPBExtensionRegistry *)extensionRegistry; 42 | * @endcode 43 | * which is a @c GPBExtensionRegistry that includes all the extensions defined by 44 | * this file and all files that it depends on. 45 | **/ 46 | @interface HdkRoot : GPBRootObject 47 | @end 48 | 49 | #pragma mark - HdkResult 50 | 51 | typedef GPB_ENUM(HdkResult_FieldNumber) { 52 | HdkResult_FieldNumber_Mnemonic = 1, 53 | HdkResult_FieldNumber_MasterKey = 2, 54 | HdkResult_FieldNumber_KeyPair = 3, 55 | }; 56 | 57 | /** 58 | * Return data to FFI interface used by HDK. 59 | **/ 60 | @interface HdkResult : GPBMessage 61 | 62 | @property(nonatomic, readwrite, copy, null_resettable) NSString *mnemonic; 63 | 64 | @property(nonatomic, readwrite, copy, null_resettable) NSData *masterKey; 65 | 66 | @property(nonatomic, readwrite, strong, null_resettable) ExtendedKeyPair *keyPair; 67 | /** Test to see if @c keyPair has been set. */ 68 | @property(nonatomic, readwrite) BOOL hasKeyPair; 69 | 70 | @end 71 | 72 | #pragma mark - ExtendedKeyPair 73 | 74 | typedef GPB_ENUM(ExtendedKeyPair_FieldNumber) { 75 | ExtendedKeyPair_FieldNumber_ExtendedPrivateKey = 1, 76 | ExtendedKeyPair_FieldNumber_ExtendedPublicKey = 2, 77 | }; 78 | 79 | /** 80 | * Extended KeyPair. 81 | **/ 82 | @interface ExtendedKeyPair : GPBMessage 83 | 84 | @property(nonatomic, readwrite, copy, null_resettable) NSData *extendedPrivateKey; 85 | 86 | @property(nonatomic, readwrite, copy, null_resettable) NSData *extendedPublicKey; 87 | 88 | @end 89 | 90 | NS_ASSUME_NONNULL_END 91 | 92 | CF_EXTERN_C_END 93 | 94 | #pragma clang diagnostic pop 95 | 96 | // @@protoc_insertion_point(global_scope) 97 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/Empty.pbobjc.m: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/empty.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers_RuntimeSupport.h" 14 | #endif 15 | 16 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 17 | #import 18 | #else 19 | #import "google/protobuf/Empty.pbobjc.h" 20 | #endif 21 | // @@protoc_insertion_point(imports) 22 | 23 | #pragma clang diagnostic push 24 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 25 | 26 | #pragma mark - GPBEmptyRoot 27 | 28 | @implementation GPBEmptyRoot 29 | 30 | // No extensions in the file and no imports, so no need to generate 31 | // +extensionRegistry. 32 | 33 | @end 34 | 35 | #pragma mark - GPBEmptyRoot_FileDescriptor 36 | 37 | static GPBFileDescriptor *GPBEmptyRoot_FileDescriptor(void) { 38 | // This is called by +initialize so there is no need to worry 39 | // about thread safety of the singleton. 40 | static GPBFileDescriptor *descriptor = NULL; 41 | if (!descriptor) { 42 | GPB_DEBUG_CHECK_RUNTIME_VERSIONS(); 43 | descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"google.protobuf" 44 | objcPrefix:@"GPB" 45 | syntax:GPBFileSyntaxProto3]; 46 | } 47 | return descriptor; 48 | } 49 | 50 | #pragma mark - GPBEmpty 51 | 52 | @implementation GPBEmpty 53 | 54 | 55 | typedef struct GPBEmpty__storage_ { 56 | uint32_t _has_storage_[1]; 57 | } GPBEmpty__storage_; 58 | 59 | // This method is threadsafe because it is initially called 60 | // in +initialize for each subclass. 61 | + (GPBDescriptor *)descriptor { 62 | static GPBDescriptor *descriptor = nil; 63 | if (!descriptor) { 64 | GPBDescriptor *localDescriptor = 65 | [GPBDescriptor allocDescriptorForClass:[GPBEmpty class] 66 | rootClass:[GPBEmptyRoot class] 67 | file:GPBEmptyRoot_FileDescriptor() 68 | fields:NULL 69 | fieldCount:0 70 | storageSize:sizeof(GPBEmpty__storage_) 71 | flags:GPBDescriptorInitializationFlag_None]; 72 | #if defined(DEBUG) && DEBUG 73 | NSAssert(descriptor == nil, @"Startup recursed!"); 74 | #endif // DEBUG 75 | descriptor = localDescriptor; 76 | } 77 | return descriptor; 78 | } 79 | 80 | @end 81 | 82 | 83 | #pragma clang diagnostic pop 84 | 85 | // @@protoc_insertion_point(global_scope) 86 | -------------------------------------------------------------------------------- /demo/Pods/Target Support Files/Pods-WedprDemo/Pods-WedprDemo-acknowledgements.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreferenceSpecifiers 6 | 7 | 8 | FooterText 9 | This application makes use of the following third party libraries: 10 | Title 11 | Acknowledgements 12 | Type 13 | PSGroupSpecifier 14 | 15 | 16 | FooterText 17 | Copyright 2008 Google Inc. All rights reserved. 18 | 19 | Redistribution and use in source and binary forms, with or without 20 | modification, are permitted provided that the following conditions are 21 | met: 22 | 23 | * Redistributions of source code must retain the above copyright 24 | notice, this list of conditions and the following disclaimer. 25 | * Redistributions in binary form must reproduce the above 26 | copyright notice, this list of conditions and the following disclaimer 27 | in the documentation and/or other materials provided with the 28 | distribution. 29 | * Neither the name of Google Inc. nor the names of its 30 | contributors may be used to endorse or promote products derived from 31 | this software without specific prior written permission. 32 | 33 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 34 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 35 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 36 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 37 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 38 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 39 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 40 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 41 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 42 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 43 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 44 | 45 | Code generated by the Protocol Buffer compiler is owned by the owner 46 | of the input file used when generating it. This code is not 47 | standalone and requires a support library to be linked with it. This 48 | support library is itself covered by the above license. 49 | 50 | License 51 | 3-Clause BSD License 52 | Title 53 | Protobuf 54 | Type 55 | PSGroupSpecifier 56 | 57 | 58 | FooterText 59 | Generated by CocoaPods - https://cocoapods.org 60 | Title 61 | 62 | Type 63 | PSGroupSpecifier 64 | 65 | 66 | StringsTable 67 | Acknowledgements 68 | Title 69 | Acknowledgements 70 | 71 | 72 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/pem2.h: -------------------------------------------------------------------------------- 1 | /* ==================================================================== 2 | * Copyright (c) 1999 The OpenSSL Project. All rights reserved. 3 | * 4 | * Redistribution and use in source and binary forms, with or without 5 | * modification, are permitted provided that the following conditions 6 | * are met: 7 | * 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 11 | * 2. Redistributions in binary form must reproduce the above copyright 12 | * notice, this list of conditions and the following disclaimer in 13 | * the documentation and/or other materials provided with the 14 | * distribution. 15 | * 16 | * 3. All advertising materials mentioning features or use of this 17 | * software must display the following acknowledgment: 18 | * "This product includes software developed by the OpenSSL Project 19 | * for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)" 20 | * 21 | * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 22 | * endorse or promote products derived from this software without 23 | * prior written permission. For written permission, please contact 24 | * licensing@OpenSSL.org. 25 | * 26 | * 5. Products derived from this software may not be called "OpenSSL" 27 | * nor may "OpenSSL" appear in their names without prior written 28 | * permission of the OpenSSL Project. 29 | * 30 | * 6. Redistributions of any form whatsoever must retain the following 31 | * acknowledgment: 32 | * "This product includes software developed by the OpenSSL Project 33 | * for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)" 34 | * 35 | * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 36 | * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 37 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 38 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 39 | * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 40 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 41 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 42 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 43 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 44 | * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 45 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 46 | * OF THE POSSIBILITY OF SUCH DAMAGE. 47 | * ==================================================================== 48 | * 49 | * This product includes cryptographic software written by Eric Young 50 | * (eay@cryptsoft.com). This product includes software written by Tim 51 | * Hudson (tjh@cryptsoft.com). 52 | * 53 | */ 54 | 55 | /* 56 | * This header only exists to break a circular dependency between pem and err 57 | * Ben 30 Jan 1999. 58 | */ 59 | 60 | #ifdef __cplusplus 61 | extern "C" { 62 | #endif 63 | 64 | #ifndef HEADER_PEM_H 65 | void ERR_load_PEM_strings(void); 66 | #endif 67 | 68 | #ifdef __cplusplus 69 | } 70 | #endif 71 | -------------------------------------------------------------------------------- /demo/WedprDemo.xcodeproj/xcshareddata/xcschemes/WedprDemo.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 45 | 51 | 52 | 53 | 54 | 60 | 62 | 68 | 69 | 70 | 71 | 73 | 74 | 77 | 78 | 79 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBUnknownFieldSet.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | @class GPBUnknownField; 34 | 35 | NS_ASSUME_NONNULL_BEGIN 36 | 37 | /** 38 | * A collection of unknown fields. Fields parsed from the binary representation 39 | * of a message that are unknown end up in an instance of this set. This only 40 | * applies for files declared with the "proto2" syntax. Files declared with the 41 | * "proto3" syntax discard the unknown values. 42 | **/ 43 | @interface GPBUnknownFieldSet : NSObject 44 | 45 | /** 46 | * Tests to see if the given field number has a value. 47 | * 48 | * @param number The field number to check. 49 | * 50 | * @return YES if there is an unknown field for the given field number. 51 | **/ 52 | - (BOOL)hasField:(int32_t)number; 53 | 54 | /** 55 | * Fetches the GPBUnknownField for the given field number. 56 | * 57 | * @param number The field number to look up. 58 | * 59 | * @return The GPBUnknownField or nil if none found. 60 | **/ 61 | - (nullable GPBUnknownField *)getField:(int32_t)number; 62 | 63 | /** 64 | * @return The number of fields in this set. 65 | **/ 66 | - (NSUInteger)countOfFields; 67 | 68 | /** 69 | * Adds the given field to the set. 70 | * 71 | * @param field The field to add to the set. 72 | **/ 73 | - (void)addField:(GPBUnknownField *)field; 74 | 75 | /** 76 | * @return An array of the GPBUnknownFields sorted by the field numbers. 77 | **/ 78 | - (NSArray *)sortedFields; 79 | 80 | @end 81 | 82 | NS_ASSUME_NONNULL_END 83 | -------------------------------------------------------------------------------- /demo/WedprDemo/Vcl.pbobjc.h: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: vcl.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers.h" 14 | #endif 15 | 16 | #if GOOGLE_PROTOBUF_OBJC_VERSION < 30002 17 | #error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources. 18 | #endif 19 | #if 30002 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION 20 | #error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources. 21 | #endif 22 | 23 | // @@protoc_insertion_point(imports) 24 | 25 | #pragma clang diagnostic push 26 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 27 | 28 | CF_EXTERN_C_BEGIN 29 | 30 | NS_ASSUME_NONNULL_BEGIN 31 | 32 | #pragma mark - VclRoot 33 | 34 | /** 35 | * Exposes the extension registry for this file. 36 | * 37 | * The base class provides: 38 | * @code 39 | * + (GPBExtensionRegistry *)extensionRegistry; 40 | * @endcode 41 | * which is a @c GPBExtensionRegistry that includes all the extensions defined by 42 | * this file and all files that it depends on. 43 | **/ 44 | @interface VclRoot : GPBRootObject 45 | @end 46 | 47 | #pragma mark - EncodedOwnerSecret 48 | 49 | typedef GPB_ENUM(EncodedOwnerSecret_FieldNumber) { 50 | EncodedOwnerSecret_FieldNumber_CreditValue = 1, 51 | EncodedOwnerSecret_FieldNumber_SecretBlinding = 2, 52 | }; 53 | 54 | /** 55 | * Encoded data to represent a owner secret used by VCL solution. 56 | **/ 57 | @interface EncodedOwnerSecret : GPBMessage 58 | 59 | @property(nonatomic, readwrite) int64_t creditValue; 60 | 61 | @property(nonatomic, readwrite, copy, null_resettable) NSString *secretBlinding; 62 | 63 | @end 64 | 65 | #pragma mark - EncodedConfidentialCredit 66 | 67 | typedef GPB_ENUM(EncodedConfidentialCredit_FieldNumber) { 68 | EncodedConfidentialCredit_FieldNumber_Point = 1, 69 | }; 70 | 71 | /** 72 | * Encoded data to represent a confidential credit used by VCL solution. 73 | **/ 74 | @interface EncodedConfidentialCredit : GPBMessage 75 | 76 | @property(nonatomic, readwrite, copy, null_resettable) NSString *point; 77 | 78 | @end 79 | 80 | #pragma mark - VclResult 81 | 82 | typedef GPB_ENUM(VclResult_FieldNumber) { 83 | VclResult_FieldNumber_Credit = 1, 84 | VclResult_FieldNumber_Secret = 2, 85 | VclResult_FieldNumber_Proof = 3, 86 | }; 87 | 88 | /** 89 | * Return data to FFI C interface 90 | **/ 91 | @interface VclResult : GPBMessage 92 | 93 | @property(nonatomic, readwrite, copy, null_resettable) NSString *credit; 94 | 95 | @property(nonatomic, readwrite, copy, null_resettable) NSString *secret; 96 | 97 | @property(nonatomic, readwrite, copy, null_resettable) NSString *proof; 98 | 99 | @end 100 | 101 | NS_ASSUME_NONNULL_END 102 | 103 | CF_EXTERN_C_END 104 | 105 | #pragma clang diagnostic pop 106 | 107 | // @@protoc_insertion_point(global_scope) 108 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBWireFormat.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import "GPBRuntimeTypes.h" 32 | 33 | CF_EXTERN_C_BEGIN 34 | 35 | NS_ASSUME_NONNULL_BEGIN 36 | 37 | typedef enum { 38 | GPBWireFormatVarint = 0, 39 | GPBWireFormatFixed64 = 1, 40 | GPBWireFormatLengthDelimited = 2, 41 | GPBWireFormatStartGroup = 3, 42 | GPBWireFormatEndGroup = 4, 43 | GPBWireFormatFixed32 = 5, 44 | } GPBWireFormat; 45 | 46 | enum { 47 | GPBWireFormatMessageSetItem = 1, 48 | GPBWireFormatMessageSetTypeId = 2, 49 | GPBWireFormatMessageSetMessage = 3 50 | }; 51 | 52 | uint32_t GPBWireFormatMakeTag(uint32_t fieldNumber, GPBWireFormat wireType) 53 | __attribute__((const)); 54 | GPBWireFormat GPBWireFormatGetTagWireType(uint32_t tag) __attribute__((const)); 55 | uint32_t GPBWireFormatGetTagFieldNumber(uint32_t tag) __attribute__((const)); 56 | BOOL GPBWireFormatIsValidTag(uint32_t tag) __attribute__((const)); 57 | 58 | GPBWireFormat GPBWireFormatForType(GPBDataType dataType, BOOL isPacked) 59 | __attribute__((const)); 60 | 61 | #define GPBWireFormatMessageSetItemTag \ 62 | (GPBWireFormatMakeTag(GPBWireFormatMessageSetItem, GPBWireFormatStartGroup)) 63 | #define GPBWireFormatMessageSetItemEndTag \ 64 | (GPBWireFormatMakeTag(GPBWireFormatMessageSetItem, GPBWireFormatEndGroup)) 65 | #define GPBWireFormatMessageSetTypeIdTag \ 66 | (GPBWireFormatMakeTag(GPBWireFormatMessageSetTypeId, GPBWireFormatVarint)) 67 | #define GPBWireFormatMessageSetMessageTag \ 68 | (GPBWireFormatMakeTag(GPBWireFormatMessageSetMessage, \ 69 | GPBWireFormatLengthDelimited)) 70 | 71 | NS_ASSUME_NONNULL_END 72 | 73 | CF_EXTERN_C_END 74 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBProtocolBuffers.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import "GPBBootstrap.h" 32 | 33 | #import "GPBArray.h" 34 | #import "GPBCodedInputStream.h" 35 | #import "GPBCodedOutputStream.h" 36 | #import "GPBDescriptor.h" 37 | #import "GPBDictionary.h" 38 | #import "GPBExtensionRegistry.h" 39 | #import "GPBMessage.h" 40 | #import "GPBRootObject.h" 41 | #import "GPBUnknownField.h" 42 | #import "GPBUnknownFieldSet.h" 43 | #import "GPBUtilities.h" 44 | #import "GPBWellKnownTypes.h" 45 | #import "GPBWireFormat.h" 46 | 47 | // This CPP symbol can be defined to use imports that match up to the framework 48 | // imports needed when using CocoaPods. 49 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 50 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 51 | #endif 52 | 53 | // Well-known proto types 54 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 55 | #import 56 | #import 57 | #import 58 | #import 59 | #import 60 | #import 61 | #import 62 | #import 63 | #import 64 | #import 65 | #else 66 | #import "google/protobuf/Any.pbobjc.h" 67 | #import "google/protobuf/Api.pbobjc.h" 68 | #import "google/protobuf/Duration.pbobjc.h" 69 | #import "google/protobuf/Empty.pbobjc.h" 70 | #import "google/protobuf/FieldMask.pbobjc.h" 71 | #import "google/protobuf/SourceContext.pbobjc.h" 72 | #import "google/protobuf/Struct.pbobjc.h" 73 | #import "google/protobuf/Timestamp.pbobjc.h" 74 | #import "google/protobuf/Type.pbobjc.h" 75 | #import "google/protobuf/Wrappers.pbobjc.h" 76 | #endif 77 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/FieldMask.pbobjc.m: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/field_mask.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers_RuntimeSupport.h" 14 | #endif 15 | 16 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 17 | #import 18 | #else 19 | #import "google/protobuf/FieldMask.pbobjc.h" 20 | #endif 21 | // @@protoc_insertion_point(imports) 22 | 23 | #pragma clang diagnostic push 24 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 25 | 26 | #pragma mark - GPBFieldMaskRoot 27 | 28 | @implementation GPBFieldMaskRoot 29 | 30 | // No extensions in the file and no imports, so no need to generate 31 | // +extensionRegistry. 32 | 33 | @end 34 | 35 | #pragma mark - GPBFieldMaskRoot_FileDescriptor 36 | 37 | static GPBFileDescriptor *GPBFieldMaskRoot_FileDescriptor(void) { 38 | // This is called by +initialize so there is no need to worry 39 | // about thread safety of the singleton. 40 | static GPBFileDescriptor *descriptor = NULL; 41 | if (!descriptor) { 42 | GPB_DEBUG_CHECK_RUNTIME_VERSIONS(); 43 | descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"google.protobuf" 44 | objcPrefix:@"GPB" 45 | syntax:GPBFileSyntaxProto3]; 46 | } 47 | return descriptor; 48 | } 49 | 50 | #pragma mark - GPBFieldMask 51 | 52 | @implementation GPBFieldMask 53 | 54 | @dynamic pathsArray, pathsArray_Count; 55 | 56 | typedef struct GPBFieldMask__storage_ { 57 | uint32_t _has_storage_[1]; 58 | NSMutableArray *pathsArray; 59 | } GPBFieldMask__storage_; 60 | 61 | // This method is threadsafe because it is initially called 62 | // in +initialize for each subclass. 63 | + (GPBDescriptor *)descriptor { 64 | static GPBDescriptor *descriptor = nil; 65 | if (!descriptor) { 66 | static GPBMessageFieldDescription fields[] = { 67 | { 68 | .name = "pathsArray", 69 | .dataTypeSpecific.className = NULL, 70 | .number = GPBFieldMask_FieldNumber_PathsArray, 71 | .hasIndex = GPBNoHasBit, 72 | .offset = (uint32_t)offsetof(GPBFieldMask__storage_, pathsArray), 73 | .flags = GPBFieldRepeated, 74 | .dataType = GPBDataTypeString, 75 | }, 76 | }; 77 | GPBDescriptor *localDescriptor = 78 | [GPBDescriptor allocDescriptorForClass:[GPBFieldMask class] 79 | rootClass:[GPBFieldMaskRoot class] 80 | file:GPBFieldMaskRoot_FileDescriptor() 81 | fields:fields 82 | fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription)) 83 | storageSize:sizeof(GPBFieldMask__storage_) 84 | flags:GPBDescriptorInitializationFlag_None]; 85 | #if defined(DEBUG) && DEBUG 86 | NSAssert(descriptor == nil, @"Startup recursed!"); 87 | #endif // DEBUG 88 | descriptor = localDescriptor; 89 | } 90 | return descriptor; 91 | } 92 | 93 | @end 94 | 95 | 96 | #pragma clang diagnostic pop 97 | 98 | // @@protoc_insertion_point(global_scope) 99 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/cmac.h: -------------------------------------------------------------------------------- 1 | /* crypto/cmac/cmac.h */ 2 | /* 3 | * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL 4 | * project. 5 | */ 6 | /* ==================================================================== 7 | * Copyright (c) 2010 The OpenSSL Project. All rights reserved. 8 | * 9 | * Redistribution and use in source and binary forms, with or without 10 | * modification, are permitted provided that the following conditions 11 | * are met: 12 | * 13 | * 1. Redistributions of source code must retain the above copyright 14 | * notice, this list of conditions and the following disclaimer. 15 | * 16 | * 2. Redistributions in binary form must reproduce the above copyright 17 | * notice, this list of conditions and the following disclaimer in 18 | * the documentation and/or other materials provided with the 19 | * distribution. 20 | * 21 | * 3. All advertising materials mentioning features or use of this 22 | * software must display the following acknowledgment: 23 | * "This product includes software developed by the OpenSSL Project 24 | * for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)" 25 | * 26 | * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 27 | * endorse or promote products derived from this software without 28 | * prior written permission. For written permission, please contact 29 | * licensing@OpenSSL.org. 30 | * 31 | * 5. Products derived from this software may not be called "OpenSSL" 32 | * nor may "OpenSSL" appear in their names without prior written 33 | * permission of the OpenSSL Project. 34 | * 35 | * 6. Redistributions of any form whatsoever must retain the following 36 | * acknowledgment: 37 | * "This product includes software developed by the OpenSSL Project 38 | * for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)" 39 | * 40 | * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 41 | * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 42 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 43 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 44 | * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 45 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 46 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 47 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 49 | * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 50 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 51 | * OF THE POSSIBILITY OF SUCH DAMAGE. 52 | * ==================================================================== 53 | */ 54 | 55 | #ifndef HEADER_CMAC_H 56 | # define HEADER_CMAC_H 57 | 58 | #ifdef __cplusplus 59 | extern "C" { 60 | #endif 61 | 62 | # include 63 | 64 | /* Opaque */ 65 | typedef struct CMAC_CTX_st CMAC_CTX; 66 | 67 | CMAC_CTX *CMAC_CTX_new(void); 68 | void CMAC_CTX_cleanup(CMAC_CTX *ctx); 69 | void CMAC_CTX_free(CMAC_CTX *ctx); 70 | EVP_CIPHER_CTX *CMAC_CTX_get0_cipher_ctx(CMAC_CTX *ctx); 71 | int CMAC_CTX_copy(CMAC_CTX *out, const CMAC_CTX *in); 72 | 73 | int CMAC_Init(CMAC_CTX *ctx, const void *key, size_t keylen, 74 | const EVP_CIPHER *cipher, ENGINE *impl); 75 | int CMAC_Update(CMAC_CTX *ctx, const void *data, size_t dlen); 76 | int CMAC_Final(CMAC_CTX *ctx, unsigned char *out, size_t *poutlen); 77 | int CMAC_resume(CMAC_CTX *ctx); 78 | 79 | #ifdef __cplusplus 80 | } 81 | #endif 82 | #endif 83 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/SourceContext.pbobjc.m: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/source_context.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers_RuntimeSupport.h" 14 | #endif 15 | 16 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 17 | #import 18 | #else 19 | #import "google/protobuf/SourceContext.pbobjc.h" 20 | #endif 21 | // @@protoc_insertion_point(imports) 22 | 23 | #pragma clang diagnostic push 24 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 25 | 26 | #pragma mark - GPBSourceContextRoot 27 | 28 | @implementation GPBSourceContextRoot 29 | 30 | // No extensions in the file and no imports, so no need to generate 31 | // +extensionRegistry. 32 | 33 | @end 34 | 35 | #pragma mark - GPBSourceContextRoot_FileDescriptor 36 | 37 | static GPBFileDescriptor *GPBSourceContextRoot_FileDescriptor(void) { 38 | // This is called by +initialize so there is no need to worry 39 | // about thread safety of the singleton. 40 | static GPBFileDescriptor *descriptor = NULL; 41 | if (!descriptor) { 42 | GPB_DEBUG_CHECK_RUNTIME_VERSIONS(); 43 | descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"google.protobuf" 44 | objcPrefix:@"GPB" 45 | syntax:GPBFileSyntaxProto3]; 46 | } 47 | return descriptor; 48 | } 49 | 50 | #pragma mark - GPBSourceContext 51 | 52 | @implementation GPBSourceContext 53 | 54 | @dynamic fileName; 55 | 56 | typedef struct GPBSourceContext__storage_ { 57 | uint32_t _has_storage_[1]; 58 | NSString *fileName; 59 | } GPBSourceContext__storage_; 60 | 61 | // This method is threadsafe because it is initially called 62 | // in +initialize for each subclass. 63 | + (GPBDescriptor *)descriptor { 64 | static GPBDescriptor *descriptor = nil; 65 | if (!descriptor) { 66 | static GPBMessageFieldDescription fields[] = { 67 | { 68 | .name = "fileName", 69 | .dataTypeSpecific.className = NULL, 70 | .number = GPBSourceContext_FieldNumber_FileName, 71 | .hasIndex = 0, 72 | .offset = (uint32_t)offsetof(GPBSourceContext__storage_, fileName), 73 | .flags = GPBFieldOptional, 74 | .dataType = GPBDataTypeString, 75 | }, 76 | }; 77 | GPBDescriptor *localDescriptor = 78 | [GPBDescriptor allocDescriptorForClass:[GPBSourceContext class] 79 | rootClass:[GPBSourceContextRoot class] 80 | file:GPBSourceContextRoot_FileDescriptor() 81 | fields:fields 82 | fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription)) 83 | storageSize:sizeof(GPBSourceContext__storage_) 84 | flags:GPBDescriptorInitializationFlag_None]; 85 | #if defined(DEBUG) && DEBUG 86 | NSAssert(descriptor == nil, @"Startup recursed!"); 87 | #endif // DEBUG 88 | descriptor = localDescriptor; 89 | } 90 | return descriptor; 91 | } 92 | 93 | @end 94 | 95 | 96 | #pragma clang diagnostic pop 97 | 98 | // @@protoc_insertion_point(global_scope) 99 | -------------------------------------------------------------------------------- /demo/WedprDemo/Common.pbobjc.m: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: common.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers_RuntimeSupport.h" 14 | #endif 15 | 16 | #import "Common.pbobjc.h" 17 | // @@protoc_insertion_point(imports) 18 | 19 | #pragma clang diagnostic push 20 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 21 | 22 | #pragma mark - CommonRoot 23 | 24 | @implementation CommonRoot 25 | 26 | // No extensions in the file and no imports, so no need to generate 27 | // +extensionRegistry. 28 | 29 | @end 30 | 31 | #pragma mark - CommonRoot_FileDescriptor 32 | 33 | static GPBFileDescriptor *CommonRoot_FileDescriptor(void) { 34 | // This is called by +initialize so there is no need to worry 35 | // about thread safety of the singleton. 36 | static GPBFileDescriptor *descriptor = NULL; 37 | if (!descriptor) { 38 | GPB_DEBUG_CHECK_RUNTIME_VERSIONS(); 39 | descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"com.webank.wedpr.crypto.proto" 40 | syntax:GPBFileSyntaxProto3]; 41 | } 42 | return descriptor; 43 | } 44 | 45 | #pragma mark - Keypair 46 | 47 | @implementation Keypair 48 | 49 | @dynamic publicKey; 50 | @dynamic privateKey; 51 | 52 | typedef struct Keypair__storage_ { 53 | uint32_t _has_storage_[1]; 54 | NSString *publicKey; 55 | NSString *privateKey; 56 | } Keypair__storage_; 57 | 58 | // This method is threadsafe because it is initially called 59 | // in +initialize for each subclass. 60 | + (GPBDescriptor *)descriptor { 61 | static GPBDescriptor *descriptor = nil; 62 | if (!descriptor) { 63 | static GPBMessageFieldDescription fields[] = { 64 | { 65 | .name = "publicKey", 66 | .dataTypeSpecific.className = NULL, 67 | .number = Keypair_FieldNumber_PublicKey, 68 | .hasIndex = 0, 69 | .offset = (uint32_t)offsetof(Keypair__storage_, publicKey), 70 | .flags = GPBFieldOptional, 71 | .dataType = GPBDataTypeString, 72 | }, 73 | { 74 | .name = "privateKey", 75 | .dataTypeSpecific.className = NULL, 76 | .number = Keypair_FieldNumber_PrivateKey, 77 | .hasIndex = 1, 78 | .offset = (uint32_t)offsetof(Keypair__storage_, privateKey), 79 | .flags = GPBFieldOptional, 80 | .dataType = GPBDataTypeString, 81 | }, 82 | }; 83 | GPBDescriptor *localDescriptor = 84 | [GPBDescriptor allocDescriptorForClass:[Keypair class] 85 | rootClass:[CommonRoot class] 86 | file:CommonRoot_FileDescriptor() 87 | fields:fields 88 | fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription)) 89 | storageSize:sizeof(Keypair__storage_) 90 | flags:GPBDescriptorInitializationFlag_None]; 91 | #if defined(DEBUG) && DEBUG 92 | NSAssert(descriptor == nil, @"Startup recursed!"); 93 | #endif // DEBUG 94 | descriptor = localDescriptor; 95 | } 96 | return descriptor; 97 | } 98 | 99 | @end 100 | 101 | 102 | #pragma clang diagnostic pop 103 | 104 | // @@protoc_insertion_point(global_scope) 105 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/ui_compat.h: -------------------------------------------------------------------------------- 1 | /* crypto/ui/ui.h */ 2 | /* 3 | * Written by Richard Levitte (richard@levitte.org) for the OpenSSL project 4 | * 2001. 5 | */ 6 | /* ==================================================================== 7 | * Copyright (c) 2001 The OpenSSL Project. All rights reserved. 8 | * 9 | * Redistribution and use in source and binary forms, with or without 10 | * modification, are permitted provided that the following conditions 11 | * are met: 12 | * 13 | * 1. Redistributions of source code must retain the above copyright 14 | * notice, this list of conditions and the following disclaimer. 15 | * 16 | * 2. Redistributions in binary form must reproduce the above copyright 17 | * notice, this list of conditions and the following disclaimer in 18 | * the documentation and/or other materials provided with the 19 | * distribution. 20 | * 21 | * 3. All advertising materials mentioning features or use of this 22 | * software must display the following acknowledgment: 23 | * "This product includes software developed by the OpenSSL Project 24 | * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" 25 | * 26 | * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 27 | * endorse or promote products derived from this software without 28 | * prior written permission. For written permission, please contact 29 | * openssl-core@openssl.org. 30 | * 31 | * 5. Products derived from this software may not be called "OpenSSL" 32 | * nor may "OpenSSL" appear in their names without prior written 33 | * permission of the OpenSSL Project. 34 | * 35 | * 6. Redistributions of any form whatsoever must retain the following 36 | * acknowledgment: 37 | * "This product includes software developed by the OpenSSL Project 38 | * for use in the OpenSSL Toolkit (http://www.openssl.org/)" 39 | * 40 | * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 41 | * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 42 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 43 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 44 | * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 45 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 46 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 47 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 49 | * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 50 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 51 | * OF THE POSSIBILITY OF SUCH DAMAGE. 52 | * ==================================================================== 53 | * 54 | * This product includes cryptographic software written by Eric Young 55 | * (eay@cryptsoft.com). This product includes software written by Tim 56 | * Hudson (tjh@cryptsoft.com). 57 | * 58 | */ 59 | 60 | #ifndef HEADER_UI_COMPAT_H 61 | # define HEADER_UI_COMPAT_H 62 | 63 | # include 64 | # include 65 | 66 | #ifdef __cplusplus 67 | extern "C" { 68 | #endif 69 | 70 | /* 71 | * The following functions were previously part of the DES section, and are 72 | * provided here for backward compatibility reasons. 73 | */ 74 | 75 | # define des_read_pw_string(b,l,p,v) \ 76 | _ossl_old_des_read_pw_string((b),(l),(p),(v)) 77 | # define des_read_pw(b,bf,s,p,v) \ 78 | _ossl_old_des_read_pw((b),(bf),(s),(p),(v)) 79 | 80 | int _ossl_old_des_read_pw_string(char *buf, int length, const char *prompt, 81 | int verify); 82 | int _ossl_old_des_read_pw(char *buf, char *buff, int size, const char *prompt, 83 | int verify); 84 | 85 | #ifdef __cplusplus 86 | } 87 | #endif 88 | #endif 89 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBUnknownField.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | @class GPBCodedOutputStream; 34 | @class GPBUInt32Array; 35 | @class GPBUInt64Array; 36 | @class GPBUnknownFieldSet; 37 | 38 | NS_ASSUME_NONNULL_BEGIN 39 | /** 40 | * Store an unknown field. These are used in conjunction with 41 | * GPBUnknownFieldSet. 42 | **/ 43 | @interface GPBUnknownField : NSObject 44 | 45 | /** Initialize a field with the given number. */ 46 | - (instancetype)initWithNumber:(int32_t)number; 47 | 48 | /** The field number the data is stored under. */ 49 | @property(nonatomic, readonly, assign) int32_t number; 50 | 51 | /** An array of varint values for this field. */ 52 | @property(nonatomic, readonly, strong) GPBUInt64Array *varintList; 53 | 54 | /** An array of fixed32 values for this field. */ 55 | @property(nonatomic, readonly, strong) GPBUInt32Array *fixed32List; 56 | 57 | /** An array of fixed64 values for this field. */ 58 | @property(nonatomic, readonly, strong) GPBUInt64Array *fixed64List; 59 | 60 | /** An array of data values for this field. */ 61 | @property(nonatomic, readonly, strong) NSArray *lengthDelimitedList; 62 | 63 | /** An array of groups of values for this field. */ 64 | @property(nonatomic, readonly, strong) NSArray *groupList; 65 | 66 | /** 67 | * Add a value to the varintList. 68 | * 69 | * @param value The value to add. 70 | **/ 71 | - (void)addVarint:(uint64_t)value; 72 | /** 73 | * Add a value to the fixed32List. 74 | * 75 | * @param value The value to add. 76 | **/ 77 | - (void)addFixed32:(uint32_t)value; 78 | /** 79 | * Add a value to the fixed64List. 80 | * 81 | * @param value The value to add. 82 | **/ 83 | - (void)addFixed64:(uint64_t)value; 84 | /** 85 | * Add a value to the lengthDelimitedList. 86 | * 87 | * @param value The value to add. 88 | **/ 89 | - (void)addLengthDelimited:(NSData *)value; 90 | /** 91 | * Add a value to the groupList. 92 | * 93 | * @param value The value to add. 94 | **/ 95 | - (void)addGroup:(GPBUnknownFieldSet *)value; 96 | 97 | @end 98 | 99 | NS_ASSUME_NONNULL_END 100 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/Duration.pbobjc.m: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/duration.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers_RuntimeSupport.h" 14 | #endif 15 | 16 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 17 | #import 18 | #else 19 | #import "google/protobuf/Duration.pbobjc.h" 20 | #endif 21 | // @@protoc_insertion_point(imports) 22 | 23 | #pragma clang diagnostic push 24 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 25 | 26 | #pragma mark - GPBDurationRoot 27 | 28 | @implementation GPBDurationRoot 29 | 30 | // No extensions in the file and no imports, so no need to generate 31 | // +extensionRegistry. 32 | 33 | @end 34 | 35 | #pragma mark - GPBDurationRoot_FileDescriptor 36 | 37 | static GPBFileDescriptor *GPBDurationRoot_FileDescriptor(void) { 38 | // This is called by +initialize so there is no need to worry 39 | // about thread safety of the singleton. 40 | static GPBFileDescriptor *descriptor = NULL; 41 | if (!descriptor) { 42 | GPB_DEBUG_CHECK_RUNTIME_VERSIONS(); 43 | descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"google.protobuf" 44 | objcPrefix:@"GPB" 45 | syntax:GPBFileSyntaxProto3]; 46 | } 47 | return descriptor; 48 | } 49 | 50 | #pragma mark - GPBDuration 51 | 52 | @implementation GPBDuration 53 | 54 | @dynamic seconds; 55 | @dynamic nanos; 56 | 57 | typedef struct GPBDuration__storage_ { 58 | uint32_t _has_storage_[1]; 59 | int32_t nanos; 60 | int64_t seconds; 61 | } GPBDuration__storage_; 62 | 63 | // This method is threadsafe because it is initially called 64 | // in +initialize for each subclass. 65 | + (GPBDescriptor *)descriptor { 66 | static GPBDescriptor *descriptor = nil; 67 | if (!descriptor) { 68 | static GPBMessageFieldDescription fields[] = { 69 | { 70 | .name = "seconds", 71 | .dataTypeSpecific.className = NULL, 72 | .number = GPBDuration_FieldNumber_Seconds, 73 | .hasIndex = 0, 74 | .offset = (uint32_t)offsetof(GPBDuration__storage_, seconds), 75 | .flags = GPBFieldOptional, 76 | .dataType = GPBDataTypeInt64, 77 | }, 78 | { 79 | .name = "nanos", 80 | .dataTypeSpecific.className = NULL, 81 | .number = GPBDuration_FieldNumber_Nanos, 82 | .hasIndex = 1, 83 | .offset = (uint32_t)offsetof(GPBDuration__storage_, nanos), 84 | .flags = GPBFieldOptional, 85 | .dataType = GPBDataTypeInt32, 86 | }, 87 | }; 88 | GPBDescriptor *localDescriptor = 89 | [GPBDescriptor allocDescriptorForClass:[GPBDuration class] 90 | rootClass:[GPBDurationRoot class] 91 | file:GPBDurationRoot_FileDescriptor() 92 | fields:fields 93 | fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription)) 94 | storageSize:sizeof(GPBDuration__storage_) 95 | flags:GPBDescriptorInitializationFlag_None]; 96 | #if defined(DEBUG) && DEBUG 97 | NSAssert(descriptor == nil, @"Startup recursed!"); 98 | #endif // DEBUG 99 | descriptor = localDescriptor; 100 | } 101 | return descriptor; 102 | } 103 | 104 | @end 105 | 106 | 107 | #pragma clang diagnostic pop 108 | 109 | // @@protoc_insertion_point(global_scope) 110 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBExtensionRegistry.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import 32 | 33 | @class GPBDescriptor; 34 | @class GPBExtensionDescriptor; 35 | 36 | NS_ASSUME_NONNULL_BEGIN 37 | 38 | /** 39 | * A table of known extensions, searchable by name or field number. When 40 | * parsing a protocol message that might have extensions, you must provide a 41 | * GPBExtensionRegistry in which you have registered any extensions that you 42 | * want to be able to parse. Otherwise, those extensions will just be treated 43 | * like unknown fields. 44 | * 45 | * The *Root classes provide `+extensionRegistry` for the extensions defined 46 | * in a given file *and* all files it imports. You can also create a 47 | * GPBExtensionRegistry, and merge those registries to handle parsing 48 | * extensions defined from non overlapping files. 49 | * 50 | * ``` 51 | * GPBExtensionRegistry *registry = [[MyProtoFileRoot extensionRegistry] copy]; 52 | * [registry addExtension:[OtherMessage neededExtension]]; // Not in MyProtoFile 53 | * NSError *parseError; 54 | * MyMessage *msg = [MyMessage parseData:data extensionRegistry:registry error:&parseError]; 55 | * ``` 56 | **/ 57 | @interface GPBExtensionRegistry : NSObject 58 | 59 | /** 60 | * Adds the given GPBExtensionDescriptor to this registry. 61 | * 62 | * @param extension The extension description to add. 63 | **/ 64 | - (void)addExtension:(GPBExtensionDescriptor *)extension; 65 | 66 | /** 67 | * Adds all the extensions from another registry to this registry. 68 | * 69 | * @param registry The registry to merge into this registry. 70 | **/ 71 | - (void)addExtensions:(GPBExtensionRegistry *)registry; 72 | 73 | /** 74 | * Looks for the extension registered for the given field number on a given 75 | * GPBDescriptor. 76 | * 77 | * @param descriptor The descriptor to look for a registered extension on. 78 | * @param fieldNumber The field number of the extension to look for. 79 | * 80 | * @return The registered GPBExtensionDescriptor or nil if none was found. 81 | **/ 82 | - (nullable GPBExtensionDescriptor *)extensionForDescriptor:(GPBDescriptor *)descriptor 83 | fieldNumber:(NSInteger)fieldNumber; 84 | 85 | @end 86 | 87 | NS_ASSUME_NONNULL_END 88 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/Timestamp.pbobjc.m: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/timestamp.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers_RuntimeSupport.h" 14 | #endif 15 | 16 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 17 | #import 18 | #else 19 | #import "google/protobuf/Timestamp.pbobjc.h" 20 | #endif 21 | // @@protoc_insertion_point(imports) 22 | 23 | #pragma clang diagnostic push 24 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 25 | 26 | #pragma mark - GPBTimestampRoot 27 | 28 | @implementation GPBTimestampRoot 29 | 30 | // No extensions in the file and no imports, so no need to generate 31 | // +extensionRegistry. 32 | 33 | @end 34 | 35 | #pragma mark - GPBTimestampRoot_FileDescriptor 36 | 37 | static GPBFileDescriptor *GPBTimestampRoot_FileDescriptor(void) { 38 | // This is called by +initialize so there is no need to worry 39 | // about thread safety of the singleton. 40 | static GPBFileDescriptor *descriptor = NULL; 41 | if (!descriptor) { 42 | GPB_DEBUG_CHECK_RUNTIME_VERSIONS(); 43 | descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"google.protobuf" 44 | objcPrefix:@"GPB" 45 | syntax:GPBFileSyntaxProto3]; 46 | } 47 | return descriptor; 48 | } 49 | 50 | #pragma mark - GPBTimestamp 51 | 52 | @implementation GPBTimestamp 53 | 54 | @dynamic seconds; 55 | @dynamic nanos; 56 | 57 | typedef struct GPBTimestamp__storage_ { 58 | uint32_t _has_storage_[1]; 59 | int32_t nanos; 60 | int64_t seconds; 61 | } GPBTimestamp__storage_; 62 | 63 | // This method is threadsafe because it is initially called 64 | // in +initialize for each subclass. 65 | + (GPBDescriptor *)descriptor { 66 | static GPBDescriptor *descriptor = nil; 67 | if (!descriptor) { 68 | static GPBMessageFieldDescription fields[] = { 69 | { 70 | .name = "seconds", 71 | .dataTypeSpecific.className = NULL, 72 | .number = GPBTimestamp_FieldNumber_Seconds, 73 | .hasIndex = 0, 74 | .offset = (uint32_t)offsetof(GPBTimestamp__storage_, seconds), 75 | .flags = GPBFieldOptional, 76 | .dataType = GPBDataTypeInt64, 77 | }, 78 | { 79 | .name = "nanos", 80 | .dataTypeSpecific.className = NULL, 81 | .number = GPBTimestamp_FieldNumber_Nanos, 82 | .hasIndex = 1, 83 | .offset = (uint32_t)offsetof(GPBTimestamp__storage_, nanos), 84 | .flags = GPBFieldOptional, 85 | .dataType = GPBDataTypeInt32, 86 | }, 87 | }; 88 | GPBDescriptor *localDescriptor = 89 | [GPBDescriptor allocDescriptorForClass:[GPBTimestamp class] 90 | rootClass:[GPBTimestampRoot class] 91 | file:GPBTimestampRoot_FileDescriptor() 92 | fields:fields 93 | fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription)) 94 | storageSize:sizeof(GPBTimestamp__storage_) 95 | flags:GPBDescriptorInitializationFlag_None]; 96 | #if defined(DEBUG) && DEBUG 97 | NSAssert(descriptor == nil, @"Startup recursed!"); 98 | #endif // DEBUG 99 | descriptor = localDescriptor; 100 | } 101 | return descriptor; 102 | } 103 | 104 | @end 105 | 106 | 107 | #pragma clang diagnostic pop 108 | 109 | // @@protoc_insertion_point(global_scope) 110 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBWireFormat.m: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2008 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import "GPBWireFormat.h" 32 | 33 | #import "GPBUtilities_PackagePrivate.h" 34 | 35 | enum { 36 | GPBWireFormatTagTypeBits = 3, 37 | GPBWireFormatTagTypeMask = 7 /* = (1 << GPBWireFormatTagTypeBits) - 1 */, 38 | }; 39 | 40 | uint32_t GPBWireFormatMakeTag(uint32_t fieldNumber, GPBWireFormat wireType) { 41 | return (fieldNumber << GPBWireFormatTagTypeBits) | wireType; 42 | } 43 | 44 | GPBWireFormat GPBWireFormatGetTagWireType(uint32_t tag) { 45 | return (GPBWireFormat)(tag & GPBWireFormatTagTypeMask); 46 | } 47 | 48 | uint32_t GPBWireFormatGetTagFieldNumber(uint32_t tag) { 49 | return GPBLogicalRightShift32(tag, GPBWireFormatTagTypeBits); 50 | } 51 | 52 | BOOL GPBWireFormatIsValidTag(uint32_t tag) { 53 | uint32_t formatBits = (tag & GPBWireFormatTagTypeMask); 54 | // The valid GPBWireFormat* values are 0-5, anything else is not a valid tag. 55 | BOOL result = (formatBits <= 5); 56 | return result; 57 | } 58 | 59 | GPBWireFormat GPBWireFormatForType(GPBDataType type, BOOL isPacked) { 60 | if (isPacked) { 61 | return GPBWireFormatLengthDelimited; 62 | } 63 | 64 | static const GPBWireFormat format[GPBDataType_Count] = { 65 | GPBWireFormatVarint, // GPBDataTypeBool 66 | GPBWireFormatFixed32, // GPBDataTypeFixed32 67 | GPBWireFormatFixed32, // GPBDataTypeSFixed32 68 | GPBWireFormatFixed32, // GPBDataTypeFloat 69 | GPBWireFormatFixed64, // GPBDataTypeFixed64 70 | GPBWireFormatFixed64, // GPBDataTypeSFixed64 71 | GPBWireFormatFixed64, // GPBDataTypeDouble 72 | GPBWireFormatVarint, // GPBDataTypeInt32 73 | GPBWireFormatVarint, // GPBDataTypeInt64 74 | GPBWireFormatVarint, // GPBDataTypeSInt32 75 | GPBWireFormatVarint, // GPBDataTypeSInt64 76 | GPBWireFormatVarint, // GPBDataTypeUInt32 77 | GPBWireFormatVarint, // GPBDataTypeUInt64 78 | GPBWireFormatLengthDelimited, // GPBDataTypeBytes 79 | GPBWireFormatLengthDelimited, // GPBDataTypeString 80 | GPBWireFormatLengthDelimited, // GPBDataTypeMessage 81 | GPBWireFormatStartGroup, // GPBDataTypeGroup 82 | GPBWireFormatVarint // GPBDataTypeEnum 83 | }; 84 | return format[type]; 85 | } 86 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/ssl23.h: -------------------------------------------------------------------------------- 1 | /* ssl/ssl23.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_SSL23_H 60 | # define HEADER_SSL23_H 61 | 62 | #ifdef __cplusplus 63 | extern "C" { 64 | #endif 65 | 66 | /* 67 | * client 68 | */ 69 | /* write to server */ 70 | # define SSL23_ST_CW_CLNT_HELLO_A (0x210|SSL_ST_CONNECT) 71 | # define SSL23_ST_CW_CLNT_HELLO_B (0x211|SSL_ST_CONNECT) 72 | /* read from server */ 73 | # define SSL23_ST_CR_SRVR_HELLO_A (0x220|SSL_ST_CONNECT) 74 | # define SSL23_ST_CR_SRVR_HELLO_B (0x221|SSL_ST_CONNECT) 75 | 76 | /* server */ 77 | /* read from client */ 78 | # define SSL23_ST_SR_CLNT_HELLO_A (0x210|SSL_ST_ACCEPT) 79 | # define SSL23_ST_SR_CLNT_HELLO_B (0x211|SSL_ST_ACCEPT) 80 | 81 | #ifdef __cplusplus 82 | } 83 | #endif 84 | #endif 85 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/rc4.h: -------------------------------------------------------------------------------- 1 | /* crypto/rc4/rc4.h */ 2 | /* Copyright (C) 1995-1997 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_RC4_H 60 | # define HEADER_RC4_H 61 | 62 | # include /* OPENSSL_NO_RC4, RC4_INT */ 63 | # ifdef OPENSSL_NO_RC4 64 | # error RC4 is disabled. 65 | # endif 66 | 67 | # include 68 | 69 | #ifdef __cplusplus 70 | extern "C" { 71 | #endif 72 | 73 | typedef struct rc4_key_st { 74 | RC4_INT x, y; 75 | RC4_INT data[256]; 76 | } RC4_KEY; 77 | 78 | const char *RC4_options(void); 79 | void RC4_set_key(RC4_KEY *key, int len, const unsigned char *data); 80 | void private_RC4_set_key(RC4_KEY *key, int len, const unsigned char *data); 81 | void RC4(RC4_KEY *key, size_t len, const unsigned char *indata, 82 | unsigned char *outdata); 83 | 84 | #ifdef __cplusplus 85 | } 86 | #endif 87 | 88 | #endif 89 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/pqueue.h: -------------------------------------------------------------------------------- 1 | /* crypto/pqueue/pqueue.h */ 2 | /* 3 | * DTLS implementation written by Nagendra Modadugu 4 | * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. 5 | */ 6 | /* ==================================================================== 7 | * Copyright (c) 1999-2005 The OpenSSL Project. All rights reserved. 8 | * 9 | * Redistribution and use in source and binary forms, with or without 10 | * modification, are permitted provided that the following conditions 11 | * are met: 12 | * 13 | * 1. Redistributions of source code must retain the above copyright 14 | * notice, this list of conditions and the following disclaimer. 15 | * 16 | * 2. Redistributions in binary form must reproduce the above copyright 17 | * notice, this list of conditions and the following disclaimer in 18 | * the documentation and/or other materials provided with the 19 | * distribution. 20 | * 21 | * 3. All advertising materials mentioning features or use of this 22 | * software must display the following acknowledgment: 23 | * "This product includes software developed by the OpenSSL Project 24 | * for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)" 25 | * 26 | * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 27 | * endorse or promote products derived from this software without 28 | * prior written permission. For written permission, please contact 29 | * openssl-core@OpenSSL.org. 30 | * 31 | * 5. Products derived from this software may not be called "OpenSSL" 32 | * nor may "OpenSSL" appear in their names without prior written 33 | * permission of the OpenSSL Project. 34 | * 35 | * 6. Redistributions of any form whatsoever must retain the following 36 | * acknowledgment: 37 | * "This product includes software developed by the OpenSSL Project 38 | * for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)" 39 | * 40 | * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 41 | * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 42 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 43 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 44 | * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 45 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 46 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 47 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 49 | * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 50 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 51 | * OF THE POSSIBILITY OF SUCH DAMAGE. 52 | * ==================================================================== 53 | * 54 | * This product includes cryptographic software written by Eric Young 55 | * (eay@cryptsoft.com). This product includes software written by Tim 56 | * Hudson (tjh@cryptsoft.com). 57 | * 58 | */ 59 | 60 | #ifndef HEADER_PQUEUE_H 61 | # define HEADER_PQUEUE_H 62 | 63 | # include 64 | # include 65 | # include 66 | 67 | #ifdef __cplusplus 68 | extern "C" { 69 | #endif 70 | typedef struct _pqueue *pqueue; 71 | 72 | typedef struct _pitem { 73 | unsigned char priority[8]; /* 64-bit value in big-endian encoding */ 74 | void *data; 75 | struct _pitem *next; 76 | } pitem; 77 | 78 | typedef struct _pitem *piterator; 79 | 80 | pitem *pitem_new(unsigned char *prio64be, void *data); 81 | void pitem_free(pitem *item); 82 | 83 | pqueue pqueue_new(void); 84 | void pqueue_free(pqueue pq); 85 | 86 | pitem *pqueue_insert(pqueue pq, pitem *item); 87 | pitem *pqueue_peek(pqueue pq); 88 | pitem *pqueue_pop(pqueue pq); 89 | pitem *pqueue_find(pqueue pq, unsigned char *prio64be); 90 | pitem *pqueue_iterator(pqueue pq); 91 | pitem *pqueue_next(piterator *iter); 92 | 93 | void pqueue_print(pqueue pq); 94 | int pqueue_size(pqueue pq); 95 | 96 | #ifdef __cplusplus 97 | } 98 | #endif 99 | #endif /* ! HEADER_PQUEUE_H */ 100 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/Any.pbobjc.m: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/any.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #else 13 | #import "GPBProtocolBuffers_RuntimeSupport.h" 14 | #endif 15 | 16 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 17 | #import 18 | #else 19 | #import "google/protobuf/Any.pbobjc.h" 20 | #endif 21 | // @@protoc_insertion_point(imports) 22 | 23 | #pragma clang diagnostic push 24 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 25 | 26 | #pragma mark - GPBAnyRoot 27 | 28 | @implementation GPBAnyRoot 29 | 30 | // No extensions in the file and no imports, so no need to generate 31 | // +extensionRegistry. 32 | 33 | @end 34 | 35 | #pragma mark - GPBAnyRoot_FileDescriptor 36 | 37 | static GPBFileDescriptor *GPBAnyRoot_FileDescriptor(void) { 38 | // This is called by +initialize so there is no need to worry 39 | // about thread safety of the singleton. 40 | static GPBFileDescriptor *descriptor = NULL; 41 | if (!descriptor) { 42 | GPB_DEBUG_CHECK_RUNTIME_VERSIONS(); 43 | descriptor = [[GPBFileDescriptor alloc] initWithPackage:@"google.protobuf" 44 | objcPrefix:@"GPB" 45 | syntax:GPBFileSyntaxProto3]; 46 | } 47 | return descriptor; 48 | } 49 | 50 | #pragma mark - GPBAny 51 | 52 | @implementation GPBAny 53 | 54 | @dynamic typeURL; 55 | @dynamic value; 56 | 57 | typedef struct GPBAny__storage_ { 58 | uint32_t _has_storage_[1]; 59 | NSString *typeURL; 60 | NSData *value; 61 | } GPBAny__storage_; 62 | 63 | // This method is threadsafe because it is initially called 64 | // in +initialize for each subclass. 65 | + (GPBDescriptor *)descriptor { 66 | static GPBDescriptor *descriptor = nil; 67 | if (!descriptor) { 68 | static GPBMessageFieldDescription fields[] = { 69 | { 70 | .name = "typeURL", 71 | .dataTypeSpecific.className = NULL, 72 | .number = GPBAny_FieldNumber_TypeURL, 73 | .hasIndex = 0, 74 | .offset = (uint32_t)offsetof(GPBAny__storage_, typeURL), 75 | .flags = (GPBFieldFlags)(GPBFieldOptional | GPBFieldTextFormatNameCustom), 76 | .dataType = GPBDataTypeString, 77 | }, 78 | { 79 | .name = "value", 80 | .dataTypeSpecific.className = NULL, 81 | .number = GPBAny_FieldNumber_Value, 82 | .hasIndex = 1, 83 | .offset = (uint32_t)offsetof(GPBAny__storage_, value), 84 | .flags = GPBFieldOptional, 85 | .dataType = GPBDataTypeBytes, 86 | }, 87 | }; 88 | GPBDescriptor *localDescriptor = 89 | [GPBDescriptor allocDescriptorForClass:[GPBAny class] 90 | rootClass:[GPBAnyRoot class] 91 | file:GPBAnyRoot_FileDescriptor() 92 | fields:fields 93 | fieldCount:(uint32_t)(sizeof(fields) / sizeof(GPBMessageFieldDescription)) 94 | storageSize:sizeof(GPBAny__storage_) 95 | flags:GPBDescriptorInitializationFlag_None]; 96 | #if !GPBOBJC_SKIP_MESSAGE_TEXTFORMAT_EXTRAS 97 | static const char *extraTextFormatInfo = 98 | "\001\001\004\241!!\000"; 99 | [localDescriptor setupExtraTextInfo:extraTextFormatInfo]; 100 | #endif // !GPBOBJC_SKIP_MESSAGE_TEXTFORMAT_EXTRAS 101 | #if defined(DEBUG) && DEBUG 102 | NSAssert(descriptor == nil, @"Startup recursed!"); 103 | #endif // DEBUG 104 | descriptor = localDescriptor; 105 | } 106 | return descriptor; 107 | } 108 | 109 | @end 110 | 111 | 112 | #pragma clang diagnostic pop 113 | 114 | // @@protoc_insertion_point(global_scope) 115 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/GPBArray_PackagePrivate.h: -------------------------------------------------------------------------------- 1 | // Protocol Buffers - Google's data interchange format 2 | // Copyright 2015 Google Inc. All rights reserved. 3 | // https://developers.google.com/protocol-buffers/ 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions are 7 | // met: 8 | // 9 | // * Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // * Redistributions in binary form must reproduce the above 12 | // copyright notice, this list of conditions and the following disclaimer 13 | // in the documentation and/or other materials provided with the 14 | // distribution. 15 | // * Neither the name of Google Inc. nor the names of its 16 | // contributors may be used to endorse or promote products derived from 17 | // this software without specific prior written permission. 18 | // 19 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 20 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 21 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | #import "GPBArray.h" 32 | 33 | @class GPBMessage; 34 | 35 | //%PDDM-DEFINE DECLARE_ARRAY_EXTRAS() 36 | //%ARRAY_INTERFACE_EXTRAS(Int32, int32_t) 37 | //%ARRAY_INTERFACE_EXTRAS(UInt32, uint32_t) 38 | //%ARRAY_INTERFACE_EXTRAS(Int64, int64_t) 39 | //%ARRAY_INTERFACE_EXTRAS(UInt64, uint64_t) 40 | //%ARRAY_INTERFACE_EXTRAS(Float, float) 41 | //%ARRAY_INTERFACE_EXTRAS(Double, double) 42 | //%ARRAY_INTERFACE_EXTRAS(Bool, BOOL) 43 | //%ARRAY_INTERFACE_EXTRAS(Enum, int32_t) 44 | 45 | //%PDDM-DEFINE ARRAY_INTERFACE_EXTRAS(NAME, TYPE) 46 | //%#pragma mark - NAME 47 | //% 48 | //%@interface GPB##NAME##Array () { 49 | //% @package 50 | //% GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 51 | //%} 52 | //%@end 53 | //% 54 | 55 | //%PDDM-EXPAND DECLARE_ARRAY_EXTRAS() 56 | // This block of code is generated, do not edit it directly. 57 | 58 | #pragma mark - Int32 59 | 60 | @interface GPBInt32Array () { 61 | @package 62 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 63 | } 64 | @end 65 | 66 | #pragma mark - UInt32 67 | 68 | @interface GPBUInt32Array () { 69 | @package 70 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 71 | } 72 | @end 73 | 74 | #pragma mark - Int64 75 | 76 | @interface GPBInt64Array () { 77 | @package 78 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 79 | } 80 | @end 81 | 82 | #pragma mark - UInt64 83 | 84 | @interface GPBUInt64Array () { 85 | @package 86 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 87 | } 88 | @end 89 | 90 | #pragma mark - Float 91 | 92 | @interface GPBFloatArray () { 93 | @package 94 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 95 | } 96 | @end 97 | 98 | #pragma mark - Double 99 | 100 | @interface GPBDoubleArray () { 101 | @package 102 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 103 | } 104 | @end 105 | 106 | #pragma mark - Bool 107 | 108 | @interface GPBBoolArray () { 109 | @package 110 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 111 | } 112 | @end 113 | 114 | #pragma mark - Enum 115 | 116 | @interface GPBEnumArray () { 117 | @package 118 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 119 | } 120 | @end 121 | 122 | //%PDDM-EXPAND-END DECLARE_ARRAY_EXTRAS() 123 | 124 | #pragma mark - NSArray Subclass 125 | 126 | @interface GPBAutocreatedArray : NSMutableArray { 127 | @package 128 | GPB_UNSAFE_UNRETAINED GPBMessage *_autocreator; 129 | } 130 | @end 131 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/mdc2.h: -------------------------------------------------------------------------------- 1 | /* crypto/mdc2/mdc2.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_MDC2_H 60 | # define HEADER_MDC2_H 61 | 62 | # include 63 | 64 | #ifdef __cplusplus 65 | extern "C" { 66 | #endif 67 | 68 | # ifdef OPENSSL_NO_MDC2 69 | # error MDC2 is disabled. 70 | # endif 71 | 72 | # define MDC2_BLOCK 8 73 | # define MDC2_DIGEST_LENGTH 16 74 | 75 | typedef struct mdc2_ctx_st { 76 | unsigned int num; 77 | unsigned char data[MDC2_BLOCK]; 78 | DES_cblock h, hh; 79 | int pad_type; /* either 1 or 2, default 1 */ 80 | } MDC2_CTX; 81 | 82 | # ifdef OPENSSL_FIPS 83 | int private_MDC2_Init(MDC2_CTX *c); 84 | # endif 85 | int MDC2_Init(MDC2_CTX *c); 86 | int MDC2_Update(MDC2_CTX *c, const unsigned char *data, size_t len); 87 | int MDC2_Final(unsigned char *md, MDC2_CTX *c); 88 | unsigned char *MDC2(const unsigned char *d, size_t n, unsigned char *md); 89 | 90 | #ifdef __cplusplus 91 | } 92 | #endif 93 | 94 | #endif 95 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/opensslv.h: -------------------------------------------------------------------------------- 1 | #ifndef HEADER_OPENSSLV_H 2 | # define HEADER_OPENSSLV_H 3 | 4 | #ifdef __cplusplus 5 | extern "C" { 6 | #endif 7 | 8 | /*- 9 | * Numeric release version identifier: 10 | * MNNFFPPS: major minor fix patch status 11 | * The status nibble has one of the values 0 for development, 1 to e for betas 12 | * 1 to 14, and f for release. The patch level is exactly that. 13 | * For example: 14 | * 0.9.3-dev 0x00903000 15 | * 0.9.3-beta1 0x00903001 16 | * 0.9.3-beta2-dev 0x00903002 17 | * 0.9.3-beta2 0x00903002 (same as ...beta2-dev) 18 | * 0.9.3 0x0090300f 19 | * 0.9.3a 0x0090301f 20 | * 0.9.4 0x0090400f 21 | * 1.2.3z 0x102031af 22 | * 23 | * For continuity reasons (because 0.9.5 is already out, and is coded 24 | * 0x00905100), between 0.9.5 and 0.9.6 the coding of the patch level 25 | * part is slightly different, by setting the highest bit. This means 26 | * that 0.9.5a looks like this: 0x0090581f. At 0.9.6, we can start 27 | * with 0x0090600S... 28 | * 29 | * (Prior to 0.9.3-dev a different scheme was used: 0.9.2b is 0x0922.) 30 | * (Prior to 0.9.5a beta1, a different scheme was used: MMNNFFRBB for 31 | * major minor fix final patch/beta) 32 | */ 33 | # define OPENSSL_VERSION_NUMBER 0x1000207fL 34 | # ifdef OPENSSL_FIPS 35 | # define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2g-fips 1 Mar 2016" 36 | # else 37 | # define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2g 1 Mar 2016" 38 | # endif 39 | # define OPENSSL_VERSION_PTEXT " part of " OPENSSL_VERSION_TEXT 40 | 41 | /*- 42 | * The macros below are to be used for shared library (.so, .dll, ...) 43 | * versioning. That kind of versioning works a bit differently between 44 | * operating systems. The most usual scheme is to set a major and a minor 45 | * number, and have the runtime loader check that the major number is equal 46 | * to what it was at application link time, while the minor number has to 47 | * be greater or equal to what it was at application link time. With this 48 | * scheme, the version number is usually part of the file name, like this: 49 | * 50 | * libcrypto.so.0.9 51 | * 52 | * Some unixen also make a softlink with the major verson number only: 53 | * 54 | * libcrypto.so.0 55 | * 56 | * On Tru64 and IRIX 6.x it works a little bit differently. There, the 57 | * shared library version is stored in the file, and is actually a series 58 | * of versions, separated by colons. The rightmost version present in the 59 | * library when linking an application is stored in the application to be 60 | * matched at run time. When the application is run, a check is done to 61 | * see if the library version stored in the application matches any of the 62 | * versions in the version string of the library itself. 63 | * This version string can be constructed in any way, depending on what 64 | * kind of matching is desired. However, to implement the same scheme as 65 | * the one used in the other unixen, all compatible versions, from lowest 66 | * to highest, should be part of the string. Consecutive builds would 67 | * give the following versions strings: 68 | * 69 | * 3.0 70 | * 3.0:3.1 71 | * 3.0:3.1:3.2 72 | * 4.0 73 | * 4.0:4.1 74 | * 75 | * Notice how version 4 is completely incompatible with version, and 76 | * therefore give the breach you can see. 77 | * 78 | * There may be other schemes as well that I haven't yet discovered. 79 | * 80 | * So, here's the way it works here: first of all, the library version 81 | * number doesn't need at all to match the overall OpenSSL version. 82 | * However, it's nice and more understandable if it actually does. 83 | * The current library version is stored in the macro SHLIB_VERSION_NUMBER, 84 | * which is just a piece of text in the format "M.m.e" (Major, minor, edit). 85 | * For the sake of Tru64, IRIX, and any other OS that behaves in similar ways, 86 | * we need to keep a history of version numbers, which is done in the 87 | * macro SHLIB_VERSION_HISTORY. The numbers are separated by colons and 88 | * should only keep the versions that are binary compatible with the current. 89 | */ 90 | # define SHLIB_VERSION_HISTORY "" 91 | # define SHLIB_VERSION_NUMBER "1.0.0" 92 | 93 | 94 | #ifdef __cplusplus 95 | } 96 | #endif 97 | #endif /* HEADER_OPENSSLV_H */ 98 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/conf_api.h: -------------------------------------------------------------------------------- 1 | /* conf_api.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_CONF_API_H 60 | # define HEADER_CONF_API_H 61 | 62 | # include 63 | # include 64 | 65 | #ifdef __cplusplus 66 | extern "C" { 67 | #endif 68 | 69 | /* Up until OpenSSL 0.9.5a, this was new_section */ 70 | CONF_VALUE *_CONF_new_section(CONF *conf, const char *section); 71 | /* Up until OpenSSL 0.9.5a, this was get_section */ 72 | CONF_VALUE *_CONF_get_section(const CONF *conf, const char *section); 73 | /* Up until OpenSSL 0.9.5a, this was CONF_get_section */ 74 | STACK_OF(CONF_VALUE) *_CONF_get_section_values(const CONF *conf, 75 | const char *section); 76 | 77 | int _CONF_add_string(CONF *conf, CONF_VALUE *section, CONF_VALUE *value); 78 | char *_CONF_get_string(const CONF *conf, const char *section, 79 | const char *name); 80 | long _CONF_get_number(const CONF *conf, const char *section, 81 | const char *name); 82 | 83 | int _CONF_new_data(CONF *conf); 84 | void _CONF_free_data(CONF *conf); 85 | 86 | #ifdef __cplusplus 87 | } 88 | #endif 89 | #endif 90 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/ripemd.h: -------------------------------------------------------------------------------- 1 | /* crypto/ripemd/ripemd.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_RIPEMD_H 60 | # define HEADER_RIPEMD_H 61 | 62 | # include 63 | # include 64 | 65 | #ifdef __cplusplus 66 | extern "C" { 67 | #endif 68 | 69 | # ifdef OPENSSL_NO_RIPEMD 70 | # error RIPEMD is disabled. 71 | # endif 72 | 73 | # if defined(__LP32__) 74 | # define RIPEMD160_LONG unsigned long 75 | # elif defined(OPENSSL_SYS_CRAY) || defined(__ILP64__) 76 | # define RIPEMD160_LONG unsigned long 77 | # define RIPEMD160_LONG_LOG2 3 78 | # else 79 | # define RIPEMD160_LONG unsigned int 80 | # endif 81 | 82 | # define RIPEMD160_CBLOCK 64 83 | # define RIPEMD160_LBLOCK (RIPEMD160_CBLOCK/4) 84 | # define RIPEMD160_DIGEST_LENGTH 20 85 | 86 | typedef struct RIPEMD160state_st { 87 | RIPEMD160_LONG A, B, C, D, E; 88 | RIPEMD160_LONG Nl, Nh; 89 | RIPEMD160_LONG data[RIPEMD160_LBLOCK]; 90 | unsigned int num; 91 | } RIPEMD160_CTX; 92 | 93 | # ifdef OPENSSL_FIPS 94 | int private_RIPEMD160_Init(RIPEMD160_CTX *c); 95 | # endif 96 | int RIPEMD160_Init(RIPEMD160_CTX *c); 97 | int RIPEMD160_Update(RIPEMD160_CTX *c, const void *data, size_t len); 98 | int RIPEMD160_Final(unsigned char *md, RIPEMD160_CTX *c); 99 | unsigned char *RIPEMD160(const unsigned char *d, size_t n, unsigned char *md); 100 | void RIPEMD160_Transform(RIPEMD160_CTX *c, const unsigned char *b); 101 | #ifdef __cplusplus 102 | } 103 | #endif 104 | 105 | #endif 106 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/rc2.h: -------------------------------------------------------------------------------- 1 | /* crypto/rc2/rc2.h */ 2 | /* Copyright (C) 1995-1997 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_RC2_H 60 | # define HEADER_RC2_H 61 | 62 | # include /* OPENSSL_NO_RC2, RC2_INT */ 63 | # ifdef OPENSSL_NO_RC2 64 | # error RC2 is disabled. 65 | # endif 66 | 67 | # define RC2_ENCRYPT 1 68 | # define RC2_DECRYPT 0 69 | 70 | # define RC2_BLOCK 8 71 | # define RC2_KEY_LENGTH 16 72 | 73 | #ifdef __cplusplus 74 | extern "C" { 75 | #endif 76 | 77 | typedef struct rc2_key_st { 78 | RC2_INT data[64]; 79 | } RC2_KEY; 80 | 81 | # ifdef OPENSSL_FIPS 82 | void private_RC2_set_key(RC2_KEY *key, int len, const unsigned char *data, 83 | int bits); 84 | # endif 85 | void RC2_set_key(RC2_KEY *key, int len, const unsigned char *data, int bits); 86 | void RC2_ecb_encrypt(const unsigned char *in, unsigned char *out, 87 | RC2_KEY *key, int enc); 88 | void RC2_encrypt(unsigned long *data, RC2_KEY *key); 89 | void RC2_decrypt(unsigned long *data, RC2_KEY *key); 90 | void RC2_cbc_encrypt(const unsigned char *in, unsigned char *out, long length, 91 | RC2_KEY *ks, unsigned char *iv, int enc); 92 | void RC2_cfb64_encrypt(const unsigned char *in, unsigned char *out, 93 | long length, RC2_KEY *schedule, unsigned char *ivec, 94 | int *num, int enc); 95 | void RC2_ofb64_encrypt(const unsigned char *in, unsigned char *out, 96 | long length, RC2_KEY *schedule, unsigned char *ivec, 97 | int *num); 98 | 99 | #ifdef __cplusplus 100 | } 101 | #endif 102 | 103 | #endif 104 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/stack.h: -------------------------------------------------------------------------------- 1 | /* crypto/stack/stack.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_STACK_H 60 | # define HEADER_STACK_H 61 | 62 | #ifdef __cplusplus 63 | extern "C" { 64 | #endif 65 | 66 | typedef struct stack_st { 67 | int num; 68 | char **data; 69 | int sorted; 70 | int num_alloc; 71 | int (*comp) (const void *, const void *); 72 | } _STACK; /* Use STACK_OF(...) instead */ 73 | 74 | # define M_sk_num(sk) ((sk) ? (sk)->num:-1) 75 | # define M_sk_value(sk,n) ((sk) ? (sk)->data[n] : NULL) 76 | 77 | int sk_num(const _STACK *); 78 | void *sk_value(const _STACK *, int); 79 | 80 | void *sk_set(_STACK *, int, void *); 81 | 82 | _STACK *sk_new(int (*cmp) (const void *, const void *)); 83 | _STACK *sk_new_null(void); 84 | void sk_free(_STACK *); 85 | void sk_pop_free(_STACK *st, void (*func) (void *)); 86 | _STACK *sk_deep_copy(_STACK *, void *(*)(void *), void (*)(void *)); 87 | int sk_insert(_STACK *sk, void *data, int where); 88 | void *sk_delete(_STACK *st, int loc); 89 | void *sk_delete_ptr(_STACK *st, void *p); 90 | int sk_find(_STACK *st, void *data); 91 | int sk_find_ex(_STACK *st, void *data); 92 | int sk_push(_STACK *st, void *data); 93 | int sk_unshift(_STACK *st, void *data); 94 | void *sk_shift(_STACK *st); 95 | void *sk_pop(_STACK *st); 96 | void sk_zero(_STACK *st); 97 | int (*sk_set_cmp_func(_STACK *sk, int (*c) (const void *, const void *))) 98 | (const void *, const void *); 99 | _STACK *sk_dup(_STACK *st); 100 | void sk_sort(_STACK *st); 101 | int sk_is_sorted(const _STACK *st); 102 | 103 | #ifdef __cplusplus 104 | } 105 | #endif 106 | 107 | #endif 108 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/hmac.h: -------------------------------------------------------------------------------- 1 | /* crypto/hmac/hmac.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | #ifndef HEADER_HMAC_H 59 | # define HEADER_HMAC_H 60 | 61 | # include 62 | 63 | # ifdef OPENSSL_NO_HMAC 64 | # error HMAC is disabled. 65 | # endif 66 | 67 | # include 68 | 69 | # define HMAC_MAX_MD_CBLOCK 128/* largest known is SHA512 */ 70 | 71 | #ifdef __cplusplus 72 | extern "C" { 73 | #endif 74 | 75 | typedef struct hmac_ctx_st { 76 | const EVP_MD *md; 77 | EVP_MD_CTX md_ctx; 78 | EVP_MD_CTX i_ctx; 79 | EVP_MD_CTX o_ctx; 80 | unsigned int key_length; 81 | unsigned char key[HMAC_MAX_MD_CBLOCK]; 82 | } HMAC_CTX; 83 | 84 | # define HMAC_size(e) (EVP_MD_size((e)->md)) 85 | 86 | void HMAC_CTX_init(HMAC_CTX *ctx); 87 | void HMAC_CTX_cleanup(HMAC_CTX *ctx); 88 | 89 | /* deprecated */ 90 | # define HMAC_cleanup(ctx) HMAC_CTX_cleanup(ctx) 91 | 92 | /* deprecated */ 93 | int HMAC_Init(HMAC_CTX *ctx, const void *key, int len, const EVP_MD *md); 94 | int HMAC_Init_ex(HMAC_CTX *ctx, const void *key, int len, 95 | const EVP_MD *md, ENGINE *impl); 96 | int HMAC_Update(HMAC_CTX *ctx, const unsigned char *data, size_t len); 97 | int HMAC_Final(HMAC_CTX *ctx, unsigned char *md, unsigned int *len); 98 | unsigned char *HMAC(const EVP_MD *evp_md, const void *key, int key_len, 99 | const unsigned char *d, size_t n, unsigned char *md, 100 | unsigned int *md_len); 101 | int HMAC_CTX_copy(HMAC_CTX *dctx, HMAC_CTX *sctx); 102 | 103 | void HMAC_CTX_set_flags(HMAC_CTX *ctx, unsigned long flags); 104 | 105 | #ifdef __cplusplus 106 | } 107 | #endif 108 | 109 | #endif 110 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/cast.h: -------------------------------------------------------------------------------- 1 | /* crypto/cast/cast.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_CAST_H 60 | # define HEADER_CAST_H 61 | 62 | #ifdef __cplusplus 63 | extern "C" { 64 | #endif 65 | 66 | # include 67 | 68 | # ifdef OPENSSL_NO_CAST 69 | # error CAST is disabled. 70 | # endif 71 | 72 | # define CAST_ENCRYPT 1 73 | # define CAST_DECRYPT 0 74 | 75 | # define CAST_LONG unsigned int 76 | 77 | # define CAST_BLOCK 8 78 | # define CAST_KEY_LENGTH 16 79 | 80 | typedef struct cast_key_st { 81 | CAST_LONG data[32]; 82 | int short_key; /* Use reduced rounds for short key */ 83 | } CAST_KEY; 84 | 85 | # ifdef OPENSSL_FIPS 86 | void private_CAST_set_key(CAST_KEY *key, int len, const unsigned char *data); 87 | # endif 88 | void CAST_set_key(CAST_KEY *key, int len, const unsigned char *data); 89 | void CAST_ecb_encrypt(const unsigned char *in, unsigned char *out, 90 | const CAST_KEY *key, int enc); 91 | void CAST_encrypt(CAST_LONG *data, const CAST_KEY *key); 92 | void CAST_decrypt(CAST_LONG *data, const CAST_KEY *key); 93 | void CAST_cbc_encrypt(const unsigned char *in, unsigned char *out, 94 | long length, const CAST_KEY *ks, unsigned char *iv, 95 | int enc); 96 | void CAST_cfb64_encrypt(const unsigned char *in, unsigned char *out, 97 | long length, const CAST_KEY *schedule, 98 | unsigned char *ivec, int *num, int enc); 99 | void CAST_ofb64_encrypt(const unsigned char *in, unsigned char *out, 100 | long length, const CAST_KEY *schedule, 101 | unsigned char *ivec, int *num); 102 | 103 | #ifdef __cplusplus 104 | } 105 | #endif 106 | 107 | #endif 108 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/txt_db.h: -------------------------------------------------------------------------------- 1 | /* crypto/txt_db/txt_db.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_TXT_DB_H 60 | # define HEADER_TXT_DB_H 61 | 62 | # include 63 | # ifndef OPENSSL_NO_BIO 64 | # include 65 | # endif 66 | # include 67 | # include 68 | 69 | # define DB_ERROR_OK 0 70 | # define DB_ERROR_MALLOC 1 71 | # define DB_ERROR_INDEX_CLASH 2 72 | # define DB_ERROR_INDEX_OUT_OF_RANGE 3 73 | # define DB_ERROR_NO_INDEX 4 74 | # define DB_ERROR_INSERT_INDEX_CLASH 5 75 | 76 | #ifdef __cplusplus 77 | extern "C" { 78 | #endif 79 | 80 | typedef OPENSSL_STRING *OPENSSL_PSTRING; 81 | DECLARE_SPECIAL_STACK_OF(OPENSSL_PSTRING, OPENSSL_STRING) 82 | 83 | typedef struct txt_db_st { 84 | int num_fields; 85 | STACK_OF(OPENSSL_PSTRING) *data; 86 | LHASH_OF(OPENSSL_STRING) **index; 87 | int (**qual) (OPENSSL_STRING *); 88 | long error; 89 | long arg1; 90 | long arg2; 91 | OPENSSL_STRING *arg_row; 92 | } TXT_DB; 93 | 94 | # ifndef OPENSSL_NO_BIO 95 | TXT_DB *TXT_DB_read(BIO *in, int num); 96 | long TXT_DB_write(BIO *out, TXT_DB *db); 97 | # else 98 | TXT_DB *TXT_DB_read(char *in, int num); 99 | long TXT_DB_write(char *out, TXT_DB *db); 100 | # endif 101 | int TXT_DB_create_index(TXT_DB *db, int field, int (*qual) (OPENSSL_STRING *), 102 | LHASH_HASH_FN_TYPE hash, LHASH_COMP_FN_TYPE cmp); 103 | void TXT_DB_free(TXT_DB *db); 104 | OPENSSL_STRING *TXT_DB_get_by_index(TXT_DB *db, int idx, 105 | OPENSSL_STRING *value); 106 | int TXT_DB_insert(TXT_DB *db, OPENSSL_STRING *value); 107 | 108 | #ifdef __cplusplus 109 | } 110 | #endif 111 | 112 | #endif 113 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/idea.h: -------------------------------------------------------------------------------- 1 | /* crypto/idea/idea.h */ 2 | /* Copyright (C) 1995-1997 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_IDEA_H 60 | # define HEADER_IDEA_H 61 | 62 | # include /* IDEA_INT, OPENSSL_NO_IDEA */ 63 | 64 | # ifdef OPENSSL_NO_IDEA 65 | # error IDEA is disabled. 66 | # endif 67 | 68 | # define IDEA_ENCRYPT 1 69 | # define IDEA_DECRYPT 0 70 | 71 | # define IDEA_BLOCK 8 72 | # define IDEA_KEY_LENGTH 16 73 | 74 | #ifdef __cplusplus 75 | extern "C" { 76 | #endif 77 | 78 | typedef struct idea_key_st { 79 | IDEA_INT data[9][6]; 80 | } IDEA_KEY_SCHEDULE; 81 | 82 | const char *idea_options(void); 83 | void idea_ecb_encrypt(const unsigned char *in, unsigned char *out, 84 | IDEA_KEY_SCHEDULE *ks); 85 | # ifdef OPENSSL_FIPS 86 | void private_idea_set_encrypt_key(const unsigned char *key, 87 | IDEA_KEY_SCHEDULE *ks); 88 | # endif 89 | void idea_set_encrypt_key(const unsigned char *key, IDEA_KEY_SCHEDULE *ks); 90 | void idea_set_decrypt_key(IDEA_KEY_SCHEDULE *ek, IDEA_KEY_SCHEDULE *dk); 91 | void idea_cbc_encrypt(const unsigned char *in, unsigned char *out, 92 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv, 93 | int enc); 94 | void idea_cfb64_encrypt(const unsigned char *in, unsigned char *out, 95 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv, 96 | int *num, int enc); 97 | void idea_ofb64_encrypt(const unsigned char *in, unsigned char *out, 98 | long length, IDEA_KEY_SCHEDULE *ks, unsigned char *iv, 99 | int *num); 100 | void idea_encrypt(unsigned long *in, IDEA_KEY_SCHEDULE *ks); 101 | #ifdef __cplusplus 102 | } 103 | #endif 104 | 105 | #endif 106 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/md4.h: -------------------------------------------------------------------------------- 1 | /* crypto/md4/md4.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_MD4_H 60 | # define HEADER_MD4_H 61 | 62 | # include 63 | # include 64 | 65 | #ifdef __cplusplus 66 | extern "C" { 67 | #endif 68 | 69 | # ifdef OPENSSL_NO_MD4 70 | # error MD4 is disabled. 71 | # endif 72 | 73 | /*- 74 | * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 75 | * ! MD4_LONG has to be at least 32 bits wide. If it's wider, then ! 76 | * ! MD4_LONG_LOG2 has to be defined along. ! 77 | * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 78 | */ 79 | 80 | # if defined(__LP32__) 81 | # define MD4_LONG unsigned long 82 | # elif defined(OPENSSL_SYS_CRAY) || defined(__ILP64__) 83 | # define MD4_LONG unsigned long 84 | # define MD4_LONG_LOG2 3 85 | /* 86 | * _CRAY note. I could declare short, but I have no idea what impact 87 | * does it have on performance on none-T3E machines. I could declare 88 | * int, but at least on C90 sizeof(int) can be chosen at compile time. 89 | * So I've chosen long... 90 | * 91 | */ 92 | # else 93 | # define MD4_LONG unsigned int 94 | # endif 95 | 96 | # define MD4_CBLOCK 64 97 | # define MD4_LBLOCK (MD4_CBLOCK/4) 98 | # define MD4_DIGEST_LENGTH 16 99 | 100 | typedef struct MD4state_st { 101 | MD4_LONG A, B, C, D; 102 | MD4_LONG Nl, Nh; 103 | MD4_LONG data[MD4_LBLOCK]; 104 | unsigned int num; 105 | } MD4_CTX; 106 | 107 | # ifdef OPENSSL_FIPS 108 | int private_MD4_Init(MD4_CTX *c); 109 | # endif 110 | int MD4_Init(MD4_CTX *c); 111 | int MD4_Update(MD4_CTX *c, const void *data, size_t len); 112 | int MD4_Final(unsigned char *md, MD4_CTX *c); 113 | unsigned char *MD4(const unsigned char *d, size_t n, unsigned char *md); 114 | void MD4_Transform(MD4_CTX *c, const unsigned char *b); 115 | #ifdef __cplusplus 116 | } 117 | #endif 118 | 119 | #endif 120 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/md5.h: -------------------------------------------------------------------------------- 1 | /* crypto/md5/md5.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_MD5_H 60 | # define HEADER_MD5_H 61 | 62 | # include 63 | # include 64 | 65 | #ifdef __cplusplus 66 | extern "C" { 67 | #endif 68 | 69 | # ifdef OPENSSL_NO_MD5 70 | # error MD5 is disabled. 71 | # endif 72 | 73 | /* 74 | * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 75 | * ! MD5_LONG has to be at least 32 bits wide. If it's wider, then ! 76 | * ! MD5_LONG_LOG2 has to be defined along. ! 77 | * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 78 | */ 79 | 80 | # if defined(__LP32__) 81 | # define MD5_LONG unsigned long 82 | # elif defined(OPENSSL_SYS_CRAY) || defined(__ILP64__) 83 | # define MD5_LONG unsigned long 84 | # define MD5_LONG_LOG2 3 85 | /* 86 | * _CRAY note. I could declare short, but I have no idea what impact 87 | * does it have on performance on none-T3E machines. I could declare 88 | * int, but at least on C90 sizeof(int) can be chosen at compile time. 89 | * So I've chosen long... 90 | * 91 | */ 92 | # else 93 | # define MD5_LONG unsigned int 94 | # endif 95 | 96 | # define MD5_CBLOCK 64 97 | # define MD5_LBLOCK (MD5_CBLOCK/4) 98 | # define MD5_DIGEST_LENGTH 16 99 | 100 | typedef struct MD5state_st { 101 | MD5_LONG A, B, C, D; 102 | MD5_LONG Nl, Nh; 103 | MD5_LONG data[MD5_LBLOCK]; 104 | unsigned int num; 105 | } MD5_CTX; 106 | 107 | # ifdef OPENSSL_FIPS 108 | int private_MD5_Init(MD5_CTX *c); 109 | # endif 110 | int MD5_Init(MD5_CTX *c); 111 | int MD5_Update(MD5_CTX *c, const void *data, size_t len); 112 | int MD5_Final(unsigned char *md, MD5_CTX *c); 113 | unsigned char *MD5(const unsigned char *d, size_t n, unsigned char *md); 114 | void MD5_Transform(MD5_CTX *c, const unsigned char *b); 115 | #ifdef __cplusplus 116 | } 117 | #endif 118 | 119 | #endif 120 | -------------------------------------------------------------------------------- /demo/Pods/Protobuf/objectivec/google/protobuf/Duration.pbobjc.h: -------------------------------------------------------------------------------- 1 | // Generated by the protocol buffer compiler. DO NOT EDIT! 2 | // source: google/protobuf/duration.proto 3 | 4 | // This CPP symbol can be defined to use imports that match up to the framework 5 | // imports needed when using CocoaPods. 6 | #if !defined(GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS) 7 | #define GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 0 8 | #endif 9 | 10 | #if GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS 11 | #import 12 | #import 13 | #import 14 | #else 15 | #import "GPBDescriptor.h" 16 | #import "GPBMessage.h" 17 | #import "GPBRootObject.h" 18 | #endif 19 | 20 | #if GOOGLE_PROTOBUF_OBJC_VERSION < 30002 21 | #error This file was generated by a newer version of protoc which is incompatible with your Protocol Buffer library sources. 22 | #endif 23 | #if 30002 < GOOGLE_PROTOBUF_OBJC_MIN_SUPPORTED_VERSION 24 | #error This file was generated by an older version of protoc which is incompatible with your Protocol Buffer library sources. 25 | #endif 26 | 27 | // @@protoc_insertion_point(imports) 28 | 29 | #pragma clang diagnostic push 30 | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 31 | 32 | CF_EXTERN_C_BEGIN 33 | 34 | NS_ASSUME_NONNULL_BEGIN 35 | 36 | #pragma mark - GPBDurationRoot 37 | 38 | /** 39 | * Exposes the extension registry for this file. 40 | * 41 | * The base class provides: 42 | * @code 43 | * + (GPBExtensionRegistry *)extensionRegistry; 44 | * @endcode 45 | * which is a @c GPBExtensionRegistry that includes all the extensions defined by 46 | * this file and all files that it depends on. 47 | **/ 48 | @interface GPBDurationRoot : GPBRootObject 49 | @end 50 | 51 | #pragma mark - GPBDuration 52 | 53 | typedef GPB_ENUM(GPBDuration_FieldNumber) { 54 | GPBDuration_FieldNumber_Seconds = 1, 55 | GPBDuration_FieldNumber_Nanos = 2, 56 | }; 57 | 58 | /** 59 | * A Duration represents a signed, fixed-length span of time represented 60 | * as a count of seconds and fractions of seconds at nanosecond 61 | * resolution. It is independent of any calendar and concepts like "day" 62 | * or "month". It is related to Timestamp in that the difference between 63 | * two Timestamp values is a Duration and it can be added or subtracted 64 | * from a Timestamp. Range is approximately +-10,000 years. 65 | * 66 | * # Examples 67 | * 68 | * Example 1: Compute Duration from two Timestamps in pseudo code. 69 | * 70 | * Timestamp start = ...; 71 | * Timestamp end = ...; 72 | * Duration duration = ...; 73 | * 74 | * duration.seconds = end.seconds - start.seconds; 75 | * duration.nanos = end.nanos - start.nanos; 76 | * 77 | * if (duration.seconds < 0 && duration.nanos > 0) { 78 | * duration.seconds += 1; 79 | * duration.nanos -= 1000000000; 80 | * } else if (duration.seconds > 0 && duration.nanos < 0) { 81 | * duration.seconds -= 1; 82 | * duration.nanos += 1000000000; 83 | * } 84 | * 85 | * Example 2: Compute Timestamp from Timestamp + Duration in pseudo code. 86 | * 87 | * Timestamp start = ...; 88 | * Duration duration = ...; 89 | * Timestamp end = ...; 90 | * 91 | * end.seconds = start.seconds + duration.seconds; 92 | * end.nanos = start.nanos + duration.nanos; 93 | * 94 | * if (end.nanos < 0) { 95 | * end.seconds -= 1; 96 | * end.nanos += 1000000000; 97 | * } else if (end.nanos >= 1000000000) { 98 | * end.seconds += 1; 99 | * end.nanos -= 1000000000; 100 | * } 101 | * 102 | * Example 3: Compute Duration from datetime.timedelta in Python. 103 | * 104 | * td = datetime.timedelta(days=3, minutes=10) 105 | * duration = Duration() 106 | * duration.FromTimedelta(td) 107 | * 108 | * # JSON Mapping 109 | * 110 | * In JSON format, the Duration type is encoded as a string rather than an 111 | * object, where the string ends in the suffix "s" (indicating seconds) and 112 | * is preceded by the number of seconds, with nanoseconds expressed as 113 | * fractional seconds. For example, 3 seconds with 0 nanoseconds should be 114 | * encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should 115 | * be expressed in JSON format as "3.000000001s", and 3 seconds and 1 116 | * microsecond should be expressed in JSON format as "3.000001s". 117 | **/ 118 | @interface GPBDuration : GPBMessage 119 | 120 | /** 121 | * Signed seconds of the span of time. Must be from -315,576,000,000 122 | * to +315,576,000,000 inclusive. Note: these bounds are computed from: 123 | * 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years 124 | **/ 125 | @property(nonatomic, readwrite) int64_t seconds; 126 | 127 | /** 128 | * Signed fractions of a second at nanosecond resolution of the span 129 | * of time. Durations less than one second are represented with a 0 130 | * `seconds` field and a positive or negative `nanos` field. For durations 131 | * of one second or more, a non-zero value for the `nanos` field must be 132 | * of the same sign as the `seconds` field. Must be from -999,999,999 133 | * to +999,999,999 inclusive. 134 | **/ 135 | @property(nonatomic, readwrite) int32_t nanos; 136 | 137 | @end 138 | 139 | NS_ASSUME_NONNULL_END 140 | 141 | CF_EXTERN_C_END 142 | 143 | #pragma clang diagnostic pop 144 | 145 | // @@protoc_insertion_point(global_scope) 146 | -------------------------------------------------------------------------------- /demo/WedprDemo/OpenSSL/include/openssl/buffer.h: -------------------------------------------------------------------------------- 1 | /* crypto/buffer/buffer.h */ 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 3 | * All rights reserved. 4 | * 5 | * This package is an SSL implementation written 6 | * by Eric Young (eay@cryptsoft.com). 7 | * The implementation was written so as to conform with Netscapes SSL. 8 | * 9 | * This library is free for commercial and non-commercial use as long as 10 | * the following conditions are aheared to. The following conditions 11 | * apply to all code found in this distribution, be it the RC4, RSA, 12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation 13 | * included with this distribution is covered by the same copyright terms 14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). 15 | * 16 | * Copyright remains Eric Young's, and as such any Copyright notices in 17 | * the code are not to be removed. 18 | * If this package is used in a product, Eric Young should be given attribution 19 | * as the author of the parts of the library used. 20 | * This can be in the form of a textual message at program startup or 21 | * in documentation (online or textual) provided with the package. 22 | * 23 | * Redistribution and use in source and binary forms, with or without 24 | * modification, are permitted provided that the following conditions 25 | * are met: 26 | * 1. Redistributions of source code must retain the copyright 27 | * notice, this list of conditions and the following disclaimer. 28 | * 2. Redistributions in binary form must reproduce the above copyright 29 | * notice, this list of conditions and the following disclaimer in the 30 | * documentation and/or other materials provided with the distribution. 31 | * 3. All advertising materials mentioning features or use of this software 32 | * must display the following acknowledgement: 33 | * "This product includes cryptographic software written by 34 | * Eric Young (eay@cryptsoft.com)" 35 | * The word 'cryptographic' can be left out if the rouines from the library 36 | * being used are not cryptographic related :-). 37 | * 4. If you include any Windows specific code (or a derivative thereof) from 38 | * the apps directory (application code) you must include an acknowledgement: 39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" 40 | * 41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND 42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 51 | * SUCH DAMAGE. 52 | * 53 | * The licence and distribution terms for any publically available version or 54 | * derivative of this code cannot be changed. i.e. this code cannot simply be 55 | * copied and put under another distribution licence 56 | * [including the GNU Public Licence.] 57 | */ 58 | 59 | #ifndef HEADER_BUFFER_H 60 | # define HEADER_BUFFER_H 61 | 62 | # include 63 | 64 | #ifdef __cplusplus 65 | extern "C" { 66 | #endif 67 | 68 | # include 69 | 70 | # if !defined(NO_SYS_TYPES_H) 71 | # include 72 | # endif 73 | 74 | /* Already declared in ossl_typ.h */ 75 | /* typedef struct buf_mem_st BUF_MEM; */ 76 | 77 | struct buf_mem_st { 78 | size_t length; /* current number of bytes */ 79 | char *data; 80 | size_t max; /* size of buffer */ 81 | }; 82 | 83 | BUF_MEM *BUF_MEM_new(void); 84 | void BUF_MEM_free(BUF_MEM *a); 85 | int BUF_MEM_grow(BUF_MEM *str, size_t len); 86 | int BUF_MEM_grow_clean(BUF_MEM *str, size_t len); 87 | size_t BUF_strnlen(const char *str, size_t maxlen); 88 | char *BUF_strdup(const char *str); 89 | 90 | /* 91 | * Like strndup, but in addition, explicitly guarantees to never read past the 92 | * first |siz| bytes of |str|. 93 | */ 94 | char *BUF_strndup(const char *str, size_t siz); 95 | 96 | void *BUF_memdup(const void *data, size_t siz); 97 | void BUF_reverse(unsigned char *out, const unsigned char *in, size_t siz); 98 | 99 | /* safe string functions */ 100 | size_t BUF_strlcpy(char *dst, const char *src, size_t siz); 101 | size_t BUF_strlcat(char *dst, const char *src, size_t siz); 102 | 103 | /* BEGIN ERROR CODES */ 104 | /* 105 | * The following lines are auto generated by the script mkerr.pl. Any changes 106 | * made after this point may be overwritten when the script is next run. 107 | */ 108 | void ERR_load_BUF_strings(void); 109 | 110 | /* Error codes for the BUF functions. */ 111 | 112 | /* Function codes. */ 113 | # define BUF_F_BUF_MEMDUP 103 114 | # define BUF_F_BUF_MEM_GROW 100 115 | # define BUF_F_BUF_MEM_GROW_CLEAN 105 116 | # define BUF_F_BUF_MEM_NEW 101 117 | # define BUF_F_BUF_STRDUP 102 118 | # define BUF_F_BUF_STRNDUP 104 119 | 120 | /* Reason codes. */ 121 | 122 | #ifdef __cplusplus 123 | } 124 | #endif 125 | #endif 126 | --------------------------------------------------------------------------------