Advertisement
Guest User

Untitled

a guest
Oct 27th, 2018
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Winbatch 11.21 KB | None | 0 0
  1. @echo off
  2. TITLE SUBIDOR DE ESTATISTICAS
  3. Color 0a
  4. if "%1" neq "Administrador" call :elevate
  5. cd %~dp0
  6.  
  7. SETLOCAL
  8. SETLOCAL EnableDelayedExpansion EnableExtensions
  9. SET "TextFile=Buscas.txt"
  10. chcp 1252 >nul
  11. set nn=2
  12. set nn2=0
  13. set off=N
  14. set shhh=50
  15.  
  16. if not exist "%textfile%" (
  17. Set "Ti_Tle_Men=Arquivo inexistente"
  18. set "M_ensa=Seu arquivo %textfile% nao existe \n\nEstamos criando um arquivo para voce \nQuando ele abrir salve os links de pesquiza do google\nque voce quer e salve\n\nEx: \nhttps://www.google.com.br/search....\nhttps://www.google.com.br/search...\nhttps://www.google.com.br/search....\nE assim por diante...."
  19. CALL:MENS_AGENS "%M_ensa%" "%Ti_po_men%" "%Ti_Tle_Men%" "1" "64"
  20. if "!botao!"=="OK" (
  21. echo.>%textfile%
  22. notepad %textfile%
  23. ) else ( call:gerabuscas )
  24. )
  25.  
  26.  
  27.  
  28.  
  29.  
  30. SET RandomLine2=1
  31.  
  32.  
  33.  
  34.  
  35. :ini_cccio
  36.  
  37. Set "Ti_Tle_Men=Desligar o computador ?"
  38. set "M_ensa=Desligar o computador após executar o Backup ? \n\nCertifique-se de que todos os aplicativos estão fechados. e seus trabalhos salvos"
  39. CALL:MENS_AGENS "%M_ensa%" "%Ti_po_men%" "%Ti_Tle_Men%" "4" "32"
  40. if "!botao!"=="Sim" (
  41. set "shutdown=Sim"
  42. set /p shhh=Quantidade de tokens ? :
  43. call:num_lt !shhh!
  44. set "off=S"
  45. )
  46. if "!botao!"=="Nao" (
  47. set "shutdown=NÆo"
  48. set "off=N"
  49. )
  50.  
  51.  
  52.  
  53. :main
  54. cls
  55. mode 70,5
  56. set /a nn2=%nn2%+1
  57. if not exist "%textfile%" call:gerabuscas
  58. FOR /f %%a IN ('type "%textfile%"^|find /c /v ""') DO SET /a numlines=%%a
  59. :rando
  60. SET /A RandomLine=(%RANDOM% %% %NumLines%)
  61. set /a RandomLine2=%nn2%*%RandomLine%
  62. if !RandomLine2! gtr 100 SET RandomLine2=100
  63.  
  64.  
  65. rem set "tempor=Timeout /T !RandomLine2!"
  66.  
  67. rem echo %tempor%
  68.  
  69. IF "%RandomLine%"=="0" (SET "RandomLine=" & goto rando) ELSE (SET "RandomLine=skip=%randomline%")
  70. FOR /F "usebackq tokens=* %RandomLine% delims=" %%A IN (`TYPE %TextFile%`) DO (  
  71. set linha=%%A
  72. GOTO Finish
  73. )
  74.  
  75. :Finish
  76. IF "!linha:~0,3!"=="htt" start /min "" !linha!
  77. IF "!linha:~0,1!"=="#" iexplore "https://www.google.com.br/!linha:"=!" & goto ttttt
  78. IF not "!linha:~0,3!"=="htt" start /min iexplore "!linha!"
  79. :ttttt
  80.  
  81. for /l %%i in (1,1,!RandomLine2!) do (
  82. echo.
  83. echo.
  84. @echo  %%i   de   !RandomLine2!
  85.  
  86. ping -n 2 -w 1 127.0.0.1 1>nul
  87. cls
  88. )
  89.  
  90. rem %tempor%
  91. call :killa_
  92. if %nn2%==10 (
  93. call:para_crome
  94. set nn2=0
  95. )
  96. goto main
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109. :MENS_AGENS
  110. if exist "%temp%\$" del /q /s "%temp%\$" >nul
  111. if exist "%temp%\#" del /q /s "%temp%\#" >nul
  112. set "botao="
  113. ::**********************************************************
  114. ::-Selecione o botão da msgbox:
  115. set "b_m=%~4"
  116. ::-0) Somente OK
  117. ::-1) OK and Cancelar
  118. ::-2) Anular, Repetir, Ignorar
  119. ::-3) Sim, Não, Cancelar
  120. ::-4) Sim ou Não
  121. ::-5) Retornar e cancelar
  122. set "i_m=%~5"
  123. ::-Select msgbox icons:
  124. ::-16) Critico
  125. ::-32) Questão
  126. ::-48) Exclamação
  127. ::-64) Informação
  128. set /a style=%b_m%+%i_m%
  129. (
  130. echo. set args=WScript.Arguments
  131. echo. Dim text,style,title,return
  132. echo. text=args.item(0^)
  133. echo. style=args.item(1^)
  134. echo. title=args.item(2^)
  135. echo. x=msgbox(Replace(text,"\n",vbCrLf^),style,title^)
  136. echo. if x=vbOK then
  137. echo. return=1
  138. echo. elseif x=vbCancel then
  139. echo. return=2
  140. echo. elseif x=vbAbort then
  141. echo. return=3
  142. echo. elseif x=vbRetry then
  143. echo. return=4
  144. echo. elseif x=vbIgnore then
  145. echo. return=5
  146. echo. elseif x=vbYes then
  147. echo. return=6
  148. echo. elseif x=vbNo then
  149. echo. return=7
  150. echo. end if
  151. echo. wscript.quit return
  152. )>"%temp%\%~n0.vbs"
  153.  
  154. Cscript /nologo "%temp%\%~n0.vbs" "%M_ensa%" "%style%" "%Ti_Tle_Men%"
  155. echo.%errorlevel%>"%temp%\$"
  156. set /p BB_ton=<"%temp%\$"
  157.  
  158. if "%BB_ton%"=="1" ( echo.OK>"%temp%\#" )
  159. if "%BB_ton%"=="2" ( echo.Cancelar>"%temp%\#" )
  160. if "%BB_ton%"=="3" ( echo.Abortar>"%temp%\#" )
  161. if "%BB_ton%"=="4" ( echo.Retornar>"%temp%\#" )
  162. if "%BB_ton%"=="5" ( echo.Ignorar>"%temp%\#" )
  163. if "%BB_ton%"=="6" ( echo.Sim>"%temp%\#" )
  164. if "%BB_ton%"=="7" ( echo.Nao>"%temp%\#" )
  165. for /f "tokens=*" %%i in ('type "%temp%\#"') do set botao=%%i
  166. SET botao=%botao: =%
  167.  
  168. ::********************
  169. GOTO:EOF
  170.  
  171.  
  172.  
  173. :killa_
  174.  
  175.  
  176.  
  177. call:clen_crhome
  178.  goto:eof
  179.  
  180.  
  181. :clen_crhome
  182. set /a nn=%nn%+1
  183. set /a shhh=%shhh%-1
  184.  
  185. if /i "%off%"=="S" (
  186. if %shhh%==0 ( shutdown -s -t 0 -f )
  187. )
  188.  
  189. if /i "%off%"=="N" (
  190. if %nn%==50 ( set nn=0 )
  191. )
  192. title **** %shhh% **** Finalizar e desligar: %shutdown%
  193. goto:eof
  194.  
  195.  
  196.  
  197. :para_crome
  198.  FOR /f "tokens=1" %%a IN ('"wmic nic get physicaladapter, index, name | findstr TRUE"') DO (
  199.     rem Get the index of the interface
  200.     wmic nic where index=%%a get name | findstr -v Name
  201. echo %%a
  202.     rem Disable the interface - this will flush the previous ip address
  203.     wmic path win32_networkadapter where index=%%a call disable >nul 2>&1
  204.     if NOT %ERRORLEVEL%==0 (
  205.       echo Error %ERRORLEVEL% when disabling interface
  206.     ) ELSE (
  207.       echo Disabling interface...
  208.     )
  209.  
  210.     rem Enable the interface
  211.     wmic path win32_networkadapter where index=%%a call enable >nul 2>&1
  212.  
  213.     if NOT %ERRORLEVEL%==0 (
  214.       echo Error %ERRORLEVEL% when enabling interface
  215.     ) ELSE (
  216.       echo Enabling interface...
  217.     )
  218.  
  219.     echo.
  220.   )
  221.  
  222. call:GOO_GLE
  223.  
  224.  
  225.     del "%tmp%\*.*" /s /q /f
  226.     FOR /d %%p IN ("%tmp%\*.*") DO rmdir "%%p" /s /q
  227. Echo Clearing cache, cookies and history for:
  228. start "" "C:\Windows\System32\rundll32.exe" InetCpl.cpl,ClearMyTracksByProcess 255
  229. start "" "C:\Windows\System32\rundll32.exe" InetCpl.cpl,ClearMyTracksByProcess 2
  230. start "" "C:\Windows\System32\rundll32.exe" InetCpl.cpl,ClearMyTracksByProcess 8
  231. start "" "C:\Windows\System32\rundll32.exe" InetCpl.cpl,ClearMyTracksByProcess 43
  232.  
  233. call :kill chrome
  234. call :kill firefox
  235. call :kill opera
  236. call :kill iexplore
  237. :: -------------
  238. :: Flash Cookies
  239. :: -------------
  240. set /p "=* Flash Player... "<NUL
  241. set FlashCookies=%APPDATA%\Macromedia\Flashp~1
  242.  
  243. >NUL (
  244.     if exist "%FlashCookies%" (
  245.         del /q /s /f "%FlashCookies%"
  246.         rd /s /q "%FlashCookies%"
  247.     )
  248. )
  249. echo Done.
  250.  
  251. goto :EOF
  252.  
  253. :: -------------
  254. :: Google Chrome
  255. :: -------------
  256.  
  257. set ChromeDataDir="C:\Users\%USERNAME%\AppData\Local\Google\Chrome\User Data\Default"
  258. set ChromeCache=%ChromeDataDir%\Cache>nul 2>&1  
  259. del /q /s /f "%ChromeCache%\*.*">nul 2>&1    
  260. del /q /f "%ChromeDataDir%\*Cookies*.*">nul 2>&1    
  261. del /q /f "%ChromeDataDir%\*History*.*">nul 2>&1    
  262.  
  263.  
  264. set ChromeDataDir="C:\Users\%USERNAME%\Local Settings\Application Data\Google\Chrome\User Data\Default"
  265. set ChromeCache=%ChromeDataDir%\Cache>nul 2>&1
  266. del /q /s /f "%ChromeCache%\*.*">nul 2>&1  
  267. del /q /f "%ChromeDataDir%\*Cookies*.*">nul 2>&1    
  268. del /q /f "%ChromeDataDir%\*History*.*">nul 2>&1    
  269. ECHO **** Clearing Chrome cache DONE
  270.  
  271.  
  272. pushd "%LOCALAPPDATA%\Google\Chrome\User Data\Default" 2>NUL && (
  273.  
  274.     set /p "=* Google Chrome... "<NUL
  275.     call :kill chrome
  276.  
  277.     for /f "delims=" %%I in (
  278.         'dir /b ^| find /v /i "bookmarks" ^| find /v /i "extension" ^| find /v /i "preferences"'
  279.     ) do (
  280.         if exist "%%~fI\" (
  281.             rmdir /q /s "%%~fI"
  282.         ) else del /f "%%~fI" >NUL
  283.     )
  284.  
  285.     popd
  286.     echo Done.
  287. )
  288.  
  289.  
  290. :: -------
  291. :: Firefox
  292. :: -------
  293. pushd "%LOCALAPPDATA%\Mozilla\Firefox\Profiles" 2>NUL && (
  294.  
  295.     set /p "=* Firefox... "<NUL
  296.     call :kill firefox
  297.  
  298.     for /f "delims=" %%I in ('dir /b /s /ad *cache* 2^>NUL') do (
  299.         if exist "%%~fI" rmdir /q /s "%%~fI"
  300.     )
  301.  
  302.     popd
  303.     pushd "%APPDATA%\Mozilla\Firefox\Profiles" 2>NUL && (
  304.  
  305.         for %%I in (history.dat formhistory.dat downloads.rdf cookies.txt) do (
  306.             for /f "delims=" %%x in ('dir /b /s /a-d %%I 2^>NUL') do (
  307.                 if exist "%%~fI" del /f "%%~fI" >NUL
  308.             )
  309.         )
  310.         for /f "delims=" %%I in ('dir /b /s /ad *cache* 2^>NUL') do (
  311.             if exist "%%~fI" rmdir /q /s "%%~fI"
  312.         )
  313.         popd
  314.     )
  315.  
  316.     echo Done.
  317. )
  318.  
  319.  
  320. :: -----
  321. :: Opera
  322. :: -----
  323. pushd "%APPDATA%\Opera\Opera\" 2>NUL && (
  324.     set /p "=* Opera... "<NUL
  325.     call :kill opera
  326.     for %%I in (history cookie session) do (
  327.         for /f "delims=" %%x in ('dir /b "*%%I*" 2^>NUL') do (
  328.             if exist "%%~fx\" (
  329.                 rmdir /q /s "%%~fx"
  330.             ) else del "%%~fx"
  331.         )
  332.     )
  333.     popd
  334.     pushd "%LOCALAPPDATA%\Opera\Opera\" 2>NUL && (
  335.         for /d %%I in (*cache) do rmdir /q /s "%%~fI"
  336.         for /d %%I in (*temp*) do rmdir /q /s "%%~fI"
  337.         popd
  338.     )
  339.     echo Done.
  340. )
  341.  
  342.  
  343. :: ------
  344. :: Safari
  345. :: ------
  346. pushd "%APPDATA%\Applec~1\Safari" 2>NUL && (
  347.     set /p "=* Safari... "<NUL
  348.     call :kill safari
  349.     rmdir /q /s "%LOCALAPPDATA%\Applec~1\Safari" 2>NUL
  350.     for /f "delims=" %%I in (
  351.         'dir /b ^| find /v /i "bookmark" ^| find /v /i "configuration"'
  352.     ) do (
  353.         if exist "%%~fI\" (
  354.             rmdir /q /s "%%~fI"
  355.         ) else del "%%~fI"
  356.     )
  357.     echo Done.
  358. )
  359.  
  360.  
  361. :: -----------------
  362. :: Internet Explorer
  363. :: -----------------
  364. set /p "=* Internet Explorer... "<NUL
  365. call :kill iexplore
  366. >NUL (
  367.     set History=%LOCALAPPDATA%\Microsoft\Windows\History
  368.  
  369.     if exist "%History%" (
  370.         del /q /s /f "%History%"
  371.         rd /s /q "%History%"
  372.     )
  373.  
  374.     set IETemp=%LOCALAPPDATA%\Microsoft\Windows\Tempor~1
  375.  
  376.     if exist "%IETemp%" (
  377.         del /q /s /f "%IETemp%"
  378.         rd /s /q "%IETemp%"
  379.     )
  380.  
  381.     set Cookies=%APPDATA%\Microsoft\Windows\Cookies
  382.  
  383.     if exist "%Cookies%" (
  384.         del /q /s /f "%Cookies%"
  385.         rd /s /q "%Cookies%"
  386.     )
  387.  
  388.     reg delete "HKCU\Software\Microsoft\Internet Explorer\TypedURLs" /va /f 2>NUL
  389. )
  390. echo Done.
  391.  
  392.  
  393. :: -------------
  394. :: Flash Cookies
  395. :: -------------
  396. set /p "=* Flash Player... "<NUL
  397. set FlashCookies=%APPDATA%\Macromedia\Flashp~1
  398.  
  399. >NUL (
  400.     if exist "%FlashCookies%" (
  401.         del /q /s /f "%FlashCookies%"
  402.         rd /s /q "%FlashCookies%"
  403.     )
  404. )
  405. echo Done.
  406.  
  407. goto :EOF
  408.  
  409. :kill
  410. taskkill /f /im "%~1.exe" >NUL 2>NUL
  411. set "task=%~1"
  412. :killwait
  413. for /f "tokens=2 delims==" %%I in ('wmic process where "name like \"%%%task%%%\"" get name /format:list 2^>NUL') do (
  414.     ping -n 2 0.0.0.0 >NUL
  415.     goto killwait
  416. )
  417. goto :EOF
  418.  
  419. :Elevate
  420.   Echo CreateObject^("Shell.Application"^).ShellExecute WScript.Arguments^(0^),"Administrador","","runas",1 >"%~dp0Elevating.vbs"
  421.   cscript.exe //nologo "%~dp0Elevating.vbs" "%~dpnx0"
  422.   del "%~dp0Elevating.vbs" >nul
  423. Exit
  424.  
  425.  
  426. :GOO_GLE
  427. SET ADSL=0
  428. FOR /F %%A IN ('"ping -n 1 www.google.com |find /i "recebidos""') DO SET ADSL=1
  429. IF "!ADSL!"=="1" (GOTO ADSL) ELSE (COLOR CF & echo        PRECISA ESTAR CONECTADO NA INTERNET      &  GOTO GOO_GLE)
  430. :ADSL
  431. Color 0a
  432. goto:eof
  433.  
  434.  
  435. :num_lt
  436. Set num=0
  437. Set Ti_po=0
  438. Set T1=%~1
  439.  
  440. :Igu_al
  441.  
  442. If not defined T1 Goto Fim
  443. Set T2=!T1:~0,1!
  444. If !T2!==0 (
  445. Set num=1
  446. Goto Mos_tra
  447. )
  448. Set/a T2=!T2!
  449. If !T2!==0 (
  450. Set Ti_po=1
  451. ) Else (
  452. Set num=1
  453. )
  454.  
  455. :Mos_tra
  456.  
  457. Set T1=!T1:~1!
  458. Goto Igu_al
  459.  
  460. :Fim
  461. If not !num!!Ti_po!==10 (
  462. cls
  463. echo.
  464. echo.
  465. echo.
  466. echo Digite somente numeros
  467. echo.
  468. echo.
  469. echo.
  470.  
  471. Timeout /T 50
  472. Cls
  473. goto ini_cccio
  474. )
  475.  
  476. goto:eof
  477.  
  478. :gerabuscas
  479. (
  480. echo. Batch-satti side de linguagem batch
  481. echo. Batch-satti  conteúdo batch script
  482. echo. Batch-satti  melhor site batch
  483. echo. Batch-satti  msdos
  484. echo. Batch-satti  vbscript
  485. echo. Batch-satti  melhores scripts
  486. echo. Batch-satti  subidor de estatisticas batch
  487. echo. Batch-satti  boss-head super programador
  488. echo. Batch-satti  melhor não tem
  489. echo. Batch-satti  site super show de bola programadores
  490. echo. http://batch-satti.forumeiros.com/t3415-subidor-de-estatisticas#20836
  491. )>Buscas.txt
  492. goto:eof
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement