Giter Site home page Giter Site logo

winrar-keygen's Introduction

WinRAR Keygen

WinRAR Keygen

Principle of WinRAR key generation

Issues License

简体中文 | English

1. What is WinRAR?

WinRAR is a trialware file archiver utility for Windows, developed by Eugene Roshal of win.rar GmbH.

It can create and view archives in RAR or ZIP file formats and unpack numerous archive file formats.

WinRAR is not a free software. If you want to use it, you should pay to RARLAB and then you will get a license file named rarreg.key.

This repository will tell you how WinRAR license file "rarreg.key" is generated.

2. How is "rarreg.key" generated?

See here.

3. How to use?

There are several ways to use it.

3.1 Encoding

WinRAR Keygen supports ASCII, ANSI and UTF-8 encoding types, the corresponding supported characters are listed in the table below.

Note

The default is utf8, but you can specify the encoding as ascii or ansi.

Encoding Supported Characters Character Examples
ascii Only full ASCII characters are supported.
ansi There is no one fixed ANSI code, usually Windows-1252, but other local codes are also possible.
utf8 Support full UTF-8 encoded characters. ASCII characters, English, 简体中文, 繁體中文, Deutsch, Français, Русский, Italiano, 日本語, 한국어, Lengua española, Ελληνική γλώσσα, et al.

3.2 License type

There are two types of WinRAR licenses, rarreg.key and rarkey.rar, which differ only in their import.

rarreg.key rarkey.rar
Drag to import or place in a location Double-click to run automatic import

If you are unable to drag, you can try to put the rarreg.key in the following directory.

C:\Users\yourname\AppData\Roaming\WinRAR\rarreg.key

You can also compress rarreg.key into rarkey.rar and double-click it to run it, and the license import will take place automatically.

4. Use Github Actions

Click to expand

The new workflow can easily help you generate a license, you just need to follow these steps.

Your Username and License Name will appear in the actions log, if you don't want to give out this information, see 5. Using Github Actions with secrets.

4.1 Fork

Fork this repo.

Fork

Fork

4.2 Allow fork repo to run workflows

Go back to the repo you just forked and click Actions to allow Workflows to run in your forked repo.

Workflow

Workflow

4.3 Run workflow

After allowing the workflow, go to Actions > WinRAR Keygen > Run workflow and fill in the information to start generating.

For the difference of license encoding, please refer to 3.1 Encoding.

Secrets

Secrets

After running successfully, open the corresponding task and select rarreg_file to download.

File retention 90 days.

Download

Download

Extract rarreg_file.zip to get rarreg.key and drag to import into WinRAR. You can also compress rarreg.key into rarkey.rar, then double-click it to run it, and the license import will be done automatically.

If you get an invalid key, please check the specific solution.

5. Use Github Actions with secrets

Click to expand

Using secrets can help you hide license information.

5.1 Fork

Fork this repo.

Fork

Fork

5.2 Allow fork repo to run workflows

Go back to the repo you just forked and click Actions to allow Workflows to run in your forked repo.

Workflow

Workflow

5.3 Create secrets

After allowing the workflow, go to Settings > Secrets and variables > Actions > New repository secret to create a secret.

Secrets

Secrets

Create three secrets with the names TEXT1, TEXT2 and PWD and fill in the relevant values.

The value filled in should be consistent with the type of code you have chosen.

Secrets Name Explanation
TEXT1 Your Name
TEXT2 Your License Name
PWD 7-Zip Password

Add Secrets

Add Secrets

Once created, you will see it.

Secrets Repo

Secrets Repo

5.4 Run workflow

Go to Actions and select WinRAR Keygen with secrets to run workflow manually.

For the difference of license encoding, please refer to 3.1 Encoding.

Run

Run

After running successfully, open the corresponding task and select rarreg_file to download.

File retained for 1 day only.

Download

Download

Extract rarreg_file.zip to get rarreg.7z, unzip it with the password to get rarreg.key, then drag and drop to import into WinRAR. You can also compress rarreg.key into rarkey.rar, then double-click it to run it, and the license import will be done automatically.

If you get an invalid key, please check the specific solution.

6. Build in Visual Studio

Click to expand

I recommend using the Github Actions, but you can still do your own compilation.

If you don't want to compile it yourself, you can also go to the release page to get winrar-keygen.exe.

