Skip to content

Commit b0732f4

Browse files
authored
Merge pull request crazytuzi#6 from crazytuzi/CustomPath
IOS Library Path
2 parents 5d30e7d + c869e88 commit b0732f4

366 files changed

Lines changed: 27689 additions & 32355 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.gitattributes‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ios/Python/libPython.a filter=lfs diff=lfs merge=lfs -text

‎Source/UnrealEnginePython/UnrealEnginePython.Build.cs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ public UnrealEnginePython(TargetInfo Target)
295295
}
296296
else if (Target.Platform == UnrealTargetPlatform.IOS)
297297
{
298-
string PythonIOSLibsDirectory = Path.Combine(PluginDirectory, "python", "python36", "ios");
298+
string PythonIOSLibsDirectory = Path.Combine(PluginDirectory, "ios");
299299

300300
string includePath = Path.Combine(PythonIOSLibsDirectory, "Python", "Headers");
301301
PublicIncludePaths.Add(includePath);
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
This file is part of bzip2/libbzip2, a program and library for
99
lossless, block-sorting data compression.
1010
11-
bzip2/libbzip2 version 1.0.6 of 6 September 2010
12-
Copyright (C) 1996-2010 Julian Seward <jseward@bzip.org>
11+
bzip2/libbzip2 version 1.0.8 of 13 July 2019
12+
Copyright (C) 1996-2019 Julian Seward <jseward@acm.org>
1313
1414
Please read the WARNING, DISCLAIMER and PATENTS sections in the
1515
README file.

‎ios/BZip2/libbzip2.a‎

1.17 MB
Binary file not shown.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/*
2+
* Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
3+
*
4+
* Licensed under the OpenSSL license (the "License"). You may not use
5+
* this file except in compliance with the License. You can obtain a copy
6+
* in the file LICENSE in the source distribution or at
7+
* https://www.openssl.org/source/license.html
8+
*/
9+
10+
/*
11+
* This file is only used by HP C on VMS, and is included automatically
12+
* after each header file from this directory
13+
*/
14+
15+
/* restore state. Must correspond to the save in __decc_include_prologue.h */
16+
#pragma names restore
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/*
2+
* Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
3+
*
4+
* Licensed under the OpenSSL license (the "License"). You may not use
5+
* this file except in compliance with the License. You can obtain a copy
6+
* in the file LICENSE in the source distribution or at
7+
* https://www.openssl.org/source/license.html
8+
*/
9+
10+
/*
11+
* This file is only used by HP C on VMS, and is included automatically
12+
* after each header file from this directory
13+
*/
14+
15+
/* save state */
16+
#pragma names save
17+
/* have the compiler shorten symbols larger than 31 chars to 23 chars
18+
* followed by a 8 hex char CRC
19+
*/
20+
#pragma names as_is,shortened

‎ios/OpenSSL/Headers/crypto/aria.h‎

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
/*
2+
* Copyright 2006-2018 The OpenSSL Project Authors. All Rights Reserved.
3+
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
4+
*
5+
* Licensed under the OpenSSL license (the "License"). You may not use
6+
* this file except in compliance with the License. You can obtain a copy
7+
* in the file LICENSE in the source distribution or at
8+
* https://www.openssl.org/source/license.html
9+
*/
10+
11+
/* Copyright (c) 2017 National Security Research Institute. All rights reserved. */
12+
13+
#ifndef OSSL_CRYPTO_ARIA_H
14+
# define OSSL_CRYPTO_ARIA_H
15+
16+
# include <openssl/opensslconf.h>
17+
18+
# ifdef OPENSSL_NO_ARIA
19+
# error ARIA is disabled.
20+
# endif
21+
22+
# define ARIA_ENCRYPT 1
23+
# define ARIA_DECRYPT 0
24+
25+
# define ARIA_BLOCK_SIZE 16 /* Size of each encryption/decryption block */
26+
# define ARIA_MAX_KEYS 17 /* Number of keys needed in the worst case */
27+
28+
typedef union {
29+
unsigned char c[ARIA_BLOCK_SIZE];
30+
unsigned int u[ARIA_BLOCK_SIZE / sizeof(unsigned int)];
31+
} ARIA_u128;
32+
33+
typedef unsigned char ARIA_c128[ARIA_BLOCK_SIZE];
34+
35+
struct aria_key_st {
36+
ARIA_u128 rd_key[ARIA_MAX_KEYS];
37+
unsigned int rounds;
38+
};
39+
typedef struct aria_key_st ARIA_KEY;
40+
41+
42+
int aria_set_encrypt_key(const unsigned char *userKey, const int bits,
43+
ARIA_KEY *key);
44+
int aria_set_decrypt_key(const unsigned char *userKey, const int bits,
45+
ARIA_KEY *key);
46+
47+
void aria_encrypt(const unsigned char *in, unsigned char *out,
48+
const ARIA_KEY *key);
49+
50+
#endif

‎ios/OpenSSL/Headers/crypto/asn1.h‎

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
/*
2+
* Copyright 2015-2018 The OpenSSL Project Authors. All Rights Reserved.
3+
*
4+
* Licensed under the OpenSSL license (the "License"). You may not use
5+
* this file except in compliance with the License. You can obtain a copy
6+
* in the file LICENSE in the source distribution or at
7+
* https://www.openssl.org/source/license.html
8+
*/
9+
10+
/* Internal ASN1 structures and functions: not for application use */
11+
12+
/* ASN1 public key method structure */
13+
14+
struct evp_pkey_asn1_method_st {
15+
int pkey_id;
16+
int pkey_base_id;
17+
unsigned long pkey_flags;
18+
char *pem_str;
19+
char *info;
20+
int (*pub_decode) (EVP_PKEY *pk, X509_PUBKEY *pub);
21+
int (*pub_encode) (X509_PUBKEY *pub, const EVP_PKEY *pk);
22+
int (*pub_cmp) (const EVP_PKEY *a, const EVP_PKEY *b);
23+
int (*pub_print) (BIO *out, const EVP_PKEY *pkey, int indent,
24+
ASN1_PCTX *pctx);
25+
int (*priv_decode) (EVP_PKEY *pk, const PKCS8_PRIV_KEY_INFO *p8inf);
26+
int (*priv_encode) (PKCS8_PRIV_KEY_INFO *p8, const EVP_PKEY *pk);
27+
int (*priv_print) (BIO *out, const EVP_PKEY *pkey, int indent,
28+
ASN1_PCTX *pctx);
29+
int (*pkey_size) (const EVP_PKEY *pk);
30+
int (*pkey_bits) (const EVP_PKEY *pk);
31+
int (*pkey_security_bits) (const EVP_PKEY *pk);
32+
int (*param_decode) (EVP_PKEY *pkey,
33+
const unsigned char **pder, int derlen);
34+
int (*param_encode) (const EVP_PKEY *pkey, unsigned char **pder);
35+
int (*param_missing) (const EVP_PKEY *pk);
36+
int (*param_copy) (EVP_PKEY *to, const EVP_PKEY *from);
37+
int (*param_cmp) (const EVP_PKEY *a, const EVP_PKEY *b);
38+
int (*param_print) (BIO *out, const EVP_PKEY *pkey, int indent,
39+
ASN1_PCTX *pctx);
40+
int (*sig_print) (BIO *out,
41+
const X509_ALGOR *sigalg, const ASN1_STRING *sig,
42+
int indent, ASN1_PCTX *pctx);
43+
void (*pkey_free) (EVP_PKEY *pkey);
44+
int (*pkey_ctrl) (EVP_PKEY *pkey, int op, long arg1, void *arg2);
45+
/* Legacy functions for old PEM */
46+
int (*old_priv_decode) (EVP_PKEY *pkey,
47+
const unsigned char **pder, int derlen);
48+
int (*old_priv_encode) (const EVP_PKEY *pkey, unsigned char **pder);
49+
/* Custom ASN1 signature verification */
50+
int (*item_verify) (EVP_MD_CTX *ctx, const ASN1_ITEM *it, void *asn,
51+
X509_ALGOR *a, ASN1_BIT_STRING *sig, EVP_PKEY *pkey);
52+
int (*item_sign) (EVP_MD_CTX *ctx, const ASN1_ITEM *it, void *asn,
53+
X509_ALGOR *alg1, X509_ALGOR *alg2,
54+
ASN1_BIT_STRING *sig);
55+
int (*siginf_set) (X509_SIG_INFO *siginf, const X509_ALGOR *alg,
56+
const ASN1_STRING *sig);
57+
/* Check */
58+
int (*pkey_check) (const EVP_PKEY *pk);
59+
int (*pkey_public_check) (const EVP_PKEY *pk);
60+
int (*pkey_param_check) (const EVP_PKEY *pk);
61+
/* Get/set raw private/public key data */
62+
int (*set_priv_key) (EVP_PKEY *pk, const unsigned char *priv, size_t len);
63+
int (*set_pub_key) (EVP_PKEY *pk, const unsigned char *pub, size_t len);
64+
int (*get_priv_key) (const EVP_PKEY *pk, unsigned char *priv, size_t *len);
65+
int (*get_pub_key) (const EVP_PKEY *pk, unsigned char *pub, size_t *len);
66+
} /* EVP_PKEY_ASN1_METHOD */ ;
67+
68+
DEFINE_STACK_OF_CONST(EVP_PKEY_ASN1_METHOD)
69+
70+
extern const EVP_PKEY_ASN1_METHOD cmac_asn1_meth;
71+
extern const EVP_PKEY_ASN1_METHOD dh_asn1_meth;
72+
extern const EVP_PKEY_ASN1_METHOD dhx_asn1_meth;
73+
extern const EVP_PKEY_ASN1_METHOD dsa_asn1_meths[5];
74+
extern const EVP_PKEY_ASN1_METHOD eckey_asn1_meth;
75+
extern const EVP_PKEY_ASN1_METHOD ecx25519_asn1_meth;
76+
extern const EVP_PKEY_ASN1_METHOD ecx448_asn1_meth;
77+
extern const EVP_PKEY_ASN1_METHOD ed25519_asn1_meth;
78+
extern const EVP_PKEY_ASN1_METHOD ed448_asn1_meth;
79+
extern const EVP_PKEY_ASN1_METHOD sm2_asn1_meth;
80+
extern const EVP_PKEY_ASN1_METHOD poly1305_asn1_meth;
81+
82+
extern const EVP_PKEY_ASN1_METHOD hmac_asn1_meth;
83+
extern const EVP_PKEY_ASN1_METHOD rsa_asn1_meths[2];
84+
extern const EVP_PKEY_ASN1_METHOD rsa_pss_asn1_meth;
85+
extern const EVP_PKEY_ASN1_METHOD siphash_asn1_meth;
86+
87+
/*
88+
* These are used internally in the ASN1_OBJECT to keep track of whether the
89+
* names and data need to be free()ed
90+
*/
91+
# define ASN1_OBJECT_FLAG_DYNAMIC 0x01/* internal use */
92+
# define ASN1_OBJECT_FLAG_CRITICAL 0x02/* critical x509v3 object id */
93+
# define ASN1_OBJECT_FLAG_DYNAMIC_STRINGS 0x04/* internal use */
94+
# define ASN1_OBJECT_FLAG_DYNAMIC_DATA 0x08/* internal use */
95+
struct asn1_object_st {
96+
const char *sn, *ln;
97+
int nid;
98+
int length;
99+
const unsigned char *data; /* data remains const after init */
100+
int flags; /* Should we free this one */
101+
};
102+
103+
/* ASN1 print context structure */
104+
105+
struct asn1_pctx_st {
106+
unsigned long flags;
107+
unsigned long nm_flags;
108+
unsigned long cert_flags;
109+
unsigned long oid_flags;
110+
unsigned long str_flags;
111+
} /* ASN1_PCTX */ ;
112+
113+
int asn1_d2i_read_bio(BIO *in, BUF_MEM **pb);

‎ios/OpenSSL/Headers/crypto/async.h‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
/*
2+
* Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
3+
*
4+
* Licensed under the OpenSSL license (the "License"). You may not use
5+
* this file except in compliance with the License. You can obtain a copy
6+
* in the file LICENSE in the source distribution or at
7+
* https://www.openssl.org/source/license.html
8+
*/
9+
10+
#include <openssl/async.h>
11+
12+
int async_init(void);
13+
void async_deinit(void);
14+
void async_delete_thread_state(void);
15+

‎ios/OpenSSL/Headers/crypto/bn.h‎

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
/*
2+
* Copyright 2014-2018 The OpenSSL Project Authors. All Rights Reserved.
3+
*
4+
* Licensed under the OpenSSL license (the "License"). You may not use
5+
* this file except in compliance with the License. You can obtain a copy
6+
* in the file LICENSE in the source distribution or at
7+
* https://www.openssl.org/source/license.html
8+
*/
9+
10+
#ifndef OSSL_CRYPTO_BN_H
11+
# define OSSL_CRYPTO_BN_H
12+
13+
# include <openssl/bn.h>
14+
# include <limits.h>
15+
16+
BIGNUM *bn_wexpand(BIGNUM *a, int words);
17+
BIGNUM *bn_expand2(BIGNUM *a, int words);
18+
19+
void bn_correct_top(BIGNUM *a);
20+
21+
/*
22+
* Determine the modified width-(w+1) Non-Adjacent Form (wNAF) of 'scalar'.
23+
* This is an array r[] of values that are either zero or odd with an
24+
* absolute value less than 2^w satisfying scalar = \sum_j r[j]*2^j where at
25+
* most one of any w+1 consecutive digits is non-zero with the exception that
26+
* the most significant digit may be only w-1 zeros away from that next
27+
* non-zero digit.
28+
*/
29+
signed char *bn_compute_wNAF(const BIGNUM *scalar, int w, size_t *ret_len);
30+
31+
int bn_get_top(const BIGNUM *a);
32+
33+
int bn_get_dmax(const BIGNUM *a);
34+
35+
/* Set all words to zero */
36+
void bn_set_all_zero(BIGNUM *a);
37+
38+
/*
39+
* Copy the internal BIGNUM words into out which holds size elements (and size
40+
* must be bigger than top)
41+
*/
42+
int bn_copy_words(BN_ULONG *out, const BIGNUM *in, int size);
43+
44+
BN_ULONG *bn_get_words(const BIGNUM *a);
45+
46+
/*
47+
* Set the internal data words in a to point to words which contains size
48+
* elements. The BN_FLG_STATIC_DATA flag is set
49+
*/
50+
void bn_set_static_words(BIGNUM *a, const BN_ULONG *words, int size);
51+
52+
/*
53+
* Copy words into the BIGNUM |a|, reallocating space as necessary.
54+
* The negative flag of |a| is not modified.
55+
* Returns 1 on success and 0 on failure.
56+
*/
57+
/*
58+
* |num_words| is int because bn_expand2 takes an int. This is an internal
59+
* function so we simply trust callers not to pass negative values.
60+
*/
61+
int bn_set_words(BIGNUM *a, const BN_ULONG *words, int num_words);
62+
63+
/*
64+
* Some BIGNUM functions assume most significant limb to be non-zero, which
65+
* is customarily arranged by bn_correct_top. Output from below functions
66+
* is not processed with bn_correct_top, and for this reason it may not be
67+
* returned out of public API. It may only be passed internally into other
68+
* functions known to support non-minimal or zero-padded BIGNUMs. Even
69+
* though the goal is to facilitate constant-time-ness, not each subroutine
70+
* is constant-time by itself. They all have pre-conditions, consult source
71+
* code...
72+
*/
73+
int bn_mul_mont_fixed_top(BIGNUM *r, const BIGNUM *a, const BIGNUM *b,
74+
BN_MONT_CTX *mont, BN_CTX *ctx);
75+
int bn_to_mont_fixed_top(BIGNUM *r, const BIGNUM *a, BN_MONT_CTX *mont,
76+
BN_CTX *ctx);
77+
int bn_from_mont_fixed_top(BIGNUM *r, const BIGNUM *a, BN_MONT_CTX *mont,
78+
BN_CTX *ctx);
79+
int bn_mod_add_fixed_top(BIGNUM *r, const BIGNUM *a, const BIGNUM *b,
80+
const BIGNUM *m);
81+
int bn_mod_sub_fixed_top(BIGNUM *r, const BIGNUM *a, const BIGNUM *b,
82+
const BIGNUM *m);
83+
int bn_mul_fixed_top(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, BN_CTX *ctx);
84+
int bn_sqr_fixed_top(BIGNUM *r, const BIGNUM *a, BN_CTX *ctx);
85+
int bn_lshift_fixed_top(BIGNUM *r, const BIGNUM *a, int n);
86+
int bn_rshift_fixed_top(BIGNUM *r, const BIGNUM *a, int n);
87+
int bn_div_fixed_top(BIGNUM *dv, BIGNUM *rem, const BIGNUM *m,
88+
const BIGNUM *d, BN_CTX *ctx);
89+
90+
#endif

0 commit comments

Comments
 (0)