Jump to content











Photo
- - - - -

Info_Hack


  • Please log in to reply
48 replies to this topic

#1 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 13 May 2011 - 05:58 PM

Info_Hack

Get The New Versions Here,at the new download link

Download InfoHack 1a8
Download InfoHack 1a7
Download InfoHack 1a6
Download InfoHack 1a5

Here is a simple tool i made Using mostly NirSoft components(and some standard windows commands),
to grab all the possible information on a Windows computer
its not a ".script" file so it wont work on PE systems(its still Alpha)
this tool will grab info like:browser passwords,email passwords,Ip adders,windows version,drivers, ect.

Posted Image
-------------------------------------------------------------------------------------------------------------
Usage:
Double click on “InfoHack.bat” and look in The "Info" Folder for the Generated "InfoHack.Html" information file

CMD Exit codes:
0 - No Errors
1 - Bad Windows version
2 - Read only Media Error

Known Issues:
-The Components in this tool is made for Windows XP/Vista/7/2008/2003 x86/x64
-Cannot run on any Read-only Media
-The Program or components may be seen as "potentially unwanted/ unsafe applications”, “Viruses” or “hack tools” on some Antivirus Programs
-Works with UAC turned on in Windows 7/Vista/2008, just allow access for the components to run (recommended to turn UAC off and restart, do not right click
And "Run as Administrator")
-Registry copy for XP x64 is currently unsupported (if someone could test which hobocopy exe works with this then i can update in the next version)
-Needs switsh to enable no-pause when run from cmd(will include in next version)
-Needs switsh to enable hidden-mode when run from cmd(will try include in next version)

-------------------------------------------------------------------------------------------------------------
Change Log:
-v1.0 Alpha 8
*Few tweaks (thanx Marten.be2)
*Added Stopwatch (thanx BergerKiller)
*Added Info Hack LOG (thanx Marten.be2 & Wonko)
*Added Registry Backup using "Volume Shadow Service" on a "Live" Windows (Thanks to Wangdera corp.)
*Added Exit Codes when Run from CMD
*Added msvcr100.dll & msvcp100.dll libraries for Registry copy

-v1.0 Alpha 7
*fixed error on HTML index creation with Operating systems with "™" in the name
*Changed the way that the password dump folder gets named, now adds PC name
*Upgraded to MailPassView v1.73
*Upgraded to MessenPass v1.42
*Upgraded to WebBrowserPassView v1.11
*Added MyEventViewer v1.60 & MyEventViewer v1.60 x64 (shows events of last 3 days only)
*Password Encrypted Components.7z (anti-virus can’t read the “components.7z” contents now but can still stop the .exe from running)
*Added Restore Point List (Thanks marten.be2)
*Changed Html index to exclude 64Bit hack lists from index when InfoHack is run on a 32Bit System


-v1.0 Alpha 6
*Fixed Components not extracting to directory with spaces in path (Thanks muggeles)
*Added a few small tweaks (Thanks Wonko)
*Added Windows version detection
*Added Read-only Media check
*Added Support for Windows XP Home Systeminfo

-V1.0 Alpha 5
*Added 7z achiever to compress components

-V1.0 Alpha 4
*Added Detection for 64x Systems

-V1.0 Alpha 3
*Improved Html layout
*Added More Info Hack Components
*Detects old Info Hacks of a UserName and overrides with a new Info Hack

-v1.0 Alpha 2
*Added an Html Index page
*Added a few small tweaks...

-v1.0 Alpha 1
*First Build

Special Thanks to NirSoft For most the program components!!
-------------------------------------------------------------------------------------------------------------
if you have some suggestions ,ideas please share!!!
  • grrrd likes this

#2 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 13 May 2011 - 07:33 PM

JFYI, this may be of use to you:
Try in batch:
(

ECHO something

ECHO something else

)>my.txt

as a replacement to:
ECHO something>my.txt

ECHO something else>>my.txt

:thumbsup:

:worship:
Wonko

#3 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 13 May 2011 - 07:42 PM

Thanx that can work in the infohack.html file creation
if there is any other components that you want to suggest please do tell..

#4 Nuno Brito

Nuno Brito

    Platinum Member

  • Team Reboot
  • 10441 posts
  • Location:boot.wim
  • Interests:I'm just a quiet simple person with a very quiet simple life living one day at a time..
  •  
    European Union

Posted 13 May 2011 - 10:07 PM

Can you place a screenshot as well? I ask mostly for illustrative reasons since this project is a good candidate for being mentioned over the next newsletter.

:thumbsup:

#5 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 14 May 2011 - 08:11 AM

Will do @Nuno Brito

#6 muggles

muggles

    Newbie

  • Members
  • 24 posts
  • Location:New Orleans
  •  
    United States

Posted 14 May 2011 - 08:28 AM

Sweet.

FYI, I had to replace:

7za e Components.7z -y -o%cd%\components>nul
with:
7za e Components.7z -y -o"%cd%\components">nul

for the batch to work on my desktop (spaces in path)

Thanks for sharing.

#7 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 14 May 2011 - 04:09 PM

Thanx that can work in the infohack.html file creation
if there is any other components that you want to suggest please do tell..

No, apart from the repetitions of the redirection when creating the html, at first sight it looks to me "fine and dandy". :thumbsup:
Only two very little things :cheers:.

    • a script for DOS/WIN9x/ME needs to have .bat extension
    • a script for DOS/WIN9x/ME AND NT family should have .bat extension (and an internal version checking)
    • a script intended ONLY for NT family should have .cmd extension
  • The REM statement (NOT a prblem in your batch, as you haev only a few of them) tends to slow script execution as whatever follows the "REM" is anyway parsed. Using instead of "REM" "::" make the whole line be skipped.

:rofl:
Wonko

#8 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 16 May 2011 - 10:17 AM

Here is some PIX:
(Edit: moved pix to first post)
I will fix the errors later this week
(why cant i edit my first post?)

#9 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 16 May 2011 - 10:42 AM

(why cant i edit my first post?)

It's a policy, JFYI:
http://reboot.pro/5753/

PM Nuno or pscEx and see if they can grant you the "privilege"/"permission", since you are a nice contributor to the Forum :), even if you haven't yet reached a "high post count" (that should grant you some privileges, like increasing attachment space, etc.).

:cheers:
Wonko

#10 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 16 May 2011 - 06:54 PM

It's a policy, JFYI:
http://reboot.pro/5753/

PM Nuno or pscEx and see if they can grant you the "privilege"/"permission", since you are a nice contributor to the Forum :), even if you haven't yet reached a "high post count" (that should grant you some privileges, like increasing attachment space, etc.).

:cheers:
Wonko

Thanx wanko i'm now a developer

a script for DOS/WIN9x/ME AND NT family should have .bat extension (and an internal version checking)

I do not understand what you are trying to say here?
must i code a internal CMD.exe version check or a Internal Windows version check?

#11 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 16 May 2011 - 07:26 PM

Thanx wanko i'm now a developer

Good news! :thumbup:

I do not understand what you are trying to say here?
must i code a internal CMD.exe version check or a Internal Windows version check?

If you have the batch have a .cmd extension it will ONLY execute on NT based systems.
If you have the batch have a .bat extension it will BOTH execute on NT based Systems AND DOS/Win9x/Me.

If you want to control WHICH version of windows can run the batch, you need a version control, examples, very basic:
:: Check OS version

IF NOT "%OS%"=="Windows_NT" GOTO Syntax
More complex (and complete):
http://www.robvander...amples.php?fc=W
http://www.robvander.../winver_bat.txt
http://www.robvander.../winver2_nt.txt

:cheers:
Wonko

#12 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 19 May 2011 - 04:57 PM

Update to Info_hack 1a6
see first post..
as always:"if you have some suggestions ,ideas please share!!!"

#13 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 20 May 2011 - 12:10 AM

If I may, don't use "forever" the filename "infohack.zip". :cheers:

Though 8.3 names are always a good idea :happy_dance: we are not actually limited to them, now you have two links in this thread:
  • Download InfoHack 1a6
  • Download InfoHack 1a5
BOTH linking to a file named Infohack.zip :cheers: (actually to two different versions with the same filename).

It would be nice IMHO if next Infohack 1a7 would link to a file named Infohack_1a7.zip, as it may simplify, at a zero cost, the life of the people that download/try the thingy.

:ph34r:
Wonko

#14 martin.be2

martin.be2

    Newbie

  • Members
  • 12 posts
  •  
    Netherlands

Posted 27 May 2011 - 09:32 PM

Update to Info_hack 1a6
see first post..
as always:"if you have some suggestions ,ideas please share!!!"



Hi DarkPhoeniX

You have made almost the same script I have made a few years ago
My idea was to make a kind of inventory and a also wanted to make it as modular as possible

I don’t want to break down your script, but I want to make some suggestions to make it more modular
So you don’t have to change the script every time you find some more things you want to inventory


I will post some parts of my batch to give some ideas


you can use wmi to find out more about the windows version
(but you cant relay on this for 100% !) with the following command