6.1 Prerequisites

  1. Please make sure that you have Visual Studio 2022. Because this is a VS2022 project. If you are still using Visual Studio 2019, you can find projects for VS2019 in the vs2019 branch, but this branch will no longer be maintained.

  2. Please make sure you have installed vcpkg and the following libraries:

    • mpir:x86-windows-static
    • mpir:x64-windows-static

    is installed.

    You can install them by:

    $ vcpkg install mpir:x86-windows-static
    $ vcpkg install mpir:x64-windows-static
  3. Your vcpkg has been integrated into your Visual Studio, which means you have run successfully.

    $ vcpkg integrate install

6.2 Build

  1. Open this project in Visual Studio.

  2. Select Release configuration.

  3. Select Build > Build Solution.

You will see executable files in bin/ directory.

6.3 How to use?

Execute the following code in the terminal and configure two parameters to generate rarreg.key.

Here is an example of ASCII encoding for Github and Single PC usage license:

Usage:
        winrar-keygen.exe <Username> <License Name>

Example:

        winrar-keygen.exe "Github" "Single PC usage license"

  or:
        winrar-keygen.exe "Github" "Github.com" | Out-File -Encoding ASCII rarreg.key

Terminal

Now you can see the newly generated file.

RAR registration data
Github
Single PC usage license
UID=3a3d02329a32b63da7d8
6412212250a7d8753c5e7037d83011171578c57042fa30c506caae
9954e4853d415ec594e46017cb3db740bc4b32e47aea25db62f350
9f22065a27da4f8216d2938e1050b6e3347501a3767d1fdd7ee130
dd4ab952600ba16a99236d910bfa995d5f60651ec451f462511507
95b3722d059f2d5303a231e396cf21f17098edeec0b6e3347501a3
767d1fdd7ee45388769767642338ee8a63178f3458b71de5609b18
5eede7ed46566b10bf033daa6384062b259194b1acbd0378116064

Save the generated information in ANSI encoding as rarreg.key.

6.4 Multi-language support

Execute the following code in the terminal and configure two paramet

When using ANSI encoding, you can only use characters from the country or region where your operating system is located. ANSI encoding is supported from Powershell 7.4 onwards, and you will also need to upgrade your Powershell.

Generate multi-language licenses in ANSI encoding.

winrar-keygen.exe "简体中文" "license" | Out-File -Encoding ansi rarreg.key

winrar-keygen.exe "繁體中文" "license" | Out-File -Encoding ansi rarreg.key

winrar-keygen.exe "Deutsch" "license" | Out-File -Encoding ansi rarreg.key

winrar-keygen.exe "Français" "license" | Out-File -Encoding ansi rarreg.key

winrar-keygen.exe "日本語" "license" | Out-File -Encoding ansi rarreg.key

winrar-keygen.exe "한국어" "license" | Out-File -Encoding ansi rarreg.key

When generating utf-8 licenses, you may need to check Use Beta:Use Unicode UTF-8 for global language support in Control Panel > Clock and Regions > Regions > Administration > Change System Region Settings in order to process the data correctly. However, it is not recommended that you do this, which may cause many software to not work properly, and it is recommended to use Github Actions.

Generate multi-language licenses with UTF-8 encoding.

utf8: is to ensure constant character representation in WinRAR across languages.

winrar-keygen.exe "utf8:简体中文" "license" | Out-File -Encoding utf8 rarreg.key

winrar-keygen.exe "utf8:繁體中文" "license" | Out-File -Encoding utf8 rarreg.key

winrar-keygen.exe "utf8:Deutsch" "license" | Out-File -Encoding utf8 rarreg.key

winrar-keygen.exe "utf8:Français" "license" | Out-File -Encoding utf8 rarreg.key

winrar-keygen.exe "utf8:日本語" "license" | Out-File -Encoding utf8 rarreg.key

winrar-keygen.exe "utf8:한국어" "license" | Out-File -Encoding utf8 rarreg.key

7. Invalid key

Why is my rarreg.key invalid?

7.1 Character encoding

TEXT1 and TEXT2 are required to fulfill corresponding coding requirements.

winrar-keygen.exe <TEXT1> <TEXT2>

You can refer to: Generation of "rarreg.key"

7.2 Text encoding

If you use the following command:

winrar-keygen.exe "Github" "Single PC usage license" > rarreg.key

In the newer Windows 10, PowerShell will export in UTF16-LE format by default, which will cause the error.

Please use the following command:

