diff options
author | Duarte Duarte <dnpd.dd@gmail.com> | 2014-11-09 16:52:49 +0000 |
---|---|---|
committer | Duarte Duarte <dnpd.dd@gmail.com> | 2014-11-09 16:52:49 +0000 |
commit | 60eaa06d208cad87bd83f2e4932086207456ba22 (patch) | |
tree | f876c40dfe1f4c21e627d5dbb2b4b04fd2314a5f /src/tools/connection_patcher/Program.cpp | |
parent | 543bea32e16bbe317171d24888a5f0c751ea19e8 (diff) | |
parent | 20d1d9d99759369c99f6c25d8e3b8300bff2b8c7 (diff) |
Merge pull request #13521 from TrinityCore/connection_patcher/fix_osx__document__fix_nonexistant_file_exception
Connection patcher: fix osx, document, fix nonexistant file exception
Diffstat (limited to 'src/tools/connection_patcher/Program.cpp')
-rw-r--r-- | src/tools/connection_patcher/Program.cpp | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/src/tools/connection_patcher/Program.cpp b/src/tools/connection_patcher/Program.cpp index a613485f839..56007232d20 100644 --- a/src/tools/connection_patcher/Program.cpp +++ b/src/tools/connection_patcher/Program.cpp @@ -48,7 +48,9 @@ namespace Connection_Patcher std::cout << "Patching module...\n"; Patcher patcher(file); + std::cout << "patching Password\n"; + // if (Authentication::ServerSignature::ClientValidateProof(x)) to if (true) patcher.Patch(PATCH::Password(), PATTERN::Password()); std::string const moduleName(Helper::GetFileChecksum(patcher.binary) + ".auth"); @@ -58,7 +60,8 @@ namespace Connection_Patcher if (!fs::exists(modulePath)) fs::create_directories(modulePath); - fs::permissions(modulePath / moduleName, fs::add_perms | fs::others_write | fs::group_write | fs::owner_write); + if (fs::exists(modulePath / modulePath)) + fs::permissions(modulePath / moduleName, fs::add_perms | fs::others_write | fs::group_write | fs::owner_write); patcher.Finish(modulePath / moduleName); fs::permissions(modulePath / moduleName, fs::remove_perms | fs::others_write | fs::group_write | fs::owner_write); @@ -82,13 +85,24 @@ namespace Connection_Patcher void do_patches(Patcher* patcher, boost::filesystem::path output) { std::cout << "patching Portal\n"; + // '.logon.battle.net' -> '' to allow for set portal 'host' patcher->Patch(Patches::Common::Portal(), Patterns::Common::Portal()); + std::cout << "patching redirect RSA Modulus\n"; + // public component of connection signing key to use known key pair patcher->Patch(Patches::Common::Modulus(), Patterns::Common::Modulus()); + std::cout << "patching BNet\n"; + // hardcode 213.248.127.130 in IP6::Address::Address(IP4::Address::Address const&) + // used in Creep::Layer::Authentication::Online(), which overwrites GameStream::Connection::GetAddressRemote() + // to avoid CRYPT_SERVER_ADDRESS_IPV6 check in module patcher->Patch(PATCH::BNet(), PATTERN::BNet()); + std::cout << "patching Signature\n"; + // if (Authentication::ModuleSignature::Validator::IsValid(x)) to if (true) in + // Creep::Instance::LoadModule() to allow for unsigned auth module patcher->Patch(PATCH::Signature(), PATTERN::Signature()); + patcher->Finish(output); std::cout << "Patching done.\n"; @@ -180,7 +194,7 @@ int main(int argc, char** argv) do_patches<Patches::Mac::x64, Patterns::Mac::x64> (&patcher, renamed_binary_path); - do_module<Patches::Windows::x64, Patterns::Windows::x64> + do_module<Patches::Mac::x64, Patterns::Mac::x64> ( "97eeb2e28e9e56ed6a22d09f44e2ff43c93315e006bbad43bafc0defaa6f50ae.auth" , "/Users/Shared/Blizzard/Battle.net/Cache/" ); |