I needed to get a listing of all staff available to email our Dynamic Distribution Group, but in the output it only included 16 records, but I knew there were a lot more. It appears that there is a limit of 16 and you can see the limit by entering in and then modify it…
Counting AD Items
Many times I simply need the number of people in an AD group. There are two ways of doing this (and probably a lot more) that I have done this. One way is to define an object and then assign the output of getting the members from a group to the object, and then getting…
Finding AD Groups
Need to find an AD Group but not sure of the name. The -Filter options comes in handy. Thus to find a group that has the name VPN in it, simply do the following:
JQ Searching for X.509 Certs
When parsing through bro log files, the bro-cut command was simple. But now that files are being written in JSON format, it ain’t so easy. At least for me, as I can’t find any good resources yet on querying these files. But I have found a work around. So this is the example. I want…
IPMI Finding the IP
If you are ever in need of finding the management cards IP address on a Linux box and have access to the OS, you can simply get it by running Of course, you need to run this with elevated privledges.
Windows Hash Utility
Linux has some cool tools for getting file hashes like md5sum and sha1sum, but Windows 7 and 10 has “certutil”. It is easy to use with simply running So a simple example to run it on the file notepad.exe located in C:\Windows\System32, would be For the hash algorithms, you have your choice of MD2-4, SHA1,…
Accessing Admin Shares with Local Account
I was attempting to access some admin shares on a machine, using a local administrator account as I did not want to use a domain account. Seems I was getting access denied even though the user is in the local administrators group. It appears that there is an UAC enforcement to prevent local admins from…
Searching for User Agent String
Let’s say you have a log file that is of your web traffic and you are collecting a lot of things including user agent strings; such as And let’s say you want to just get the user agent string in each connection and get a count or do something else with it. You can use…
AWK Functions
You can use AWK to convert a file to lowercase or uppercase. For example you can run to print out all of the content of the file but print it out as lowercase.
Unique Sort
I used to use the “uniq” command to get a unique count of output, usually after sort. However the command takes care of that for you!