winrar-keygen.exe "Github" "Github.com" | Out-File -Encoding ascii rarreg.key

winrar-keygen.exe "Github" "Github.com" | Out-File -Encoding ansi rarreg.key

winrar-keygen.exe "utf8:Github" "Github.com" | Out-File -Encoding utf8 rarreg.key

8. Contributing

8.1 Suggestion

If you encounter some problems, you can report on the Issues page. There will be many enthusiastic developers or Github users to help you.

This project welcomes contributions and suggestions. You can make suggestions in Issues, or submit a pull request 😄

8.2 Thanks

Thank you very much to some enthusiastic developers for helping answer some questions in Issues.

🏆 Special Thanks @Sonic-The-Hedgehog-LNK1123

9. License

The code is available under the MIT license

winrar-keygen's People

Contributors

bitcookies avatar brlin-tw avatar pudding0503 avatar quyentruong avatar vavavr00m avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

winrar-keygen's Issues

Workflows are not available.

By simply following the tutorial you may hit a roadblock because the workflows are not visible.

This is because they are disabled by default on forked repos.

Could you add a note in the readme to warn noobs like me to press 'that button' to enable them.
I found the button but pushed it before documenting the process.

关于简中注册仍有广告的解决办法

考虑到PR太麻烦,这里就提个 issue 啰嗦一下吧,以下正题:

首先,WINRAR的简中个人版,不管有没有注册都有广告。

这里是简中版去广告的四种方式。

  1. 通过Resource Hacker修改及删除了内部的广告程序:全栈程序员站长-WinRAR去广告:只需六步,教你去除WinRAR的广告
  2. 阻止其联网:百度经验-如何禁止winrar弹出广告
  3. 使用商业版进行注册,winrar商业版提取器:wiflvtx/win-rar-extractor
  4. 绕道官网购买(非代理商),联系WinRAR技术支持:为什么 WinRAR 买了授权还是有广告? - 小约翰的回答 - 知乎

商业版地址规律:

YYYYMMDD,年月日;PPP是渠道;XXX,版本号。

https://www.win-rar.com/fileadmin/winrar-versions/sc/scYYYYMMDD/PPP/winrar-x64-XXXsc.exe

综上所述,这些文献资料提供的信息与逻辑,个人想出了一个快速使用的小点子

其他参考资料:

InternalError: The length of register data is not correct.

The error InternalError: The length of register data is not correct. is sometimes returned while generating a key.

After some testing, I discovered that the length checks that should prevent that error in the first place, are incorrect.

first:

