#define hc_thread_mutex_delete(m) pthread_mutex_destroy (&m)
#endif
-#ifdef OSX
+#ifdef __APPLE__
typedef struct cpu_set
{
uint32_t count;
exit (-1); \
} else { \
log_info ("WARNING: %s is missing from %s shared library.", #name, #libname); \
- return (-1); \
+ return -1; \
} \
} \
}
exit (-1); \
} else { \
log_info ("WARNING: %s is missing from %s shared library.", #name, #libname); \
- return (-1); \
+ return -1; \
} \
} \
}
exit (-1); \
} else { \
log_error ("WARNING: %s at address %08x is missing from %s shared library.", #name, addr, #libname); \
- return (-1); \
+ return -1; \
} \
}
#define CL_VENDOR_NV "NVIDIA Corporation"
#define CL_VENDOR_POCL "The pocl project"
-#define VENDOR_ID_AMD (1 << 0)
-#define VENDOR_ID_APPLE (1 << 1)
-#define VENDOR_ID_INTEL_BEIGNET (1 << 2)
-#define VENDOR_ID_INTEL_SDK (1 << 3)
-#define VENDOR_ID_MESA (1 << 4)
-#define VENDOR_ID_NV (1 << 5)
-#define VENDOR_ID_POCL (1 << 6)
-#define VENDOR_ID_AMD_USE_INTEL (1 << 7)
-#define VENDOR_ID_GENERIC (1 << 31)
+#define VENDOR_ID_AMD (1u << 0)
+#define VENDOR_ID_APPLE (1u << 1)
+#define VENDOR_ID_INTEL_BEIGNET (1u << 2)
+#define VENDOR_ID_INTEL_SDK (1u << 3)
+#define VENDOR_ID_MESA (1u << 4)
+#define VENDOR_ID_NV (1u << 5)
+#define VENDOR_ID_POCL (1u << 6)
+#define VENDOR_ID_AMD_USE_INTEL (1u << 7)
+#define VENDOR_ID_GENERIC (1u << 31)
#define BLOCK_SIZE 64
#define HT_00140 "sha1($salt.unicode($pass))"
#define HT_00150 "HMAC-SHA1 (key = $pass)"
#define HT_00160 "HMAC-SHA1 (key = $salt)"
-#define HT_00190 "sha1(LinkedIn)"
#define HT_00200 "MySQL323"
#define HT_00300 "MySQL4.1/MySQL5"
#define HT_00400 "phpass, MD5(Wordpress), MD5(phpBB3), MD5(Joomla)"
#define DISPLAY_LEN_MAX_150 40 + 1 + 51
#define DISPLAY_LEN_MIN_150H 40 + 1 + 0
#define DISPLAY_LEN_MAX_150H 40 + 1 + 102
-#define DISPLAY_LEN_MIN_190 40
-#define DISPLAY_LEN_MAX_190 40
#define DISPLAY_LEN_MIN_200 16
#define DISPLAY_LEN_MAX_200 16
#define DISPLAY_LEN_MIN_300 40
#define KERN_TYPE_SHA1_SLTPWU 140
#define KERN_TYPE_HMACSHA1_PW 150
#define KERN_TYPE_HMACSHA1_SLT 160
-#define KERN_TYPE_SHA1_LINKEDIN 190
#define KERN_TYPE_MYSQL 200
#define KERN_TYPE_MYSQL41 300
#define KERN_TYPE_PHPASS 400
int osx512_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
int phpass_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
int sha1_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
-int sha1linkedin_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
int sha1b64_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
int sha1b64s_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
int sha1s_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
int veracrypt_parse_hash_655331 (char *input_buf, uint input_len, hash_t *hash_buf);
int win8phone_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf);
+void naive_replace (char *s, const u8 key_char, const u8 replace_char);
+void naive_escape (char *s, size_t s_max, const u8 key_char, const u8 escape_char);
void load_kernel (const char *kernel_file, int num_devices, size_t *kernel_lengths, const u8 **kernel_sources);
void writeProgramBin (char *dst, u8 *binary, size_t binary_size);