for /f "tokens=1 delims=^|" %%a in ('wmic /node:localhost os get name ^| find "icrosoft"') do set fullver=%%a

sometimes it can be very useful to find out the restore point (you need to check if system is > XP


if not "%versie%"== "2000" (

	echo restorepoint

	setlocal

	for /f "Tokens=*" %%a in ('cscript //nologo .\util\erp.vbs') do (

 	 	echo %%a >> .\%COMPUTERNAME%\restorpoints.txt

		)

	)


and the code for erp.vbs is


set eRP = getobject("winmgmts:\\.\root\default").InstancesOf ("systemrestore")

for each Point in eRP

wscript.Echo point.creationtime & ":" & point.Description & ":" & point.sequencenumber & ":" &point.RestorePointType

next


Also, I would check to find out if there is a domain on the computer you are running the script


if "%USERDNSDOMAIN%" == "" goto nodomain

so if there is a domain, you can change your nirsoft commands to inventory the complete domain on some commands (like finding out the productkeys etc etc)

I also would suggest to encrypt the 7zip file
if you encrypt this with a simple password you will be sure that your tools will not be deleted on the first moment you insert your usb stick in some computer :)
so copy it first to a local disk, and then extract it with a simple password

I see you are running 64 bits versions of nirsoft
as far I know you don’t need to, because every 32 bits version will run on a 64 bit system, and there is no difference in the output


then about the way I run the command

I use the following method


set curdir=%cd%

set regkeys=%curdir%\lists\regkeys.txt



for /f "tokens=1,2 delims=$" %%A in (%regkeys%) do (

 %reg% export %%B .\%COMPUTERNAME%\regkeys\%%A > nul

 )


and I post you a simple regkeys.txt below

winvnc_u.txt$"HKCU\SOFTWARE\ORL\WinVNC3" 

winvnc_m.txt$"HKLM\Software\ORL\WinVNC3" 

mru_urls.txt$"HKCU\Software\Microsoft\Internet Explorer\TypedURLs" 

mru_run.txt$"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\RunMRU" 

office2k.txt$"HKLM\SOFTWARE\Microsoft\Office\9.0\Registration\ProductID"

rdp_ts.txt$"HKCU\Software\Microsoft\Terminal Server Client"

mru_ext.txt$"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\ComDlg32\OpenSaveMRU"

shellfld.txt$"HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders"

produopt.txt$"HKLM\SYSTEM\CurrentControlSet\Control\ProductOptions"


I am using the same routine for running the application so I don’t have to change the program every time I want to add some commands

the list I use is also conditional because i don’t want to run all commands on every system
i post you a example of my application list






if "%privacy%"=="yes" (

 echo .\download\recentfilesview.exe /shtml .\%COMPUTERNAME%\nir\recentfv.html

 echo .\download\iehv.exe /shtml .\%COMPUTERNAME%\nir\iehv.html

 echo .\download\iecacheview.exe /shtml .\%COMPUTERNAME%\nir\iecache.html

 echo .\download\mylastsearch.exe /shtml .\%COMPUTERNAME%\nir\search.html

 echo .\download\mozillahistoryview.exe /shtml .\%COMPUTERNAME%\nir\mozhiss.html

 echo .\download\mozillacacheview.exe /shtml .\%COMPUTERNAME%\nir\mozcache.html

 echo .\download\operacacheview.exe /shtml .\%COMPUTERNAME%\nir\operacache.html

 echo .\download\nk2view.exe /shtml .\%COMPUTERNAME%\nir\contacts.html

 echo .\download\muicacheview.exe /shtml .\%COMPUTERNAME%\nir\muicache.html

 echo .\download\skypelogview.exe /shtml .\%COMPUTERNAME%\nir\skypelog.html

 echo .\download\livecontactsview.exe /shtml .\%COMPUTERNAME%\nir\livecontacts.html

 echo .\download\shellbagsview.exe /shtml .\%COMPUTERNAME%\nir\shellbagsview.html

 echo .\download\usbdeview.exe /stab .\%COMPUTERNAME%\nir\usbview.txt

 if "%crome%"=="yes" echo .\download\chromecacheview.exe /shtml .\%COMPUTERNAME%\nir\chromecache.html

 )


so the application list will be modularly generated if some conditions are ok
(in this case the environment privacy)

I can continue to post lots of other examples but I’m not sure if your goal is the same as my goal

I hope that I have given you some new ideas and maybe you can use them

Regard, Martinb

#15 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 28 May 2011 - 05:59 AM

thanx @ martin.be2 real useful code you have their