if (LicenseTypeSignatureR.length() <= 60 && LicenseTypeSignatureS.length() <= 60) {

Pad with zeros, and <= should be == :

if (LicenseTypeSignatureR.length() < 60) {
    LicenseTypeSignatureR.insert(LicenseTypeSignatureR.begin(), 60 - LicenseTypeSignatureR.size(), '0');
}
if (LicenseTypeSignatureS.length() < 60) {
    LicenseTypeSignatureS.insert(LicenseTypeSignatureS.begin(), 60 - LicenseTypeSignatureS.size(), '0');
}
if (LicenseTypeSignatureR.length() == 60 && LicenseTypeSignatureS.length() == 60) { 

second:

if (UserNameSignatureR.length() <= 60 || UserNameSignatureS.length() <= 60) {

same as above, and || should be &&:

if (UserNameSignatureR.length() < 60) {
    UserNameSignatureR.insert(UserNameSignatureR.begin(), 60 - UserNameSignatureR.size(), '0');
}
if (UserNameSignatureS.length() < 60) {
    UserNameSignatureS.insert(UserNameSignatureS.begin(), 60 - UserNameSignatureS.size(), '0');
}
if (UserNameSignatureR.length() == 60 && UserNameSignatureS.length() == 60) { 

These changes should get rid of that error.

WinRAR keygen may not work anymore soon

Hey, I don't know if this will be a problem in the future, but I still posted this, take a look at the picture
image
It says that some three features are "deprecated" and will be "disabled" soon
I'm not sure if anyone posted this issue before, but just went with it anyways

Format string causes undefined behavior

The format string "60%060s%060s" at:

RegInfo.Items[1] = HelperStringFormat("60%060s%060s", LicenseTypeSignatureS.c_str(), LicenseTypeSignatureR.c_str());

and
RegInfo.Items[2] = HelperStringFormat("60%060s%060s", UserNameSignatureS.c_str(), UserNameSignatureR.c_str());

is not valid, the "0" flag cannot be combined with the "s" specifier.

The string should be replaced with "60%s%s" like this:

RegInfo.Items[1] = HelperStringFormat("60%060s%060s", LicenseTypeSignatureS.c_str(), LicenseTypeSignatureR.c_str());

should be replaced by:

RegInfo.Items[1] = HelperStringFormat("60%s%s", LicenseTypeSignatureS.c_str(), LicenseTypeSignatureR.c_str());

and

RegInfo.Items[2] = HelperStringFormat("60%060s%060s", UserNameSignatureS.c_str(), UserNameSignatureR.c_str());

should be replaced by:

RegInfo.Items[2] = HelperStringFormat("60%s%s", UserNameSignatureS.c_str(), UserNameSignatureR.c_str()); 

The changes introduced in #6 already ensure the strings to be formatted are exactly 60 chars.

[Request] binary or tutorial for Linux

I would really like to know, if this code is also intended to be used on Linux.
Of course I can use mono or wine . but I would like to run it as binary or a compiled code on linux.

So how do I compile this for linux? :)

Thanks in advance!

Convert rarreg.key to rarreg.rar?

When you purchase WinRAR, you get a rarreg.rar file which can be opened in winrar to activate it.
How can I convert the rarreg.key that this tool generates to a rarreg.rar? Just compressing it doesn't work.

(win10) Can't run keygenx64.exe

i do disabled window defense but it didn't seem to work. it just flash open a console like cmd window and close itself immediately

Generate WinRAR regkey file contain a UTF-8 Username.

I brought a genuine WinRAR license on win-rar.com, and got a rarreg.key file that contain utf-8 characters.
Then I try use your winrar-keygen to generate a rarreg.key file like the genuine one.

我今天购买了正版的WinRAR授权,然后发现授权文件可以使用中文。
后经过自己尝试用你的winrar-keygen生成了中文用户名的rarreg.key文件。
首先在控制面板-时钟和区域-区域的管理选项卡下,选择[更改系统区域设置],勾选[Beta版:使用Unicode UTF-8提供全球语言支持]
重启电脑后用Powershell在winrar-keygen文件夹下运行
.\winrar-keygen-x64.exe "utf8:神北小毬" "Single PC usage license" | Out-File -Encoding UTF8 rarreg.key
生成的文件中增加一个换行,更改文件编码为utf-8 no ROM。之后此文件就可以正常激活WinRAR 7.00了。
区域设置
rarreg[神北小毬].zip

Registration Failed

RAR registration data
Github
Github.com
UID=3a3d02329a32b63da7d8
6412212250a7d8753c5e7037d83011171578c57042fa30c506caae
9954e4853d415ec594e460a7213ad70c9139c941613a53b6798ea8
aa19873a1f107ba38957c31029722ba44f4c88667180de0dd18d35
b59927bfb6c3db0f916a59b707c657bc9360faa4200e4ee2cbd7e2
7ca2797b748eb2edce71ac60b2e8cca23563003c752ba44f4c8866
7180de0dfb4545465f32e0b12aa3bcaf0e9c21b4425f627c609b18
5eede7ed46566b10bf033daa6384062b259194b1acbd3027113380

WinRAR version: 6.0.2

Auto Generate rarreg.key

Hello bitcookies,
It's kinda a suggestion but will it be possible to make an exe that takes registration name as a text field input and outputs rarreg.key directly without running it through powershell ?
It's for the people who are not well versed in computers.

Thanks for the keygen thought i really like it.

PS :- I'm planning to make one but idk anything about making exe files so I'll have to learn and start it from scratch.

Found Malware

Just on the Release file executable, I found detection score of 2/74 at VirusTotal. CrowdStrike Falcon and Cynet are claiming that.
Just check and disinfect your executable. Thanks!

[Help Request] How to build with VS2022 Build Tools only and what is the minimum required components for the project to successfully compile?

OS: Windows 11 Pro

I cobbled up a batch script that generates the key automatically last year and it still works as of today, however, with the xz utils incident several months ago, I wanna be on the safe side and have the script eventually be able to build the KG from source automatically without installing the entire Visual Studio. I'm no developer, just casually learning how to write batch script; it's a bit of a struggle for me to figure it out.

  1. Downloaded source zip and extracted to C:

  2. Downloaded hMSBuild.bat and moved it to C:\Windows

  3. Installed VS2022 Build Tools along + some per this issue for it to stop throwing an error "vcpkg install error:in triplet x64-windows: Unable to find a valid Visual Studio instance Could not locate a complete Visual Studio instance"

> winget install Microsoft.VisualStudio.2022.BuildTools --silent --override "--wait --quiet --add ProductLang En-us --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.Windows10SDK --add Microsoft.VisualStudio.Component.Windows11SDK --add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended"
  1. Rebooted

  2. Installed git

  3. Installed vcpkg

> git clone https://github.com/microsoft/vcpkg
> .\vcpkg\bootstrap-vcpkg.bat
  1. Installed mpir
.\vcpkg\vcpkg install mpir --triplet=x64-windows
  1. Not sure what this does but ran it anyway
> vcpkg integrate install
  1. Go to the extracted files
> cd C:\winrar-keygen-master
  1. Ran:
> hmsbuild winrar-keygen.sln

Build fails. See log below. What am I doing wrong? How can I simplify the process and ensure that only the necessary stuff are installed?

hMSBuild: "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\MSBuild\Current\Bin\amd64\MSBuild.exe"
MSBuild version 17.10.4+10fbfbf2e for .NET Framework
Build started 6/21/2024 12:16:07 PM.

Project "C:\winrar-keygen-master\winrar-keygen.sln" on node 1 (default targets).
ValidateSolutionConfiguration:
  Building solution configuration "Debug|x64".
Project "C:\winrar-keygen-master\winrar-keygen.sln" (1) is building "C:\winrar-keygen-master\winrar-keygen.vcxproj" (2)
 on node 1 (default targets).
PrepareForBuild:
  Creating directory "C:\winrar-keygen-master\obj\x64-Debug\".
  Structured output is enabled. The formatting of compiler diagnostics will reflect the error hierarchy. See https://ak
  a.ms/cpp/structured-output for more details.
  Creating directory "C:\winrar-keygen-master\bin\x64-Debug\".
  Creating directory "C:\winrar-keygen-master\obj\x64-Debug\winrar-keygen.tlog\".
InitializeBuildStatus:
  Creating "C:\winrar-keygen-master\obj\x64-Debug\winrar-keygen.tlog\unsuccessfulbuild" because "AlwaysCreate" was spec
  ified.
  Touching "C:\winrar-keygen-master\obj\x64-Debug\winrar-keygen.tlog\unsuccessfulbuild".
VcpkgTripletSelection:
  Using triplet "x64-windows-static" from "C:\Users\0\vcpkg\installed\x64-windows-static\"
  Using normalized configuration "Debug"
ClCompile:
  C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.40.33807\bin\HostX64\x64\CL.exe /c /I
  "C:\Users\0\vcpkg\installed\x64-windows-static\include" /ZI /JMC /nologo /W3 /WX- /diagnostics:column /sdl /Od /D _DE
  BUG /D _CONSOLE /D _UNICODE /D UNICODE /Gm- /EHsc /RTC1 /MTd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /std
  :c++17 /permissive- /Fo"C:\winrar-keygen-master\obj\x64-Debug\\" /Fd"C:\winrar-keygen-master\obj\x64-Debug\vc143.pdb"
   /external:W3 /Gd /TP /FC /errorReport:queue /utf-8 _tmain.cpp
  _tmain.cpp
C:\winrar-keygen-master\BigInteger.hpp(4,10): error C1083: Cannot open include file: 'gmp.h': No such file or directory
 [C:\winrar-keygen-master\winrar-keygen.vcxproj]
  (compiling source file '_tmain.cpp')

Done Building Project "C:\winrar-keygen-master\winrar-keygen.vcxproj" (default targets) -- FAILED.

Done Building Project "C:\winrar-keygen-master\winrar-keygen.sln" (default targets) -- FAILED.


Build FAILED.

"C:\winrar-keygen-master\winrar-keygen.sln" (default target) (1) ->
"C:\winrar-keygen-master\winrar-keygen.vcxproj" (default target) (2) ->
(ClCompile target) ->
  C:\winrar-keygen-master\BigInteger.hpp(4,10): error C1083: Cannot open include file: 'gmp.h': No such file or directo
ry [C:\winrar-keygen-master\winrar-keygen.vcxproj]

    0 Warning(s)
    1 Error(s)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.