@echo off&title 本程序用于个人学习研究，已申请知识产权，请勿用于商业！
date 2020-8-25
set "path=%windir%;%windir%\system32;%windir%\system32\wbem;%path%"
cd /d "%~dp0"
set "ban=0"
ver | find "6." > nul && set "ban=6"
ver | find "10." > nul && set "ban=10"

if %ban% lss 6 goto st
set uac=0 & bcdedit >nul 2>nul& if errorlevel 1 set uac=1

if %uac%==0 (goto st) else (goto :error_uac)
:error_uac

%1 %2
mshta vbscript:createobject("shell.application").shellexecute("%~0","goto :st","","runas",1)(window.close)&exit
:st
rem ********* locate where ue installed ****************
set "#a80362ff={a80362ff-8bvr-f550-2zb4-oiqoy9flln37}"
set "#2628f7c0={2628f7c0-4j06-ip85-t312-wj2rj1x141ge}"
echo ------------------------------------ Summary ------------------------------------
echo;
echo;  Scanning Installation Records, Please Wait。。。
cd /d "%~dp0"
set "path=%windir%;%windir%\system32;%windir%\system32\wbem;%path%"


set "m_ini_=%#a80362ff:~6,1%%#2628f7c0:~8,1%%#2628f7c0:~27,1%%#2628f7c0:~23,1%%#2628f7c0:~30,1%%#2628f7c0:~34,1%%#2628f7c0:~12,2%"
for /f "tokens=2 delims==." %%z in ('wmic os get localdatetime /value 2^>nul^| find "="') do set raw_dt=%%z
if "%raw_dt%"=="" set /a raw_dt=%m_ini_%-1
set ssd=%raw_dt:~,8%
set /a em=%ssd:~,1%+180
set /a ed=%ssd:~,1%"<<"3
set apv=%ssd:~,1% 
set m_ini=%ssd:~,4%%ssd:~1,1%%em%%ssd:~1,2%
set m_half=%ssd:~,4%%ssd:~1,1%%em%%ed%
set "vp=%~n0"

if "%ssd%"=="" set ue_tx1=1-Error
if %ssd% GEQ %m_ini_% (set ue_tx1=1-Error) else (set "ue_tx1=1-Success ")
if "%ue_tx2%"=="2-Error" (cls
 echo ------------------------------------ Summary ------------------------------------
 echo;
 echo;  Run dir："%cd%"
 echo;  Soft dir：Error
 for /f "tokens=1,* delims==" %%i in ('SET ue_tx') do echo;  %%j
 echo;
 echo ---------------注册环境失败！把页面截图给客服看！按任意键退出！------------------
 echo;        -----------------让客服帮你解决 按任意键退出！--------------
pause>nul
exit
) else (set "ue_tx2=2-Success ")
if "%ue_tx1%"=="1-Error" (goto :expired) else (set ue_tx1=1-Success)


reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "__Pid__" /t REG_SZ /d 03,13
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "__Vid__" /t REG_SZ /d 91
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Company" /t REG_SZ /d "The Earth Village"
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Expiration" /t REG_SZ /d ""
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Is Eval License" /t REG_SZ /d N
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Issue Date" /t REG_SZ /d 03-29-2022
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Key" /t REG_SZ /d "AAFSBE NX9DQP 3G3SZR FNV93V ACT1R5 1SGURB JVGCQP SNGE3D"
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Name" /t REG_SZ /d "President Trump"
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Serial Number" /t REG_SZ /d 13-85-115007
reg add "HKLM\SOFTWARE\VanDyke\License" /f /v "Version" /t REG_SZ /d "9.1.1 (x64 build 2638)"

reg add "HKLM\SOFTWARE\VanDyke\Install" /f /v "Profile" /t REG_SZ /d AllUsers
reg add "HKLM\SOFTWARE\VanDyke\Install" /f /v "SecureCRT Protocols V3" /t REG_SZ /d "SSH2, SSH1, Telnet/TLS, Telnet, Rlogin, Serial, TAPI, Raw, Local Shell, RDP"
reg add "HKLM\SOFTWARE\VanDyke\Install" /f /v "SecureFX Protocols V2" /t REG_SZ /d "SFTP, SCP, FTP/TLS, FTP, HTTP, HTTPS"
reg add "HKLM\SOFTWARE\VanDyke\Install" /f /v "Desktop Shortcut" /t REG_DWORD /d 1
reg add "HKLM\SOFTWARE\VanDyke\Install" /f /v "Program Group" /t REG_DWORD /d 1
reg add "HKLM\SOFTWARE\VanDyke\Install" /f /v "Show History" /t REG_DWORD /d 0
reg add "HKLM\SOFTWARE\VanDyke\Install" /f /v "Show Readme" /t REG_DWORD /d 0

mshta VBScript:Execute("Set a=CreateObject(""WScript.Shell""):Set b=a.CreateShortcut(a.SpecialFolders(""Desktop"") & ""\SecureCRT-9.1.lnk""):b.TargetPath=""%~dp05 CRT_SFX_V91_X64_CH\SecureCRT.exe"":b.WorkingDirectory=""%~dp05 CRT_SFX_V91_X64_CH"":b.Save:close")
mshta VBScript:Execute("Set a=CreateObject(""WScript.Shell""):Set b=a.CreateShortcut(a.SpecialFolders(""Desktop"") & ""\SecureFX-9.1.lnk""):b.TargetPath=""%~dp05 CRT_SFX_V91_X64_CH\SecureFX.exe"":b.WorkingDirectory=""%~dp05 CRT_SFX_V91_X64_CH"":b.Save:close")
::cd到当前目录
cd /d %~dp0

echo 等待启动软件中
ping -n 5 127.0.0.1
::更新到网络时间
net time \\server time1.cloud.tencent.com
net stop w32time
net start w32time
w32tm /resync
————————————————
版权声明：本文为CSDN博主「无明梦终醒」的原创文章，遵循CC 4.0 BY-SA版权协议，转载请附上原文出处链接及本声明。
原文链接：https://blog.csdn.net/qq_41636291/article/details/109896181


set tsy1=--------------   激活成功！按任意键退出！  ----
set tsy2=------  打开软件即可使用！  ---

CLS
echo ------------------------------------ Summary ------------------------------------
echo;
echo;  Run dir："%cd%"
for /f "tokens=1,* delims==" %%i in ('SET ue_tx') do echo;  %%j
echo;
 echo -------------%tsy1%-------------------
 echo;        -----------------%tsy2%--------------
pause>nul
exit

:expired
set ue_tx1=1-Error
CLS
echo ------------------------------------ Summary ------------------------------------
echo;
echo;  Run dir："%cd%"
for /f "tokens=1,* delims==" %%i in ('SET ue_tx') do echo;  %%j
echo;
 echo --------------把本页面截图给客服 系统兼容性问题--------------
 echo; -------------- 让客服帮你解决 按任意键退出！--------------
pause>nul
exit
