show all fans in hwmon output

This commit is contained in:
Gabriele Gristina
2021-06-19 20:32:07 +02:00
parent 65b41fcb8f
commit 3a6481da4e
9 changed files with 83 additions and 32 deletions
+2 -1
View File
@@ -18,6 +18,7 @@
#define KERNEL_INDEX_SMC 2
#define DATATYPE_FPE2 "fpe2"
#define DATATYPE_FLT "flt "
#define DATATYPE_UINT8 "ui8 "
#define DATATYPE_UINT16 "ui16"
#define DATATYPE_UINT32 "ui32"
@@ -119,7 +120,7 @@ kern_return_t hm_IOKIT_SMCReadKey (UInt32Char_t key, SMCVal_t *val, io_connect_t
int hm_IOKIT_SMCGetSensorGraphicHot (void *hashcat_ctx);
int hm_IOKIT_SMCGetTemperature (void *hashcat_ctx, char *key, double *temp);
bool hm_IOKIT_SMCGetFanRPM (char *key, io_connect_t conn, float *ret);
int hm_IOKIT_get_fan_speed_current (void *hashcat_ctx, int *fan_speed);
int hm_IOKIT_get_fan_speed_current (void *hashcat_ctx, char *fan_speed_buf);
bool iokit_init (void *hashcat_ctx);
bool iokit_close (void *hashcat_ctx);
#endif // __APPLE__
+3
View File
@@ -16,6 +16,9 @@ int hm_get_threshold_shutdown_with_devices_idx (hashcat_ctx_t *hashcat_ctx, cons
int hm_get_temperature_with_devices_idx (hashcat_ctx_t *hashcat_ctx, const int backend_device_idx);
int hm_get_fanpolicy_with_devices_idx (hashcat_ctx_t *hashcat_ctx, const int backend_device_idx);
int hm_get_fanspeed_with_devices_idx (hashcat_ctx_t *hashcat_ctx, const int backend_device_idx);
#if defined(__APPLE__)
int hm_get_fanspeed_apple (hashcat_ctx_t *hashcat_ctx, char *fan_speed_buf);
#endif
int hm_get_buslanes_with_devices_idx (hashcat_ctx_t *hashcat_ctx, const int backend_device_idx);
int hm_get_utilization_with_devices_idx (hashcat_ctx_t *hashcat_ctx, const int backend_device_idx);
int hm_get_memoryspeed_with_devices_idx (hashcat_ctx_t *hashcat_ctx, const int backend_device_idx);
+3
View File
@@ -98,6 +98,9 @@ char *status_get_brain_link_send_bytes_sec_dev (const hashcat_ctx_t *hash
char *status_get_brain_rx_all (const hashcat_ctx_t *hashcat_ctx);
char *status_get_brain_tx_all (const hashcat_ctx_t *hashcat_ctx);
#endif
#if defined(__APPLE__)
char *status_get_hwmon_fan_dev (const hashcat_ctx_t *hashcat_ctx);
#endif
char *status_get_hwmon_dev (const hashcat_ctx_t *hashcat_ctx, const int backend_devices_idx);
int status_get_corespeed_dev (const hashcat_ctx_t *hashcat_ctx, const int backend_devices_idx);
int status_get_memoryspeed_dev (const hashcat_ctx_t *hashcat_ctx, const int backend_devices_idx);
+3
View File
@@ -2251,6 +2251,9 @@ typedef struct device_info
double exec_msec_dev;
char *speed_sec_dev;
char *guess_candidates_dev;
#if defined(__APPLE__)
char *hwmon_fan_dev;
#endif
char *hwmon_dev;
int corespeed_dev;
int memoryspeed_dev;