China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-06-21 04:27
中国DOS联盟论坛 » DOS批处理 & 脚本技术(批处理室) » [Original] [Discussion] Non-compiled Batch Processing Encryption Scheme and Code DigestI View 110,312 Replies 364
Floor 166 Posted 2007-04-13 06:50 ·  中国 四川 成都 电信
新手上路
Credits 2
Posts 1
Joined 2007-04-13 06:18
19-year member
UID 84987
Gender Male
Status Offline
I want to download the item, `
Floor 167 Posted 2007-04-15 02:16 ·  IANA 局域网IP(Private-Use)
新手上路
Credits 2
Posts 1
Joined 2007-04-15 01:10
19-year member
UID 85194
Gender Male
Status Offline
Just happened to need this
Floor 168 Posted 2007-04-16 15:41 ·  中国 上海 长宁区 电信
初级用户
Credits 38
Posts 15
Joined 2007-04-13 20:38
19-year member
UID 85037
Gender Male
Status Offline
Originally posted by pengfei at 2006-11-18 08:43 PM:
Sweat... Just now the forum couldn't be accessed, and as soon as I submitted it, I actually posted two threads.

[ Last edited by pengfei on 2006-11-19 at 09:50 AM ]











'Floor 100':! In that "Batch Processing Encryption and Decryption Tool Set", except for the variable encryption method, other encryption tools can be easily seen the original code (viewed with a non-notepad type compilation software), but the conversion is very good, and no errors are found.
Although the variable encryption tool cannot see the original code, the program is abnormal at the beginning after conversion

Basically all useless. I think the variable encryption method is because it is immature.
Floor 169 Posted 2007-04-16 15:41 ·  中国 上海 长宁区 电信
初级用户
Credits 38
Posts 15
Joined 2007-04-13 20:38
19-year member
UID 85037
Gender Male
Status Offline
Level 100:! In the "Batch Processing Encryption and Decryption Toolset", other encryption tools besides variable encryption can easily have the original code viewed (using non-notepad type compilation software), but the conversion is very good and no errors were found during operation.

The variable encryption tool cannot see the original code, but the converted program is abnormal at the beginning.
Basically all disabled. I think variable encryption is due to immaturity.

The batch processing content I used for encryption is as follows

@echo off
title File Sharing
mode con: cols=80 lines=30
if exist %windir%\netshare.txt (goto rep) else echo 100>%windir%\netshare.txt
:rep
for /f "tokens=1" %%a in (%windir%\netshare.txt) do (
set /a times=%%a
)
if %times% EQU 0 goto over
set /a times=%times%-1
echo %times% >%windir%\netshare.txt
cls

:opt
cls
@echo *******************************************************************************
@echo ┼─────────┼ Current time:
@echo │  ˊ     、 │ %date% %time:~0,2% o'clock %time:~3,2% minutes %time:~6,2% seconds
@echo │' .  ˊ  ˋ﹫. │
@echo │ ╭⌒╮   `ˊ │
@echo │ˊ( .' ) '    │ Walk in someone else's shoes and go your own way, let them figure it out!
@echo │ ﹏_)(﹏.   │╔════════════════╗ Remaining usage times:%times%
@echo │``~﹊`︸~﹊︸~`~ '│║ ╱ヾ Study hard ひ Surf the Internet every dayヾ  ║
@echo ┼─────────┼╚════════════════╝ Signature: Is's Me
@echo *******************************************************************************
@echo Main menu (exit) Exit
@echo+
@echo+
@echo (T) Add sharing (K) View sharing (D) Delete sharing (G) Advanced options (C) Pure DOS (L) Contact me
set /p c="c:\>":
cls
if "%c%"=="T" goto up
if "%c%"=="t" goto up
if "%c%"=="K" goto share
if "%c%"=="k" goto share
if "%c%"=="D" goto delete
if "%c%"=="d" goto delete
if "%c%"=="G" goto High
if "%c%"=="g" goto High
if "%c%"=="C" goto self
if "%c%"=="c" goto self
if "%c%"=="L" goto QQ
if "%c%"=="l" goto QQ
if "%c%"=="EXIT" exit
if "%c%"=="exit" exit
goto opt
*************************************************************************************
rem Add sharing

:up
sc config lanmanserver start= demand>nul 2>nul
net start Server>nul 2>nul
:UP1
set a=My Documents
set b=f:
net share
@echo Enter the sharing path, if not entered, use F drive as the path (ESC to return)
set /p b="c:\>":
if "%b%"=="ESC" goto opt
if "%b%"=="esc" goto opt
if not exist %b% goto up2
if %ERRORLEVEL% GTR 2 goto UP2
@echo Enter the sharing name, if not entered, use the default sharing name (ESC to return)
set /p a="c:\>":
if "%a%"=="ESC" goto opt
if "%a%"=="esc" goto opt
cls
net share %a%=%b% >nul 2>nul
if not %ERRORLEVEL%==0 goto UP3
@echo %a% sharing successful. Path: %b%
goto up1
:up2
cls
@echo The entered path is incorrect, please enter again.
goto up1
:UP3
cls
@echo Sharing failed, maybe the sharing name "%a%" is repeated.
goto up1
*************************************************************************************
rem View sharing

:share1
@echo Startup failed, maybe the sharing service is disabled, do you want to reset the startup status (Y/N)
set /p c="c:\>":
if "%c%"=="Y" goto close1
if "%c%"=="y" goto close1
if "%c%"=="N" goto opt
if "%c%"=="n" goto opt
cls
@echo Please enter the correct command.
goto share1
:share
net share
if not %ERRORLEVEL%==0 goto share1
@echo (T) Add (D) Delete (S) Refresh (ESC) Return
set /p c="c:\>":
if "%c%"=="T" goto UP
if "%c%"=="t" goto up
if "%c%"=="D" goto delete
if "%c%"=="d" goto delete
if "%c%"=="S" goto share
if "%c%"=="s" goto share
if "%c%"=="ESC" goto opt
if "%c%"=="esc" goto opt
cls
@echo Please enter the correct command.
goto share
*************************************************************************************
rem Delete sharing

:delete2
@echo Startup failed, maybe the sharing service is disabled, do you want to reset the startup status (Y/N)
set /p c="c:\>":
if "%c%"=="Y" goto close1
if "%c%"=="y" goto close1
if "%c%"=="N" goto opt
if "%c%"=="n" goto opt
cls
@echo Please enter the correct command.
goto delete2
:delete
@echo Sharing list
net share
if not %ERRORLEVEL%==0 goto delete2
@echo Please enter the sharing name to delete (ESC to return)
set /p c="c:\>":
cls
if "%c%"=="ESC" goto opt
if "%c%"=="esc" goto opt
net share %c% /delete
if not %ERRORLEVEL%==0 goto delete1
@echo Successfully deleted sharing "%c%"
goto delete

:delete1
@echo Deletion failed, maybe the sharing name "%c%" does not exist.
goto delete


*************************************************************************************
rem Advanced options

:High
@echo (A) Thoroughly delete default sharing (K) Enable sharing service (C) Disable sharing service (ESC) Return
set /p c="c:\>":
if "%c%"=="A" goto mr
if "%c%"=="a" goto mr
if "%c%"=="K" goto on
if "%c%"=="k" goto on
if "%c%"=="C" goto close
if "%c%"=="c" goto close
if "%c%"=="ESC" goto opt
if "%c%"=="esc" goto opt
cls
@echo Please enter the correct command.
goto High
----------------------------------------------------------
:mr
net start Server>nul 2>nul
@echo Deleting default sharing directories.....
net share c$ /delete>nul 2>nul
net share d$ /delete>nul 2>nul
net share e$ /delete>nul 2>nul
net share f$ /delete>nul 2>nul
net share g$ /delete>nul 2>nul
net share h$ /delete>nul 2>nul
net share j$ /delete>nul 2>nul
net share k$ /delete>nul 2>nul
net share admin$ /delete>nul 2>nul
net share ipc$ /delete>nul 2>nul
cls
@echo Deletion of default sharing directories completed
:XZXG
net share
@echo Do you want to modify the registry, otherwise the default sharing will reappear after restart (Y/N) (ESC) Return
set /p c="c:\>":
if "%c%"=="Y" goto ZC
if "%c%"=="y" goto ZC
if "%c%"=="N" goto High
if "%c%"=="n" goto High
if "%c%"=="ESC" goto opt
if "%c%"=="esc" goto opt
cls
@echo Please enter the correct command.
goto XZXG
:ZC
@echo Preparing to generate temporary registry file......
echo Windows Registry Editor Version 5.00>delshare.reg
echo >>delshare.reg
echo "AutoShareWks"=dword:00000000>>delshare.reg
echo "AutoShareServer"=dword:00000000>>delshare.reg
echo Running temporary registry file.....
regedit /s delshare.reg
echo Deleting temporary registry file......
del /f/q/s/a delshare.reg
echo Registry modified.
goto High
----------------------------------------------------------
:on
sc config lanmanserver start= demand>nul 2>nul
net start lanmanserver>nul 2>nul
cls
@echo Successfully enabled sharing service.
goto High
----------------------------------------------------------
:close
net stop Server /y>nul 2>nul
cls
@echo Successfully disabled sharing service.
:close1
@echo Change the startup type of the sharing service for next startup. Default is manual.
@echo (Z) Automatic (S) Manual (J) Disabled (ESC) Return
set /p c="c:\>":
if "%c%"=="Z" goto close2
if "%c%"=="z" goto close2
if "%c%"=="S" goto close3
if "%c%"=="s" goto close3
if "%c%"=="J" goto close4
if "%c%"=="j" goto close4
if "%c%"=="ESC" goto High
if "%c%"=="esc" goto High
cls
@echo Please enter the correct command.
goto close1

:close2
sc config lanmanserver start= auto>nul 2>nul
cls
@echo Successfully changed to automatic status. The service will start automatically when booting next time.
goto High

:close3
sc config lanmanserver start= demand>nul 2>nul
cls
@echo Successfully changed to manual status. The service must be started manually next time.
goto High

:close4
sc config lanmanserver start= disabled>nul 2>nul
cls
@echo Successfully changed to disabled status. To start a disabled service, the startup type should be changed to other values.
goto High

*************************************************************************************
rem Pure DOS operation

:self
@echo Please enter pure DOS commands. (exit) Return
Start /b/wait cmd.exe
goto opt


*************************************************************************************
rem Contact me


:QQ
start /b tencent://message/?uin=83909654
goto opt
*************************************************************************************
rem Usage times

:over
cls
@echo You have reached the usage times, will exit automatically in 5 seconds.
ping 127.0.0.1 -n 6 >nul 2>nul
exit

*************************************************************************************




Just started learning batch processing.. Hehe. Don't mind. It's the first time I wrote it. Hehe. Here I also want to ask. Originally I wanted to make the following content into variables but didn't succeed. Those who know please tell me ha
@echo *******************************************************************************
@echo ┼─────────┼ Current time:
@echo │  ˊ     、 │ %date% %time:~0,2% o'clock %time:~3,2% minutes %time:~6,2% seconds
@echo │' .  ˊ  ˋ﹫. │
@echo │ ╭⌒╮   `ˊ │
@echo │ˊ( .' ) '    │ Walk in someone else's shoes and go your own way, let them figure it out!
@echo │ ﹏_)(﹏.   │╔════════════════╗ Remaining usage times:%times%
@echo │``~﹊`︸~﹊︸~`~ '│║ ╱ヾ Study hard ひ Surf the Internet every dayヾ  ║
@echo ┼─────────┼╚════════════════╝ Signature: Is's Me
@echo *******************************************************************************

[ Last edited by windeshadow on 2007-4-16 at 02:54 AM ]
Floor 170 Posted 2007-04-22 00:19 ·  中国 辽宁 大连 教育网
初级用户
Credits 45
Posts 25
Joined 2007-04-21 13:23
19-year member
UID 85991
Gender Male
Status Offline
I'll download it as soon as I save enough points! @
Floor 171 Posted 2007-04-22 11:57 ·  中国 广东 广州 鹏博士宽带
初级用户
★★
Credits 176
Posts 78
Joined 2007-04-15 10:53
19-year member
UID 85268
Gender Male
Status Offline
Hungry all night, finally finished reading this great post. Understood the stuff, also gained knowledge, and now have a few more stories for bragging in the future...
^_^
Time to eat...
Floor 172 Posted 2007-04-22 13:04 ·  中国 河南 郑州 联通
初级用户
Credits 46
Posts 22
Joined 2006-08-06 13:27
19-year member
UID 59949
Gender Male
From 郑州
Status Offline
Practical, good post. Study hard
Floor 173 Posted 2007-04-26 18:38 ·  中国 山西 太原 小店区 电信
新手上路
Credits 2
Posts 1
Joined 2007-04-25 13:09
19-year member
UID 86439
Gender Male
Status Offline
I think we should post more such programs!
Floor 174 Posted 2007-04-28 04:18 ·  中国 江苏 无锡 电信
初级用户
Credits 80
Posts 43
Joined 2007-04-21 23:44
19-year member
UID 86017
Gender Male
Status Offline
Earning credits.
Floor 175 Posted 2007-04-28 05:58 ·  中国 江苏 无锡 电信
初级用户
Credits 80
Posts 43
Joined 2007-04-21 23:44
19-year member
UID 86017
Gender Male
Status Offline
Came late. Didn't learn anything, everyone teach me
Floor 176 Posted 2007-04-29 05:11 ·  中国 福建 厦门 电信
初级用户
Credits 94
Posts 40
Joined 2007-04-28 22:13
19-year member
UID 86806
Gender Male
Status Offline
Support!!! Bump
Floor 177 Posted 2007-04-29 05:11 ·  中国 福建 厦门 电信
初级用户
Credits 94
Posts 40
Joined 2007-04-28 22:13
19-year member
UID 86806
Gender Male
Status Offline
Support!!! Bump
Floor 178 Posted 2007-04-30 21:32 ·  中国 江苏 连云港 电信
新手上路
Credits 6
Posts 3
Joined 2006-05-30 11:32
20-year member
UID 56253
Status Offline
Studied it carefully
Floor 179 Posted 2007-05-07 11:39 ·  中国 江苏 常州 电信
初级用户
Credits 20
Posts 7
Joined 2007-05-07 11:12
19-year member
UID 87734
Gender Male
Status Offline
Great, just what I need. I'm going to write this for the business department. Using C is tedious, and this is intuitive. The encryption function can be the simplest one.
Floor 180 Posted 2007-05-07 11:39 ·  中国 江苏 常州 电信
初级用户
Credits 20
Posts 7
Joined 2007-05-07 11:12
19-year member
UID 87734
Gender Male
Status Offline
Great, just what I need. I'm going to write this for the business department. Using C is troublesome, and this is more intuitive. The encryption function can be the simplest one.
‹ Prev 1 10 11 12 13 14 25 Next ›
Forum Jump: