diff --git a/README.md b/README.md index f93855be828e2e0aa308cc4c0dabfb3ae7971417..bcb354d345739f9b55cb5b50b6b94bfad87f29af 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ ## Client TCP -``` +```powershell $TCP_HOST="myhostname.domain.com" # or : "localhost", or ip like 192.168.0.10. $TCP_PORT=443 @@ -15,7 +15,7 @@ Test-NetConnection -ComputerName $TCP_HOST -Port $TCP_PORT -InformationLevel "De ## Client (s)FTP -``` +```powershell $FTP_USER=remote_username $FTP_HOST=hostname @@ -32,7 +32,7 @@ Get-SFTPItem -SessionId $SFTPSession.SessionId -Path /home/myuser/myfile.txt -De ## Client HTTP(s) -``` +```powershell $HTTP_PROTOCOL="https" # default http; https if secured. $HTTP_HOST="www.mydomain.com" # ex: www.domain.tld $HTTP_PORT="443" # default 80 not secure; 443 @@ -104,24 +104,24 @@ Test-ADUserAuthentication -ADUserLogin $ADUserLogin -ADUserPassword $ADUserPassw Check Member of a group : -``` +```powershell Import-Module ActiveDirectory Get-ADGroupMember $GROUP_NAME | select name,distinguishedname ``` ## Client SMTP -SMTP Parameters -``` + +```powershell $SMTP_HOST="smtp.domain.com" # default $SMTP_PORT="25" # default port 25 not secure, and 587 for encrypted (secure)serveur # $SMTP_USERNAME= # optional # $SMTP_PASSWORD= # optional -SMTP_SUBJECT="Test Subject" -SMTP_BODY="Test Body" -SMTP_RECIPIENT="recipient@domain.com" # Example -# SMTP_FROM="sender@domain.com" # Optional, don't add this if your server are not trusted by the recipient smtp server. +$SMTP_SUBJECT="Test Subject" +$SMTP_BODY="Test Body" +$SMTP_RECIPIENT="recipient@domain.com" # Example +# $SMTP_FROM="sender@domain.com" # Optional, don't add this if your server are not trusted by the recipient smtp server. Send-MailMessage -SmtpServer $SMTP_HOST -Port $SMTP_PORT -To $SMTP_RECIPIENT -Subject $SMTP_SUBJECT -Body $SMTP_BODY @@ -129,13 +129,13 @@ Send-MailMessage -SmtpServer $SMTP_HOST -Port $SMTP_PORT -To $SMTP_RECIPIENT -Su ``` +# Show Listened ports -Client GIT -Git Parameter -Git Testing +```powershell +Get-NetTCPConnection -State Listen,Established +``` -Show Listened ports PROXY HTTP : Reach a HTTP serveur Through a Proxy Set proxy globaly on linux