Compare commits
4 Commits
unzCountEn
...
v2.1.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6b302a33b1 | ||
|
|
6128b6faf3 | ||
|
|
8e3a03d78b | ||
|
|
5b9e60e4ea |
@@ -1,5 +1,5 @@
|
||||
PODS:
|
||||
- SSZipArchive (2.1.0)
|
||||
- SSZipArchive (2.1.1)
|
||||
|
||||
DEPENDENCIES:
|
||||
- SSZipArchive (from `..`)
|
||||
@@ -9,7 +9,7 @@ EXTERNAL SOURCES:
|
||||
:path: ..
|
||||
|
||||
SPEC CHECKSUMS:
|
||||
SSZipArchive: 1e8e53dcb11bca3ded4738958dc49fc467320a14
|
||||
SSZipArchive: 14401ade5f8e82aba1ff03e9f88e9de60937ae60
|
||||
|
||||
PODFILE CHECKSUM: 5e250843c66c607960128ebfe02ab7d6569102be
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
Pod::Spec.new do |s|
|
||||
s.name = 'SSZipArchive'
|
||||
s.version = '2.1.0'
|
||||
s.version = '2.1.1'
|
||||
s.summary = 'Utility class for zipping and unzipping files on iOS, tvOS, watchOS, and Mac.'
|
||||
s.description = 'SSZipArchive is a simple utility class for zipping and unzipping files on iOS, tvOS, watchOS, and Mac.'
|
||||
s.homepage = 'https://github.com/ZipArchive/ZipArchive'
|
||||
|
||||
@@ -46,10 +46,6 @@
|
||||
|
||||
#define CRC32(c, b) ((*(pcrc_32_tab+(((uint32_t)(c) ^ (b)) & 0xff))) ^ ((c) >> 8))
|
||||
|
||||
#ifndef ZCR_SEED2
|
||||
# define ZCR_SEED2 3141592654UL /* use PI as default pattern */
|
||||
#endif
|
||||
|
||||
/***************************************************************************/
|
||||
|
||||
uint8_t decrypt_byte(uint32_t *pkeys)
|
||||
@@ -90,11 +86,10 @@ void init_keys(const char *passwd, uint32_t *pkeys, const z_crc_t *pcrc_32_tab)
|
||||
|
||||
int cryptrand(unsigned char *buf, unsigned int len)
|
||||
{
|
||||
static unsigned calls = 0;
|
||||
int rlen = 0;
|
||||
#ifdef _WIN32
|
||||
HCRYPTPROV provider;
|
||||
unsigned __int64 pentium_tsc[1];
|
||||
int rlen = 0;
|
||||
int result = 0;
|
||||
|
||||
|
||||
@@ -112,24 +107,12 @@ int cryptrand(unsigned char *buf, unsigned int len)
|
||||
QueryPerformanceCounter((LARGE_INTEGER *)pentium_tsc);
|
||||
buf[rlen] = ((unsigned char*)pentium_tsc)[rlen % 8];
|
||||
}
|
||||
#else
|
||||
int frand = open("/dev/urandom", O_RDONLY);
|
||||
if (frand != -1)
|
||||
{
|
||||
rlen = (int)read(frand, buf, len);
|
||||
close(frand);
|
||||
}
|
||||
#endif
|
||||
if (rlen < (int)len)
|
||||
{
|
||||
/* Ensure different random header each time */
|
||||
if (++calls == 1)
|
||||
srand((unsigned)(time(NULL) ^ ZCR_SEED2));
|
||||
|
||||
while (rlen < (int)len)
|
||||
buf[rlen++] = (rand() >> 7) & 0xff;
|
||||
}
|
||||
return rlen;
|
||||
#else
|
||||
arc4random_buf(buf, len);
|
||||
return len;
|
||||
#endif
|
||||
}
|
||||
|
||||
int crypthead(const char *passwd, uint8_t *buf, int buf_size, uint32_t *pkeys,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
PODS:
|
||||
- SSZipArchive (2.1.0)
|
||||
- SSZipArchive (2.1.1)
|
||||
|
||||
DEPENDENCIES:
|
||||
- SSZipArchive (from `..`)
|
||||
@@ -9,7 +9,7 @@ EXTERNAL SOURCES:
|
||||
:path: ..
|
||||
|
||||
SPEC CHECKSUMS:
|
||||
SSZipArchive: 1e8e53dcb11bca3ded4738958dc49fc467320a14
|
||||
SSZipArchive: 14401ade5f8e82aba1ff03e9f88e9de60937ae60
|
||||
|
||||
PODFILE CHECKSUM: 0dc500eb72745751ccba7677de4da5534fcef36d
|
||||
|
||||
|
||||
Reference in New Issue
Block a user