Jump to content

Recommended Posts

  • Contributor
6 minutes ago, GoldCash said:

So i use domain name http://something/patcher and than i can see what in the web but patcher dont work

Maybe your site have a redirect from http to https or something. In that case, use https link in the patcher.

Edited by TMP4
  • Contributor
20 minutes ago, GoldCash said:

Dont work ?

Give me your link in DM and I'll have a look.

Edit: @GoldCash Your patchlist.txt is wrong, you have to remove the D:/Client/ from every line.

Also when I first opened the link, it said website unavailable for like 5 second then Chrome refreshed. I'm sure there are some protection / pre-filter enabled in your webserver. I never used LiteSpeed so can't tell more.

Edited by TMP4
  • Premium
5 hours ago, GoldCash said:

So i use domain name http://something/patcher and than i can see what in the web but patcher dont work

Are u using a free storage just for test? Cuz this will not work ? I tried with a lot of free cloud storage, but nothing worked. I bought a cloud storage for 1year (cost me 12€) and it worked instantly. ?
 

Spoiler

Sry for my bad english.

 

Ulthar

Just now, Ulthar said:

Are u using a free storage just for test? Cuz this will not work ? I tried with a lot of free cloud storage, but nothing worked. I bought a cloud storage for 1year (cost me 12€) and it worked instantly. ?
 

  Reveal hidden contents

Sry for my bad english.

 

No i have hosting website

Just now, Ulthar said:

Try the @TMP4 idea ? if its not working, send me DM and i will try to help you.

I right know if i upload files to my website hosting its not work, but if i upload to my VPS Hosting this working i dont know why ?

  • 9 months later...
  • 4 months later...
On 11/13/2015 at 2:59 AM, wezt said:

Hi, try to change crc hash to md5, it helped me.

 

  Reveal hidden contents

 

In Common.cs

Add this in begging of the file:

using System.Security.Cryptography;

and after:

        public static string GetHash(string Name)
        {
            if (Name == string.Empty)
                return string.Empty;

            CRC crc = new CRC();

            string Hash = string.Empty;

            using (FileStream fileStream = File.Open(Name, FileMode.Open))
            {
                foreach (byte b in crc.ComputeHash(fileStream))
                {
                    Hash += b.ToString("x2").ToLower();
                }
            }

            return Hash;
        }

add:

        public static string CalculateMD5Hash(string Name)
        {
            if (Name == string.Empty)
                return null;

            MD5 md5 = System.Security.Cryptography.MD5.Create();

            string Hash = string.Empty;

            try
            {
                using (FileStream fileStream = File.Open(Name, FileMode.Open, FileAccess.Read, FileShare.Read))
                {
                    foreach (byte b in md5.ComputeHash(fileStream))
                    {
                        Hash += b.ToString("x2").ToLower();
                    }
                }
            }
            catch
            {
                MessageBox.Show("Can't open: " + Name);
            }

            return Hash;
        }

In FileChecker.cs find:

if (!File.Exists(file.Name) || Common.GetHash(file.Name) != file.Hash)

and replace with:

if (!File.Exists(file.Name) || Common.CalculateMD5Hash(file.Name) != file.Hash)

After these changes you'll have MD5 Patcher :)

PS: Atm I'm experiencing some problems with progress bar, will add solution if I'll find it.

 

 

 

 

Also I'd like to share php script which generate patchlist.txt (probably will be useful for someone):

  Hide contents

 

<?php
/*
Usage: Upload this file to the web-server, in folder with patchlist.txt and open it in browser.
Note: I recommend to protect this file from public usage with password (put file in folder, change output file and directory path and and use .htaccess)
*/
function list_directory($dir) {
	$file_list = array();
	$stack[] = $dir;

	while ($stack) {
		$current_dir = array_pop($stack);
		if ($dh = opendir($current_dir)) {
			while (($file = readdir($dh)) !== false) {
				if ($file !== '.' AND $file !== '..') {
					$current_file = "{$current_dir}/{$file}";
					$report = array();
					if (is_file($current_file)) {
						$file_list[] = "{$current_dir}/{$file}";
					} elseif (is_dir($current_file)) {
						$stack[] = $current_file;
						$file_list[] = "{$current_dir}/{$file}/";
					}
				}
			}
		}
	}

	return $file_list;
}

$files = list_directory('.'); // Path to directory with files
sort($files, SORT_NATURAL | SORT_FLAG_CASE);
$line = "";
foreach($files as $file)
{
	$hash = hash_file( 'crc32b', $file );
	$size = filesize($file);

	if($hash == "00000000" || preg_match("/patchlist/", $file))
		continue;

	$file_n = preg_replace("/^../","",$file);
	echo $file_n . " " . $hash . " " . $size . "<br>";
	$line .= $file_n . " " . $hash . " " . $size . "\r\n";
}

