44
55#define VERSION "2.2.0 BETA"
66
7+ #include "path.h"
78#include "defines.h"
89#include "offsets.h"
910
@@ -460,7 +461,7 @@ int set_target_id(char *tid) {
460461 snprintf (buffer , buffer_size , "Kratos" );
461462 break ;
462463 default :
463- printf_notification ("Spoofing: UNKNOWN...\nCheck your `hen.ini ` file" );
464+ printf_notification ("Spoofing: UNKNOWN...\nCheck your `" HEN_INI " ` file" );
464465 return -1 ;
465466 }
466467
@@ -485,9 +486,9 @@ static void write_blob(const char* path, const void* blob, const size_t blobsz)
485486}
486487
487488static void upload_prx_to_disk (void ) {
488- write_blob ("/user/data/hen /plugin_bootloader.prx" , plugin_bootloader_prx , plugin_bootloader_prx_len );
489- write_blob ("/user/data/hen /plugin_loader.prx" , plugin_loader_prx , plugin_loader_prx_len );
490- write_blob ("/user/data/hen /plugin_server.prx" , plugin_server_prx , plugin_server_prx_len );
489+ write_blob ("/user/" BASE_PATH " /plugin_bootloader.prx" , plugin_bootloader_prx , plugin_bootloader_prx_len );
490+ write_blob ("/user/" BASE_PATH " /plugin_loader.prx" , plugin_loader_prx , plugin_loader_prx_len );
491+ write_blob ("/user/" BASE_PATH " /plugin_server.prx" , plugin_server_prx , plugin_server_prx_len );
491492}
492493
493494static void kill_proc (const char * proc ) {
@@ -505,7 +506,7 @@ static void kill_proc(const char* proc) {
505506
506507
507508static void upload_ver (void ) {
508- write_blob ("/user/data/hen /ps4hen_version.txt" , VERSION , sizeof (VERSION ) - 1 );
509+ write_blob ("/user/" BASE_PATH " /ps4hen_version.txt" , VERSION , sizeof (VERSION ) - 1 );
509510}
510511
511512int _main (struct thread * td ) {
@@ -537,23 +538,23 @@ int _main(struct thread *td) {
537538 memset (& config , '\0' , sizeof (config ));
538539 config .disable_aslr = DEFAULT_DISABLE_ASLR ;
539540 config .nobd_patches = DEFAULT_NOBD_PATCHES ;
540- if (file_exists ("/mnt/usb0/hen.ini" )) {
541- if (cfg_parse ("/mnt/usb0/hen.ini" , config_handler , & config ) < 0 ) {
542- printf_notification ("ERROR: Unable to load `/mnt/usb0/hen.ini `" );
541+ if (file_exists (USB_INI_PATH )) {
542+ if (cfg_parse (USB_INI_PATH , config_handler , & config ) < 0 ) {
543+ printf_notification ("ERROR: Unable to load `" USB_INI_PATH " `" );
543544 // Restore defaults in case one of them changed for some reason...
544545 memset (& config , '\0' , sizeof (config ));
545546 config .disable_aslr = DEFAULT_DISABLE_ASLR ;
546547 config .nobd_patches = DEFAULT_NOBD_PATCHES ;
547548 } else {
548- if (!file_compare ("/mnt/usb0/hen/hen.ini" , "/data/hen/hen.ini" )) {
549- unlink ("/data/hen/hen.ini" );
550- copy_file ("/mnt/usb0/hen/hen.ini" , "/data/hen/hen.ini" );
549+ if (!file_compare (USB_INI_PATH , HDD_INI_PATH )) {
550+ unlink (HDD_INI_PATH );
551+ copy_file (USB_INI_PATH , HDD_INI_PATH );
551552 }
552553 config_loaded = 1 ;
553554 }
554- } else if (file_exists ("/data/hen/hen.ini" )) {
555- if (cfg_parse ("/data/hen/hen.ini" , config_handler , & config ) < 0 ) {
556- printf_notification ("ERROR: Unable to load `/data/hen/hen.ini `" );
555+ } else if (file_exists (HDD_INI_PATH )) {
556+ if (cfg_parse (HDD_INI_PATH , config_handler , & config ) < 0 ) {
557+ printf_notification ("ERROR: Unable to load `" HDD_INI_PATH " `" );
557558 // Restore defaults in case one of them changed for some reason...
558559 memset (& config , '\0' , sizeof (config ));
559560 config .disable_aslr = DEFAULT_DISABLE_ASLR ;
0 commit comments