posted this in
Windows on
February 3rd, 2013 The easiest way to get curl on windows with HTTPS is to simply download and install the git package then add
|
|
c:\Program Files (x86)\Git\bin |
as an environment variable to allow you to run curl from anywhere.
Don’t forget when running curl commands in a DOS prompt to use double quotes.
Example:
|
|
curl https://www.cloudflare.com/api_json.html -d "a=fpurge_ts" -d "tkn=<apikey>" -d "email=<username>" -d "z=domain" -d "v=1" {"response":{"fpurge_ts":1359831767},"result":"success","msg":null,"attributes":{"cooldown":20}}</username></apikey> |
posted this in
Active Directory, Windows on
December 28th, 2012 Active Directory Cheat Sheet
This page contains my Active Directory Cheat Sheet. A list of collected one liners and vb scripts. Enjoy and feel free to add some yourself via comments!
Active Directory One Liners
This isn’t so much a script as an awesome way to reset an active directory user’s password.
How to Reset . . . → Read More: active directory cheatsheet
posted this in
Uncategorized, Windows on
November 19th, 2012 Background
The NTFS file system implemented in NT4, Windows 2000, Windows XP, Windows XP64, and Windows7 supports a facility known as hard links (referred to herein as Hardlinks). Hardlinks provide the ability to keep a single copy of a file yet have it appear in multiple folders (directories). They can be created with the POSIX . . . → Read More: Creating Hard Links in Windows
posted this in
Windows on
November 15th, 2012 The best tool i’ve found to delete duplicate files windows is sfk (aka “Swiss File Knife”).
Installation
1. Download Swiss File knife from there homepage
2. Extract and copy to C:\windows
Usage
sfk dupfind -dir anydir [-file .ext1 .ext2]
find and list duplicate files.
options -diffdirs list only duplicates residing in different root directories. this . . . → Read More: delete duplicate files windows
posted this in
Howto, Linux, Mac, Windows on
November 9th, 2012 Objective
Convert your .crt and .key or .pfx file to a .pem file
Tools
OpenSSL- This tool will do the conversion Note: If you have Visual SVN Server then openssl is located at:
|
|
"%VISUALSVN_SERVER%\bin\openssl" |
Converting .crt .key to .pem
This section describes how to convert a .crt and .key file to .pem
Linux/Unix/MacOS/Windows Convert .crt . . . → Read More: convert .crt .key or .pfx to .pem
posted this in
IIS, Windows on
November 8th, 2012 To redirect in IIS 6.0 using pure javascript create a file called “redirect.htm” and have IIS6 listen on port 80 and redirect to that file:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
<!-- beginning of redirect magic file --> <script type="text/javascript"> function redirectToHttps() { var httpURL = window.location.hostname+window.location.pathname; var httpsURL = "https://" + httpURL ; window.location = httpsURL ; } redirectToHttps(); </script> <!-- end of redirect magic file --> |
posted this in
Defense, Windows on
November 8th, 2012 Using TCP DUMP on windows
This will cover how to use command line TCPDUMP on Windows.
Software Windump Winpcap Examples
|
|
windump.exe -Ap -s65535 port 80 > c:\example_dump.txt |
posted this in
IIS, Windows on
September 24th, 2012 Set proper permissions in IIS 7.x on a remote computer
We will be using psexec icacls on the remote comptuer
Objective: Grant NT AUTHORITY\NetworkService the proper permissions for a particular website on “somecomputer” using credentials “somedomain\someuser somepassword”
The Command to Run
|
|
psexec -u somedomain\someuser -p somepassword -e \\somecomputer cmd /c (^ mkdir c:\temp1\Common ^ & icacls c:\temp1\Common /grant "NT AUTHORITY\NetworkService":^^(OI^^)^^(M^^) ^ & icacls c:\temp1\Common /grant "NT AUTHORITY\NetworkService":(CI^^)^^(M^^) ^ & icacls c:\temp1\Common /grant "NT AUTHORITY\NetworkService":^^(OI^^)^^(CI^^)^^(M^^) ^ ) |
What if we want to do this through jenkins? On the remote computer . . . → Read More: psexec icacls remote computer
posted this in
Howto, Linux, Mac, Windows on
August 23rd, 2012 Goal: join mp3 files single file
Download mp3wrap
Installation
mp3wrap is cross-platform (Windows, Linux, and Mac).
Windows
Download from sourceforge here
Mac
You will need to use Mac Ports and run command:
|
|
sudo port install mp3wrap |
Linux – Ubuntu
|
|
sudo apt-get install mp3wrap |
Linux – CentOS
Using mp3wrap
In this example we will be joining all audio files for CD1 . . . → Read More: join mp3 files single file
posted this in
IIS on
July 24th, 2012 You’ll need to edit the web.config
Web.config
Place the following after system.web tag:
|
|
<trace enabled="true" localOnly="true" pageOutput="false" requestLimit="100" traceMode="SortByTime" /> |
Trace ASP.NET Application
Those options only allow you to see the trace from the server itself. RDP in to the server
Connect to:
|
|
http://your.domain.name.com/trace.axd |