$handle = fopen("patchlist.txt", "w+"); // Path to output file
fwrite($handle, $line);
fclose($handle);
?>

 

Best Regards

Hi, I've done as indicated.
After creating the patch list and using the patcher, everything downloads perfectly.

If I close the patcher and open it up again, somehow it checks for the files and then redownloads all the files...

anyone knows how to fix this?

Edited by anton96
  • 6 months later...
  • 5 months later...
  • 3 months later...

@ TMP4 you had some temporary keys. What are the passwords? i cannot create new cause your design is fixed with this key.

“𝓐𝓵𝓵 𝔀𝓮 𝓱𝓪𝓿𝓮 𝓽𝓸 𝓭𝓮𝓬𝓲𝓭𝓮 𝓲𝓼 𝔀𝓱𝓪𝓽 𝓽𝓸 𝓭𝓸 𝔀𝓲𝓽𝓱 𝓽𝓱𝓮 𝓽𝓲𝓶𝓮 𝓽𝓱𝓪𝓽 𝓲𝓼 𝓰𝓲𝓿𝓮𝓷 𝓾𝓼.” ~ 𝓖𝓪𝓷𝓭𝓪𝓵𝓯 𝓽𝓱𝓮 𝓖𝓻𝓮𝔂

  • 3 months later...

Hey, is anyone dealing with viruses problem? When i compile it shows viruses.. Anyone have fix for this please? Here is virus total

This is the hidden content, please

i tried googling this problem and found "solution" to try turn of antivirus in pc.. which i tried and now i have still some viruses found by virustotal

This is the hidden content, please

Thanks

  • Metin2 Dev 5
  • Love 3
  • Active+ Member
5 hours ago, dexolus said:

Hey, is anyone dealing with viruses problem? When i compile it shows viruses.. Anyone have fix for this please? Here is virus total

 

Hidden Content

  • Give reaction to this post to see the hidden content.

 

i tried googling this problem and found "solution" to try turn of antivirus in pc.. which i tried and now i have still some viruses found by virustotal

 

Hidden Content

  • Give reaction to this post to see the hidden content.

 

Thanks

This is obviously just a false positive caused by how retarded heuristic detection is nowadays in antivurses.

What you're gonna do to fix this is switch target .NET framework version and simply recompile. Should do the trick.

Hey thanks for asnwering.. I tried every possible framework but still getting loads of shit around 22 Security vendors on VirusTotal sometimes less (probably depends on framework or dunno howit works) Do you have any other fix in mind? Thanks..

This is the hidden content, please
 back to this xd

Edited by dexolus
just edit for virustotal
  • Metin2 Dev 2
  • Love 4
  • 4 months later...
  • Active+ Member

Up! After creating a design and compiling multiple times, I've started to get microsoft antivirus notifications. I believe I will have issues with virus total too. Does anyone have figured it out a solution?

  • Active Member
On 11/27/2024 at 1:39 AM, KolenMG said:

Up! After creating a design and compiling multiple times, I've started to get microsoft antivirus notifications. I believe I will have issues with virus total too. Does anyone have figured it out a solution?

I don't think there is any option to fix this. In the past I was using application security certificate (it's paid option). It helps a lot.

  • Love 1
  • Active+ Member
18 hours ago, jking said:

I don't think there is any option to fix this. In the past I was using application security certificate (it's paid option). It helps a lot.

You can just report your binary to AV companies for whitelisting. No need for EV certs

  • Active Member
2 minutes ago, b6d4a82c15 said:

You can just report your binary to AV companies for whitelisting. No need for EV certs

Dont you need to do this every time you compile binary?

I took the time to make a patcher using the SHA-256 hash, which works perfectly fine, even though the one from Sanchez doesn't use this hash.
To download my files, I only use System.Net.Http in C# with HttpClient.
My patcher is compiled in .NET 6, and I integrate my DLL, which is also compiled, directly into my patcher.exe.
I just ran a VirusTotal scan on my old patcher, and it shows 0/73 detections. However, the one I'm currently modifying sometimes generates 1/73 detections. I'll attach an image of the VirusTotal results for reference.

  • Active+ Member
On 11/29/2024 at 3:24 PM, jking said:

Dont you need to do this every time you compile binary?

Yes since the hash changes but well written patcher doesnt really need recompilation. You just compile it once and leave it as is. Any dynamic content such as image sliders or patch list can be pulled dynamically from your remote server

  • 4 months later...

Hello guys, 

I am trying install it but i get this error:

https://metin2.download/picture/Xdx566x0Hc5L8cnK0fauwQrtxftr15bM/.jpg

 

What am I doing wrong? I change the url to: https://mysite.com/patch

Is anyone could help me  I would be grateful.

Edited by Metin2 Dev International
Core X - External 2 Internal

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.