#16 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 28 May 2011 - 01:09 PM

@martin.be2

Unless there is a "trade secret" involved :thumbup:, and of course ONLY if you wish to do so :), why don't you share your "whole" script or batch or .vbs or whatever? :)

There may be parts that you think irrelevant (or not worth to mention) :w00t: that other people may insted find either simply interesting or "the key, missing piece" to solve a completely different puzzle. :frusty:

I am pretty sure that the boot-land reboot.pro members interested in this kind of things will be able to "extract" from your script the parts they find useful and/or get inspiration from them. ;)

:cheers:
Wonko

#17 martin.be2

martin.be2

    Newbie

  • Members
  • 12 posts
  •  
    Netherlands

Posted 28 May 2011 - 05:09 PM

@martin.be2

Unless there is a "trade secret" involved :frusty:, and of course ONLY if you wish to do so :thumbup:, why don't you share your "whole" script or batch or .vbs or whatever? :)



No secrets, but I think its better to share ideas, then share scripts
if i share the complete script then most people will not take the time to understand the script
Like I said, i made the script modular, so you don’t need to change the code if you want to add something new


Just a other example how you could start some simple commands




echo set $set.txt

echo ver $ver.txt

echo ipconfig /all $ipconfig.txt

echo route print$route.txt

echo tracert www.google.nl -h 3$tracert.txt

echo net use $netuse.txt

echo net share $netshare.txt

echo net view $netview.txt

echo net start $services.txt

echo net accounts $net_accounts.txt

echo net file $net_file.txt

if "%domain%" == "yes" (

 echo net group $net_group.txt

 echo net view /domain $net_vdom.txt

 echo net localgroup administrators /domain $net_lg_dom.txt

 echo net user %USERNAME% /domain $userinfo_dom.txt

 echo net accounts /domain $net_accounts_dom.txt 

 echo net accounts $net_accounts_loc.txt

 )

if "%domain%" == "no" (

 echo net view /domain $net_vdom.txt

 echo net user %USERNAME% $userinfo_loc.txt

 echo net accounts $net_accounts_loc.txt

 )



echo tasklist $tasklist.txt

echo schtasks /Query /FO CSV /V $schtasks.txt

echo net localgroup $net_localgroup.txt

echo net session $net_session.txt

echo net user $net_user.txt

echo net localgroup administrators $net_lg.txt

echo .\download\uptime $uptime.txt

echo .\download\quser.exe $quser.txt

echo netstat $netstat.txt

if "%portscan%"=="yes" echo .\download\fscan.exe -e -p 21,22,25,80,443,445,5800,5900,3389 %startip%-255  -t 100 -c 100 $fscan.txt

echo arp -a $arplist.txt

echo nbtstat -c $nbtstat.txt

echo nbtstat -a %COMPUTERNAME% $nbtstat2.txt

echo netsh dump $netsh_dump.txt

if not "%versie%" == "2000" echo netsh firewall show config $netsh_firewall.txt

echo sc query $sc_query.txt


this is some part of a file named cmdlist_tmp.txt

I run the following code to execute this


copy %fullcmds_tmp% fullcmds.bat > nul

call fullcmds.bat > fullcmds.txt

del fullcmds.bat



echo start executing commands



for /f "delims=$" %%A in (fullcmds.txt) do (

 for /f %%i in ('echo %%A') do echo running %%i & %%A > nul

)



%func% log end fullcommands

del fullcmds.txt



A other suggestion is to build a execute list depending on some other info

Its useless to start the program WirelessKeyView.exe when there is no wifi card on the computer


ipconfig | find "ireless" > nul

if errorlevel == 1 set wifi=no


Hope its useful for some people

#18 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 28 May 2011 - 05:20 PM

...and this way most (other) people won't spend the time to reassemble the bit and pieces....:whistling:

It's a no-win/no-win situation, IMHO. :dubbio:

Personally I think that sharing BOTH ideas and scripts is the best, my suggestion was not to have the script INSTEAD of the info. :)

Only apparemtly Off Topic :ph34r: an autoit script that may give some ideas:
http://www.autoitscr...fo-without-gui/

:cheers:
Wonko

#19 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 01 June 2011 - 05:03 PM

Only apparemtly Off Topic :dubbio: an autoit script that may give some ideas:
http://www.autoitscr...fo-without-gui/

Wooo this is a lil over me ,i dont even know how to run this...

Just a other example how you could start some simple commands

il see if i can fit this in to a future alpha version but i have to setup a domain first to test....

#20 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13439 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 01 June 2011 - 05:28 PM

