Dienstag, 29. März 2016

How to display User's Password Expiry on Server 2012 R2

How to see user's password expiry status:

PowerShell Script: display.ps1



$Users = Get-ADUser -Filter {Enabled -eq $True -and PasswordNeverExpires -eq $False} -Properties msDS-UserPasswordExpiryTimeComputed, PasswordLastSet, CannotChangePassword

$Users | select Name, @{Name="ExpiryDate";Expression={[datetime]::FromFileTime($_."msDS-UserPasswordExpiryTimeComputed")}}, PasswordLastSet

Freitag, 25. März 2016

MX Record

Two easy ways to get information about MX Server:

In case you have a real operating system:

dig -t MX cnn.com

or

host cnn.com

In case you use windows:

nslookup -querytype=MX cnn.com

FreeBSD pflog auswerten

sudo tcpdump -n -e -ttt -r /var/log/pflog

Auswertungen:

sudo tcpdump -n -e -ttt -r /var/log/pflog port 80
sudo tcpdump -n -e -ttt -r /var/log/pflog port 80 and host 10.1.1.2

Dienstag, 22. März 2016

PF Log

$ sudo pfctl -n -f /etc/pf.conf 

-n: rules check

after this:
                                               
$ sudo pfctl -f /etc/pf.conf








Block nasty Guys:



table <badhosts> persist
block in quick on fxp0 from <badhosts> to any

$ sudo pfctl -t badhosts -T add 1.2.3.4
$ sudo pfctl -t badhosts -T delete 1.2.3.4
$ sudo pfctl -t bad hosts -T show

Montag, 21. März 2016

Kali Linux 2.0 Parallels Tools installation

In case you can't install Parallels Tools:

Add the needed resources first:

/etc/apt/sources.list

just add:

deb http://ftp.de.debian.org/debian/ stable main contrib non-free
deb-src http://ftp.de.debian.org/debian/ stable main contrib non-free
deb http://security.debian.org/ stable/updates main contrib non-free
deb-src http://security.debian.org/ stable/updates main contrib non-free

Dienstag, 1. März 2016