WinHttp Proxy settings
Some Windows services, such as the Crypto API, use the winhttp. If your behind a proxy server which doesn't auto configure, then you must setup the proxy settings manually using proxycfg.
C:\>Proxycfg.exe -u proxycfg -u : import proxy settings from current user's Microsoft Internet Explorer manual settings (in HKCU)
Defrag XP from the command line
If your normal login account does not have administrative priveledges on your machine, you can't run the defragmenter. If you have a seperate login account, you can run it from the command line like this:
%SystemRoot%\System32\cmd.exe runas /user:kbcfp\eggebr_admin %SystemRoot%\System32\dfrg.msc
Run the add/remove programs:
rundll32.exe shell32.dll,Control_RunDLL appwiz.cpl
My cygwin (bash) prompt
export PS1="\[\e[32m\]\h\[\e[0m\]@\[\e[34m\]\W$\[\e[0m\] "
Command Prompt Here
Merge this into your registry:
Windows Registry Editor Version 5.00 [HKEY_CLASSES_ROOT\Directory\shell\OpenNew] @="Command Prompt Here" [HKEY_CLASSES_ROOT\Directory\shell\OpenNew\Command] @="cmd.exe /k cd %1"
It seems that when installing iTunes 6.0.2 you have to stop your Cygwin services. I run sshd & cron. For other applications, iTunes asks you to shut them down first. I'm a little concerned that I have to close Microsoft Money in order to install iTunes.
How to check access to Shared Resources Useful to find out who has a file open.
- Unix Utilities Common utilities like grep compiled as Win32 executables.
- PrimoPDF Free PDF Creator. Convert to PDF from any application by simply 'printing' to the PrimoPDF printer - it couldn't be easier! It's not trialware or shareware. It runs with no ads, and it's very simple.
Logged in user
Find a user's computer name and IP address with their username:
net send someuser "" > null nbtstat -c ... find their login with <03> netstat -A theirip
How to find in the logged in user of a Windows XP SP2 Machine
The above used to work fine, until SP2 came about, and by default disabled the messenger service. Here is a way to figure it out, with only user level permissions.
You can still use 'ping -a' to get a hostname from an IP. Next, open regedt32 and select 'Connect to network registry...'. Enter the name of the computer and connect. You'll see the remote computer, and two keys:
* HKEY_LOCAL_MACHINE * HKEY_USERS
You won't have access to open HKEY_LOCAL_MACHINE, and you'll only get to browse the top of HKEY_USERS. However, from here, you should see the SID of the logged in user. This will look like 'HKEY_USERS\S-1-5-21-1547161642-1958367476-1801674531-21293'. Right click and copy this key.
Now, you just need to find out the username for this SID. Download the free sidtoname tool.
You can run the tool like this:
C:\Documents and Settings\eggebr>sidtoname HKEY_USERS\S-1-5-21-1547161642-1958367476-1801674531-21293 SidToName V02.00.00cpp Joe Richards (firstname.lastname@example.org) March 2003 [User]: KBCFP\eggebr The command completed successfully.
When all else fails
I attempt to Remote Desktop to the machine in question. I then log in, and it asks if I want to boot the user 'Domain\Joe' off his PC.