Wooo this is a lil over me ,i dont even know how to run this...

It is an AutoIt script.
In order to run it you need the AutoIt Interpreter:
http://www.autoitscr...om/site/autoit/
http://www.autoitscr...toit/downloads/
and, once you have it "ready to go" you can actually "compile" it using the AutoIt coverter (this is one of the IMHO advantages of AutoIt, it can be used BOTH as a scripting language and as a "compiler" to obtain a selfstanding .exe).

:dubbio:
Wonko

#21 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 01 June 2011 - 07:40 PM

Update to Info_hack 1a7
see first post..
as always:"if you have some suggestions ,ideas please share!!!"

#22 gutnik

gutnik

    Member

  • Advanced user
  • 46 posts

Posted 02 June 2011 - 04:27 PM

This potpourri is useful thing. Unfortunatelly it easily blocked by some programs.
L.A.G.

#23 dsolomon

dsolomon

    Frequent Member

  • Advanced user
  • 237 posts

Posted 02 June 2011 - 08:56 PM

might there be any way we can use this awesome program inside of a livexp environment?
i was thinking maybe use it with runscanner?
just a thought.
this tool would be very wanted if you could scavenge an offline windows drive.

#24 DarkPhoeniX

DarkPhoeniX

    Frequent Member

  • Team Reboot
  • 452 posts
  • Location:In the middle of nowhere
  • Interests:Interesting Things
  •  
    South Africa

Posted 03 June 2011 - 08:34 PM

might there be any way we can use this awesome program inside of a livexp environment?i was thinking maybe use it with runscanner?just a thought.this tool would be very wanted if you could scavenge an offline windows drive.

i did some research in to this already and only some of the components can be used with runscanner like produkey but others like broserpassview needs you to run the program on the system you are using (it uses the files from the pe and not the host's OS)it might beg more research to pull it off...

This potpourri is useful thing. Unfortunatelly it easily blocked by some programs.
L.A.G.

jap the program is more usfull as a vulnerably test then a hack tool i use it as a information gathering tool on my customers pc's
You know like if thy forgot their passwords or somthing....

#25 martin.be2

martin.be2

    Newbie

  • Members
  • 12 posts
  •  
    Netherlands

Posted 08 June 2011 - 06:20 PM

Update to Info_hack 1a7
see first post..
as always:"if you have some suggestions ,ideas please share!!!"



Some suggestions:

1- Please don’t use the exit command unless you really need to.

(I want to get back to the prompt when I start a batch, I don’t want to get out of the command line)

2- Try to log output to file AND console, so even without screen output you will have results, and its useful to know the date/time

3- I would change the line {set Directory="Passwords_%username%_%userdomain%"} to {set Directory="Info_%username%_%userdomain%"}

You can use "subroutines" in batch but most people don’t know this
will give you a example you can use in your batch
the line “goto :EOF” will return to the point you started the “call”

place the first 2 line somewhere in top of your batch

set log=.\%Directory%\log.txt

set logline=call log



place the following “sub routine” somewhere at the end of your batch
(the following part you can simply copy/paste on your current batch)

:: --------------------------------------------------------------------------------------------------------------------------------------------

%logline%  -------------------------------------------------------------------------------

%logline% Cleaning Temp files



del "%comp%\*.*" /f  /q

rmdir /s "%comp%\" /q

%logline% Cleaning Done

%logline% Press Any key to Exit

pause>nul

goto end



:error1

cls

color 47

%logline% Non NT Windows or Bad Windows Version

%logline% Detected Windows: %win%

%logline% The components in this tool is made for Windows XP\Vista\7

%logline% Press Any key to Exit

pause>nul

goto end



:error2

cls

color 47

%logline% This Tool cannot be run in read-only media!

%logline% Press Any key to Exit

pause>nul

goto end



:log

shift

shift

set comment=%0 %1 %2 %3 %4 %5 %6 %7 %8 %9

call :timestamp

echo %timestamp% %comment% >> %log%

echo %timestamp% %comment%

goto :EOF



:timestamp

for /F "tokens=1-4 delims=:., " %%a in ("%TIME%") do set tijd=%%a:%%b:%%c

for /F "tokens=1-4 delims=/- " %%A in ('date/T') do set datum=%%A-%%B-%%C-%%D

set timestamp=[%datum%][%tijd%]

goto :EOF



:end

Its possible the timestamp needs some little work to make it international
Its also possible that I made some errors on the code, but I’m sure you will find out the useful pieces to place in your batch

If you find this useful i will give some more suggestions on your next beta


Regards, Martinb




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users