一、下载Navicat Premium并安装
navicat官网下载地址
二、激活
github的一个开源项目navicat-keygen,项目windows和Mac两个版本
2.1 How to build
如果Mac安装了Xcode(iOS等开发工具),会集成Homebrew和git等工具
如果没有安装Xcode,先要安装Homebrew和git
- 安装Homebrew:
~$/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
- 用Homebrew安装git
~$ brew install git
- 在编译navicat-keygen前先安装依赖库
~$ brew install openssl
~$ brew install capstone
~$ brew install keystone
~$ brew install rapidjson
~$ brew install libplist
- Clone Mac分支并编译keygen和batcher
~$ git clone -b mac --single-branch
https://github.com/DoubleLabyrinth/navicat-keygen.git
~$ cd navicat-keygen
navicat-keygen berning$ make all
- ./bin目录下会有两个可执行文件
navicat-keygen berning$ ls bin/
navicat-keygen navicat-patcher
2.2 How to use
编译keygen 和 patcher
备份好 Navicat Premium.app/Contents/MacOS/Navicat Premium 以及Navicat中所有已保存的数据库连接(包括密码)。
移除所有Navicat在 Keychain.app (即钥匙链)中保存的连接,如果有的话。
你可以通过搜索关键词 navicat 来找到它们。
- 用navicat-patcher 替换 Navicat 激活公钥.
navicat-keygen berning$ cd bin
bin berning$ ./navicat-patcher /Applications/Navicat\ Premium.app/
测试版本:12.0.27
上述命令输出如下:
***************************************************
* Navicat Patcher by @DoubleLabyrinth *
* Version: 4.0 *
***************************************************
Press Enter to continue or Ctrl + C to abort.
[-] ./navicat-patcher/main.cpp:134 ->
open failed.
Not a directory
BerningsdeMacBook-Pro:navicat-keygen berning$ ./bin/navicat-patcher /Applications/Navicat\ Premium.app
***************************************************
* Navicat Patcher by @DoubleLabyrinth *
* Version: 4.0 *
***************************************************
Press Enter to continue or Ctrl + C to abort.
[*] Your Navicat version: 12.0.27
[+] PatchSolution0 ...... Ready to apply.
Keyword offset = +0x025b7d39
[-] PatchSolution1 ...... Omitted.
[-] PatchSolution2 ...... Omitted.
[*] Generating new RSA private key, it may take a long time...
[+] New RSA private key has been saved to RegPrivateKey.pem.
[*] Your RSA public key:
-----BEGIN PUBLIC KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAy0xu37JEz5JpLbyC9mNu
YjKSVN2oJosj5viwyHUm8XE/uH1akMvkHRf1UVlzXPVR3REKwikECdAAId2qZbKI
Ub1ap6Hola1r0cue0IDAwzSX0Yfw+Ia+yYkmgd/bvERfd7V15/caQqkE5JOgspvi
9B88X2Jlu+EKowFIl5A9OM6aCNBoALOa1lB18AWjnk128X4WvxW0XtXduDUvBAGW
kV6F5Jv5MGYBtnSq3d7r02ldAp/wb+YT9PJXGbJmi2YpHVdzakCE5MimP9ZRXBjB
L88nHlf7NZQojzgWwIqiSy20IQ69U/j4SEajZbzwUA4q2A89Jdf4gKgOnEpc1mP+
kQIDAQAB
-----END PUBLIC KEY-----
**************************************************************
* PatchSolution0 *
**************************************************************
@+0x025b7d39
Previous:
-0x0000000000000009 2d 2d 2d 2d 2d 42 45 -----BE
+0x0000000000000007 47 49 4e 20 50 55 42 4c 49 43 20 4b 45 59 2d 2d GIN PUBLIC KEY--
+0x0000000000000017 2d 2d 2d 00 4d 49 49 42 49 6a 41 4e 42 67 6b 71 ---.MIIBIjANBgkq
+0x0000000000000027 68 6b 69 47 39 77 30 42 41 51 45 46 41 41 4f 43 hkiG9w0BAQEFAAOC
+0x0000000000000037 41 51 38 41 4d 49 49 42 43 67 4b 43 41 51 45 41 AQ8AMIIBCgKCAQEA
+0x0000000000000047 77 31 64 71 46 33 53 6b 43 61 41 41 6d 4d 7a 73 w1dqF3SkCaAAmMzs
+0x0000000000000057 38 38 39 49 00 71 64 57 39 4d 32 64 49 64 68 33 889I.qdW9M2dIdh3
+0x0000000000000067 6a 47 39 79 50 63 6d 4c 6e 6d 4a 69 47 70 42 46 jG9yPcmLnmJiGpBF
+0x0000000000000077 34 45 39 56 48 53 4d 47 65 38 6f 50 41 79 32 6b 4E9VHSMGe8oPAy2k
+0x0000000000000087 4a 44 6d 64 4e 74 34 42 63 45 79 67 76 73 73 45 JDmdNt4BcEygvssE
+0x0000000000000097 66 67 69 6e 76 00 61 35 74 35 6a 6d 33 35 32 55 fginv.a5t5jm352U
+0x00000000000000a7 41 6f 44 6f 73 55 4a 6b 54 58 47 51 68 70 41 57 AoDosUJkTXGQhpAW
+0x00000000000000b7 4d 46 34 66 42 6d 42 70 4f 33 45 65 64 47 36 32 MF4fBmBpO3EedG62
+0x00000000000000c7 72 4f 73 71 4d 42 67 6d 53 64 41 79 78 43 53 50 rOsqMBgmSdAyxCSP
+0x00000000000000d7 42 52 4a 49 4f 46 00 52 30 51 67 5a 46 62 52 6e BRJIOF.R0QgZFbRn
+0x00000000000000e7 55 30 66 72 6a 33 34 66 69 56 6d 67 59 69 4c 75 U0frj34fiVmgYiLu
+0x00000000000000f7 5a 53 41 6d 49 62 73 38 5a 78 69 48 50 64 70 31 ZSAmIbs8ZxiHPdp1
+0x0000000000000107 6f 44 34 74 55 70 76 73 46 63 69 34 51 4a 74 59 oD4tUpvsFci4QJtY
+0x0000000000000117 4e 6a 4e 6e 47 55 32 00 57 50 48 36 72 76 43 68 NjNnGU2.WPH6rvCh
+0x0000000000000127 47 6c 31 49 52 4b 72 78 4d 74 71 4c 69 65 6c 73 Gl1IRKrxMtqLiels
+0x0000000000000137 76 61 6a 55 6a 79 72 67 4f 43 36 4e 6d 79 6d 59 vajUjyrgOC6NmymY
+0x0000000000000147 4d 76 5a 4e 45 52 33 68 74 46 45 74 4c 31 65 51 MvZNER3htFEtL1eQ
+0x0000000000000157 62 43 79 54 66 44 6d 74 00 59 79 51 31 57 74 34 bCyTfDmt.YyQ1Wt4
+0x0000000000000167 4f 74 31 32 6c 78 66 30 77 56 49 52 35 6d 63 47 Ot12lxf0wVIR5mcG
+0x0000000000000177 4e 37 58 43 58 4a 52 48 4f 46 48 53 66 31 67 7a N7XCXJRHOFHSf1gz
+0x0000000000000187 58 57 61 62 52 53 76 6d 74 31 6e 72 6c 37 73 57 XWabRSvmt1nrl7sW
+0x0000000000000197 36 63 6a 78 6c 6a 75 75 51 00 61 77 49 44 41 51 6cjxljuuQ.awIDAQ
+0x00000000000001a7 41 42 00 2d 2d 2d 2d 2d 45 4e 44 20 50 55 42 4c AB.-----END PUBL
+0x00000000000001b7 49 43 20 4b 45 59 2d 2d 2d 2d 2d 00 74 69 6d 65 IC KEY-----.time
After:
-0x0000000000000009 2d 2d 2d 2d 2d 42 45 -----BE
+0x0000000000000007 47 49 4e 20 50 55 42 4c 49 43 20 4b 45 59 2d 2d GIN PUBLIC KEY--
+0x0000000000000017 2d 2d 2d 00 4d 49 49 42 49 6a 41 4e 42 67 6b 71 ---.MIIBIjANBgkq
+0x0000000000000027 68 6b 69 47 39 77 30 42 41 51 45 46 41 41 4f 43 hkiG9w0BAQEFAAOC
+0x0000000000000037 41 51 38 41 4d 49 49 42 43 67 4b 43 41 51 45 41 AQ8AMIIBCgKCAQEA
+0x0000000000000047 79 30 78 75 33 37 4a 45 7a 35 4a 70 4c 62 79 43 y0xu37JEz5JpLbyC
+0x0000000000000057 39 6d 4e 75 00 59 6a 4b 53 56 4e 32 6f 4a 6f 73 9mNu.YjKSVN2oJos
+0x0000000000000067 6a 35 76 69 77 79 48 55 6d 38 58 45 2f 75 48 31 j5viwyHUm8XE/uH1
+0x0000000000000077 61 6b 4d 76 6b 48 52 66 31 55 56 6c 7a 58 50 56 akMvkHRf1UVlzXPV
+0x0000000000000087 52 33 52 45 4b 77 69 6b 45 43 64 41 41 49 64 32 R3REKwikECdAAId2
+0x0000000000000097 71 5a 62 4b 49 00 55 62 31 61 70 36 48 6f 6c 61 qZbKI.Ub1ap6Hola
+0x00000000000000a7 31 72 30 63 75 65 30 49 44 41 77 7a 53 58 30 59 1r0cue0IDAwzSX0Y
+0x00000000000000b7 66 77 2b 49 61 2b 79 59 6b 6d 67 64 2f 62 76 45 fw+Ia+yYkmgd/bvE
+0x00000000000000c7 52 66 64 37 56 31 35 2f 63 61 51 71 6b 45 35 4a Rfd7V15/caQqkE5J
+0x00000000000000d7 4f 67 73 70 76 69 00 39 42 38 38 58 32 4a 6c 75 Ogspvi.9B88X2Jlu
+0x00000000000000e7 2b 45 4b 6f 77 46 49 6c 35 41 39 4f 4d 36 61 43 +EKowFIl5A9OM6aC
+0x00000000000000f7 4e 42 6f 41 4c 4f 61 31 6c 42 31 38 41 57 6a 6e NBoALOa1lB18AWjn
+0x0000000000000107 6b 31 32 38 58 34 57 76 78 57 30 58 74 58 64 75 k128X4WvxW0XtXdu
+0x0000000000000117 44 55 76 42 41 47 57 00 6b 56 36 46 35 4a 76 35 DUvBAGW.kV6F5Jv5
+0x0000000000000127 4d 47 59 42 74 6e 53 71 33 64 37 72 30 32 6c 64 MGYBtnSq3d7r02ld
+0x0000000000000137 41 70 2f 77 62 2b 59 54 39 50 4a 58 47 62 4a 6d Ap/wb+YT9PJXGbJm
+0x0000000000000147 69 32 59 70 48 56 64 7a 61 6b 43 45 35 4d 69 6d i2YpHVdzakCE5Mim
+0x0000000000000157 50 39 5a 52 58 42 6a 42 00 4c 38 38 6e 48 6c 66 P9ZRXBjB.L88nHlf
+0x0000000000000167 37 4e 5a 51 6f 6a 7a 67 57 77 49 71 69 53 79 32 7NZQojzgWwIqiSy2
+0x0000000000000177 30 49 51 36 39 55 2f 6a 34 53 45 61 6a 5a 62 7a 0IQ69U/j4SEajZbz
+0x0000000000000187 77 55 41 34 71 32 41 38 39 4a 64 66 34 67 4b 67 wUA4q2A89Jdf4gKg
+0x0000000000000197 4f 6e 45 70 63 31 6d 50 2b 00 6b 51 49 44 41 51 OnEpc1mP+.kQIDAQ
+0x00000000000001a7 41 42 00 2d 2d 2d 2d 2d 45 4e 44 20 50 55 42 4c AB.-----END PUBL
+0x00000000000001b7 49 43 20 4b 45 59 2d 2d 2d 2d 2d 00 74 69 6d 65 IC KEY-----.time
[+] PatchSolution0 has been applied.
**************************************************************
* Patch has been done successfully. Have fun and enjoy~~ *
* DO NOT FORGET TO SIGN NAVICAT BY YOUR CERTIFICATE!!! *
**************************************************************
~$
- Navicat Premium 版本低于12.0.24的:
navicat-patcher 会中止且不会生成任何补丁,解决办法如下:
~ $ openssl genrsa -out RegPrivateKey.pem 2048
~$ openssl rsa -in RegPrivateKey.pem -pubout -out rpk
用生成的rpk文件替换如下目录的rpk
$ mv rpk /Applications/Navicat Premium.app/Contents/Resources/rpk
-
生成一份自签名的代码证书
在keychain Access.app 里面创建证书
用codesign对Navicat Premium.app重签名
bin berning$ codesign -f -s "navicat" /Applications/Navicat\ Premium.app
/Applications/Navicat Premium.app/: replacing existing signature
- navicat-keygen来生成 序列号 和 激活码
bin berning$ pwd
/Users/berning/navicat-keygen/bin
:bin berning$ cd ..
navicat-keygen berning$ ls
HOW_DOES_IT_WORK.md Makefile RegPrivateKey.pem navicat-keygen
HOW_DOES_IT_WORK.zh-CN.md README.md bin navicat-patcher
LICENSE README.zh-CN.md common
//RegPrivateKey.pem位于navicat-keygen目录下
navicat-keygen berning$ ./bin/navicat-keygen RegPrivateKey.pem
输出如下:(备注的四行根据实际情况输入)
先不要关闭终端
***************************************************
* Navicat Keygen by @DoubleLabyrinth *
* Version: 4.0 *
***************************************************
Which is your Navicat Premium language?
0. English
1. Simplified Chinese
2. Traditional Chinese
3. Japanese
4. Polish
5. Spanish
6. French
7. German
8. Korean
9. Russian
10. Portuguese
(Input index)> 0 //我选择了0.English
(Input major version number, range: 0 ~ 15, default: 12)>
Invalid number.
(Input major version number, range: 0 ~ 15, default: 12)> 12 //navicat 版本信息
Serial number:
NAVG-UDTR-4CQV-M9MU
Your name: berning //我的用户名
Your organization: bien //我的组织
Input request code (in Base64), input empty line to end: //粘贴request code
断网
--->打开Navicat--->注册(Registration)--->输入生成Serial number--->激活(Activate)(会失败,别在意,继续)--->手动激活( Manual Activation)--->弹出窗口会得到 request code--->将request code复制粘贴到终端 --->回车两下
Your name: berning //我的用户名
Your organization: bien //我的组织
Input request code (in Base64), input empty line to end:
B8MLDrtQV6z/lnFJSVyUOMDdettQ7Ei1NAZyjxCaNnz66kMxmdQNaIXv2WpJKDZJTIQTbgxccL3P
+RefVar1KO9wjcFHhDLi14F6OYwSOvsAr/g9eZA7bHVhYCA5dUHktjybSTUCrGQLWhsSQkqo10bx
MAr+oCvfOszXlbRYfsNNvgJxzX3aarwoIwGNOv78D9uTPg7s5E3FUEi3PnF9mifKXZaisaemhI29
84vaV4Lli+ydYIQUPzxBVZxgVbjITYH/TS+92XbwCh8bAfuyZRWVhaxMP4XVb/uB8ktKa15soPy6
6vD7AdsM8j6gPVccAnCIey9SuCoaEtczjujTQQ==
Request Info:
{
"K" : "NAVGUDTR4CQVM9MU",
"P" : "Mac 10.14",
"DI" : "MTdhN2ZkNTFjNmM1NWUz"
}
Response Info:
{"K":"NAVGUDTR4CQVM9MU","DI":"MTdhN2ZkNTFjNmM1NWUz","N":"wbn","O":"bien","T":1570163675}
License:
ymo8n2QTGTcRlAqpNxZ6mwqoXzf3IjoSTce4iQsS60jbKhKOHVuIFtPrc+5FCahgvjch+BJFfkzor+BDeopaHL8maRTGh3Qxtuc3zJFpRLagFxGxp6VKXIQPnHclfnhf9fGMAv1ViLYaXM92a8DhAIXaaMbp4aaW1qcP6VyaAh//KmlRMEr2QJxE9wQQ7TWnPRToOH1RbeC4/Vspby+t4BA9q01JW66FL1i/JQCJT9nGT9pWvj2OqnnVxgXqHf445x5h60+KZ+F4nvdUH3dcP0vCizccJoR1DnP7W7VokQOoTLaXgepBP1a7yMgeefWzrTFOubNC2PoXwNdBcZ6VrQ==
- 将生成的Base64编码的Activation Code,复制粘贴到手动激活的窗口,点击Activate。
If nothing wrong, activation should be done successfully.