SlideShare uma empresa Scribd logo
1 de 106
Baixar para ler offline
Practical PowerShell Programming 
for 
Professional People 
Ben Ten 
(@Ben0xA) 
Slides: http://www.slideshare.net/BenTen0xA 
DerbyCon 2014
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
About Me 
Ben Ten (0xA) 
@Ben0xA - twitter 
Chicago - #burbsec 
Vice President 
Security Officer 
Developer 
PoshSec Framework Developer / Creator 
Gamer 
Geek
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
SecurityFail 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Overview 
●Languages and Development 
●PowerShell Scripting 
●Resources 
●Q&A 
●PSA: This is mostly live code scripting in 
PowerShell. Please code along with me!
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Overview 
Feel free to interrupt and ask questions!
Languages and Development 
Before we begin, a bit of a primer! 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
●Styles of Coding 
●Syntax 
●Getting Help 
●Starting Out
Languages and Development 
Styles of Coding/Scripting/Development 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
●Novice 
●Avid Scripter 
●Full Time Developer 
●Code Monkey
Languages and Development 
Styles of Coding/Scripting/Development 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
●Novice 
●Avid Scripter 
●Full Time Developer 
●Code Monkey
Languages and Development 
Syntax 
syn•tax (sĭnˈtăksˌ) – the rules that govern 
how a script, or program, is developed in a 
given language. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Languages and Development 
Syntax 
White Space, parens (), commas, periods, 
quotes (“ vs '), tabs, braces [], curly 
brackets {}, colons :, semi-colons ;, all play 
an integral part in the syntax of a 
language! 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Languages and Development 
Getting Help! 
RTF Manual/Docs/Reference 
Often times, the documentation will have 
an answer for what you are trying to 
accomplish. *NOT ALWAYS THOUGH* 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Languages and Development 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Getting Help! 
Interactive Help 
● ? 
●F1 
●Intellisense (Ctrl+Space) 
●Get-Help
Languages and Development 
Getting Help! 
Search Engines FTW! 
Google is not the end all in searches. For 
Development I prefer DuckDuckGo! 
https://duckduckgo.com 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Languages and Development 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Languages and Development 
@JimmyVo – DuckDuckVo! 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Overview 
PowerShell is a task automation and 
configuration management framework 
from Microsoft, consisting of a command-line 
shell and associated scripting 
language built on the .NET Framework. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Overview 
PowerShell was designed by : 
● Jeffrey Snover (@jsnover) 
●Bruce Payette (@BrucePayette) 
● James Truher 
Initial release was November 14, 2006 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Overview 
PowerShell is a part of the Windows 
Management Framework. WMF 5.0 was 
released on April 3, 2014. 
For today's scripting we will be using WMF 
3.0. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
You will need: 
●Windows Management Framework 3.0 
●Microsoft .NET Framework 4.5 
●Text Editor (your choice) 
●Sublime Text http://www.sublimetext.com/ 
●Komodo Edit http://komodoide.com/komodo-edit/ 
●PowerShell ISE (comes with WMF)
PowerShell 
File Name Extensions 
.ps1 – Script Files 
.psm1 – Script Module Files 
.psd1 – Script Manifest Files 
.ps1xml – Formatting and Type Files 
.dll - Cmdlet and Provider Assemblies 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
File Name Extensions 
.ps1 – Script Files 
.psm1 – Script Module Files 
.psd1 – Script Manifest Files 
.ps1xml – Formatting and Type Files 
.dll - Cmdlet and Provider Assemblies 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Cmdlets, Functions, and Scripts Oh My! 
From a functional standpoint, cmdlets, 
functions, and scripts are practically the 
same. 
They are a way to call a specific block of 
code. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Cmdlet: 
Written in a compiled .NET language. 
Easier to deploy. 
Help files are easier to write. 
Has support for parameter validation. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Function: 
Written in a PowerShell language. 
Has to be deployed with a library. 
Help is written inside the function. 
Parameter validation has to be done in the 
function itself. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Script: 
Written in a PowerShell language. 
Is invoked by calling the .ps1 file. 
Deployed by itself or in a manifest file. 
Can contain functions. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Set-ExecutionPolicy 
Before you can run your custom scripts 
you have to set the ExecutionPolicy to 
RemoteSigned. 
In PowerShell type: 
Set-ExecutionPolicy RemoteSigned 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
PowerShell 
HelloWorld.ps1 
Enough of the primer! Let's get coding! 
This is where you code along with me if 
you can! 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Variable(s): 
a symbolic name associated with a value 
and whose associated value may be 
changed. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Hard-Coded: 
Typing the value directly into your script. 
Our “Hello World” text was hard-coded. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
PowerShell Variables: 
A PowerShell variable is defined with the 
dollar sign $ followed by the name of the 
variable. 
For example: $message is a variable. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
PowerShell Variables: 
Let's rewrite our HelloWorld.ps1 to use a 
variable $message with our text “Hello 
World”. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Quotes! Single vs Double 
Double Quotes (“) will attempt to resolve 
any variables before anything is printed to 
the screen. 
Single Quotes (') will print exactly what is 
typed between the quotes. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Backtick ` 
The backtick, or grave accent, is a special 
escape character. This means that you 
want the next character to be printed and 
not interpreted in anyway. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
HelloWorld.ps1 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Getting Input 
Write-Output is great. But how do you get 
information from a user? 
Read-Host 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Getting Input 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Getting Input 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
A Condition is: 
a feature of a programming language 
which perform a different set of 
computations or actions depending on 
whether a programmer-specified boolean 
condition evaluates to true or false. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
A Condition is: 
Is the stop light is green? Keep going. 
Is the stop light is red? Stop. 
Is the stop light is yellow? Floor it!!!! 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
A Condition expressed: 
● If - Beginning of the condition. 
●Else - Evaluates only if preceding condition(s) 
is(are) false. 
●ElseIf – Evaluates if preceding condition(s) 
is(are) false with a new condition. 
●Switch – Multiple conditions for a single 
variable or object. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
A Conditional Operator: 
-and = both conditions must be true. 
-or = only one of the conditions must be 
true. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
A Conditional Operator: 
-eq = Equals 
-lt = Less Than 
-gt = Greater Than 
-ne = Not Equal 
-ge = Great Than or Equal 
-le = Less Than or Equal
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
A Conditional Operator: 
-Like 
-NotLike 
-Match 
-NotMatch 
-Contains 
-NotContains 
-In 
-NotIn 
-Replace
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Operator Precedence: 
When operators have equal precedence, 
Windows PowerShell evaluates them from 
left to right. The exceptions are the 
assignment operators, the cast operators, 
and the negation operators (!, -not, -bnot), 
which are evaluated from right to left. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Operator Precedence: 
You can use enclosures, such as 
parentheses, to override the standard 
precedence order and force Windows 
PowerShell to evaluate the enclosed part 
of an expression before an unenclosed 
part. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Conditional Logic 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Parameters 
A Parameter is: 
A variable that allows you to pass an 
object to a Cmdlet, Function, or Script. 
Get-ChildItem 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Parameters 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Parameters 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Get-Help Get-ChildItem 
Get-ChildItem [[-Path] <String[]>] [[-Filter] <String>] [-Exclude <String[]> 
[-Name] [-Recurse] [-UseTransaction [<SwitchParameter>]] 
[<CommonParameters> 
Get-ChildItem [[-Filter] <String>] [-Exclude <String[]>] [-Force] [-Include 
-LiteralPath <String[]> [-UseTransaction [<SwitchParameter>]] 
[<CommonParame 
Get-ChildItem [-Attributes <FileAttributes]>] [-Directory] [-File] [-Force] 
[-UseTransaction] [<CommonParameters>]
Parameters 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Parameters 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Objects vs Text 
PowerShell is Object Based. 
Even if you see text on the screen, that 
text is actually a “String” object. 
You can access the members of the object 
using the . operator after the variable 
name. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Objects vs Text 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Piping 
Piping is: 
a way of moving something, unchanged, 
from one place to another.
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Piping 
Piping is represented by the | (pipe) 
character. 
A pipe takes the object from the left side 
and passes it to the right side. 
Note: When passing to another cmdlet, $_ 
is used to reference the passed object.
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Piping
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Piping
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Loops 
Loops: 
A way to perform the same block of code 
for a specific number of times, until a 
specific condition is met, or while a 
specific condition exists.
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Loops 
Loops: 
●ForEach 
●ForEach-Object 
●For 
●While 
●Do While 
●Do Until
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Loops
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Loops
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Loops
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Comments 
Comments are defined by the # symbol. 
Block comments are enclosed with <# and 
#>. 
.SYNOPSIS 
.DESCRIPTION 
.PARAMETER 
.EXAMPLE
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Comments
Putting it all Together 
The final program! 
Requirements: 
●Search all files. 
●Find the ones that were modified in a 
specific date range. 
●Create a list of those files and display 
them. 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Pitfalls 
Don't overuse the Pipe! Not everything has 
to be done in a single line. 
It's more important that you understand 
the code before you try to condense it to a 
single line.
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Pitfalls 
With Loops, start small then open the 
valve all the way! 
You can get more than you wanted, or get 
stuck in an endless loop. 
Especially true when doing File operations!
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Resources 
Freenode (irc.freenode.net) 
#PowerShell, #pssec, #poshsec channels. 
Learn Windows PowerShell in a Month of 
Lunches ~ Don Jones 
Carlos Perez – PowerShell Workshop at 
DerbyCon.
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Resources 
PoshSec – https://github.com/PoshSec 
PoshSec Framework 
PowerSploit – 
https://github.com/mattifestation/ 
Posh-SecMod – 
https://github.com/DarkOperator/
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Resources 
http://www.slideshare.net/BenTen0xA/ 
practical-powershell-programming-for-professional- 
people
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
Thanks! 
@securitymoey 
@jaysonstreet 
@DerbyCon 
@tonikjdk 
@darkoperator 
@mattifestation 
@obscuresec 
@harmj0y
Contact - Q&A 
Ben Ten (0xA) 
@Ben0xA - twitter 
http://ben0xa.com 
https://poshsec.org 
web@ben0xa.com 
Ben0xA – LinkedIn, Github, keybase, etc. 
irc.freenode.net 
#burbsec, #poshsec, #pssec 
http://www.slideshare.net/BenTen0xA 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA) 
QUESTIONS?!
Thank You! 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)
Thank You! 
Practical Powe rShell Programming for Professional People 
DerbyCon - Ben Ten (@Ben0xA)

Mais conteúdo relacionado

Mais procurados

Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016Clark Everetts
 
TAKING PHP SERIOUSLY - Keith Adams
TAKING PHP SERIOUSLY - Keith AdamsTAKING PHP SERIOUSLY - Keith Adams
TAKING PHP SERIOUSLY - Keith AdamsHermes Alves
 
Theory and practice – migrating your legacy code into our modern test drive...
Theory and practice – migrating your  legacy code into our modern test  drive...Theory and practice – migrating your  legacy code into our modern test  drive...
Theory and practice – migrating your legacy code into our modern test drive...Lars Jankowfsky
 
How to analyze your codebase with Exakat using Docker - Longhorn PHP
How to analyze your codebase with Exakat using Docker - Longhorn PHPHow to analyze your codebase with Exakat using Docker - Longhorn PHP
How to analyze your codebase with Exakat using Docker - Longhorn PHPDana Luther
 
Apigility – Lightning Fast API Development - OSSCamp 2014
Apigility – Lightning Fast API Development - OSSCamp 2014 Apigility – Lightning Fast API Development - OSSCamp 2014
Apigility – Lightning Fast API Development - OSSCamp 2014 OSSCube
 
Composer - The missing package manager for PHP
Composer - The missing package manager for PHPComposer - The missing package manager for PHP
Composer - The missing package manager for PHPTareq Hasan
 
Zend con 2016 bdd with behat for beginners
Zend con 2016   bdd with behat for beginnersZend con 2016   bdd with behat for beginners
Zend con 2016 bdd with behat for beginnersAdam Englander
 
Netflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.js
Netflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.jsNetflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.js
Netflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.jsChris Saint-Amant
 
Zend expressive workshop
Zend expressive workshopZend expressive workshop
Zend expressive workshopAdam Culp
 
Mixing Plone and Django for explosive results
Mixing Plone and Django for explosive resultsMixing Plone and Django for explosive results
Mixing Plone and Django for explosive resultsSimone Deponti
 
PHP 4? OMG! A small vademecum for obsolete software migration.
PHP 4? OMG! A small vademecum for obsolete software migration.PHP 4? OMG! A small vademecum for obsolete software migration.
PHP 4? OMG! A small vademecum for obsolete software migration.Francesco Fullone
 
Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....
Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....
Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....Moscow.pm
 
TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기
TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기
TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기Heejong Ahn
 
Preparing an Open Source Documentation Repository for Translations
Preparing an Open Source Documentation Repository for TranslationsPreparing an Open Source Documentation Repository for Translations
Preparing an Open Source Documentation Repository for TranslationsHPCC Systems
 
Measuring Code Quality in WTF/min.
Measuring Code Quality in WTF/min. Measuring Code Quality in WTF/min.
Measuring Code Quality in WTF/min. David Gómez García
 

Mais procurados (16)

Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016
 
TAKING PHP SERIOUSLY - Keith Adams
TAKING PHP SERIOUSLY - Keith AdamsTAKING PHP SERIOUSLY - Keith Adams
TAKING PHP SERIOUSLY - Keith Adams
 
Theory and practice – migrating your legacy code into our modern test drive...
Theory and practice – migrating your  legacy code into our modern test  drive...Theory and practice – migrating your  legacy code into our modern test  drive...
Theory and practice – migrating your legacy code into our modern test drive...
 
How to analyze your codebase with Exakat using Docker - Longhorn PHP
How to analyze your codebase with Exakat using Docker - Longhorn PHPHow to analyze your codebase with Exakat using Docker - Longhorn PHP
How to analyze your codebase with Exakat using Docker - Longhorn PHP
 
Apigility – Lightning Fast API Development - OSSCamp 2014
Apigility – Lightning Fast API Development - OSSCamp 2014 Apigility – Lightning Fast API Development - OSSCamp 2014
Apigility – Lightning Fast API Development - OSSCamp 2014
 
Composer - The missing package manager for PHP
Composer - The missing package manager for PHPComposer - The missing package manager for PHP
Composer - The missing package manager for PHP
 
Zend con 2016 bdd with behat for beginners
Zend con 2016   bdd with behat for beginnersZend con 2016   bdd with behat for beginners
Zend con 2016 bdd with behat for beginners
 
Netflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.js
Netflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.jsNetflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.js
Netflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.js
 
Zend expressive workshop
Zend expressive workshopZend expressive workshop
Zend expressive workshop
 
Mixing Plone and Django for explosive results
Mixing Plone and Django for explosive resultsMixing Plone and Django for explosive results
Mixing Plone and Django for explosive results
 
PHP 4? OMG! A small vademecum for obsolete software migration.
PHP 4? OMG! A small vademecum for obsolete software migration.PHP 4? OMG! A small vademecum for obsolete software migration.
PHP 4? OMG! A small vademecum for obsolete software migration.
 
Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....
Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....
Разработка документации для RESTful API: как убить трёх зайцев одним. Moscow....
 
Automate Yo' Self
Automate Yo' SelfAutomate Yo' Self
Automate Yo' Self
 
TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기
TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기
TypeScript와 Flow: 
자바스크립트 개발에 정적 타이핑 도입하기
 
Preparing an Open Source Documentation Repository for Translations
Preparing an Open Source Documentation Repository for TranslationsPreparing an Open Source Documentation Repository for Translations
Preparing an Open Source Documentation Repository for Translations
 
Measuring Code Quality in WTF/min.
Measuring Code Quality in WTF/min. Measuring Code Quality in WTF/min.
Measuring Code Quality in WTF/min.
 

Destaque

PowerShell and the Future of Windows Automation
PowerShell and the Future of Windows AutomationPowerShell and the Future of Windows Automation
PowerShell and the Future of Windows AutomationConcentrated Technology
 
Managing enterprise with PowerShell remoting
Managing enterprise with PowerShell remotingManaging enterprise with PowerShell remoting
Managing enterprise with PowerShell remotingConcentrated Technology
 
Advanced Tools & Scripting with PowerShell 3.0 Jump Start - Certificate
Advanced Tools & Scripting with PowerShell 3.0 Jump Start - CertificateAdvanced Tools & Scripting with PowerShell 3.0 Jump Start - Certificate
Advanced Tools & Scripting with PowerShell 3.0 Jump Start - CertificateDon Reese
 
Automating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShellAutomating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShellConcentrated Technology
 
Introduction to powershell
Introduction to powershellIntroduction to powershell
Introduction to powershellSalaudeen Rajack
 
Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!Thomas Lee
 

Destaque (20)

Powershell training material
Powershell training materialPowershell training material
Powershell training material
 
No-script PowerShell v2
No-script PowerShell v2No-script PowerShell v2
No-script PowerShell v2
 
Implementing dr w. hyper v clustering
Implementing dr w. hyper v clusteringImplementing dr w. hyper v clustering
Implementing dr w. hyper v clustering
 
PowerShell custom properties
PowerShell custom propertiesPowerShell custom properties
PowerShell custom properties
 
Best free tools for w d a
Best free tools for w d aBest free tools for w d a
Best free tools for w d a
 
Meet Windows PowerShell
Meet Windows PowerShellMeet Windows PowerShell
Meet Windows PowerShell
 
Automating ad with powershell
Automating ad with powershellAutomating ad with powershell
Automating ad with powershell
 
PowerShell crashcourse for sharepoint
PowerShell crashcourse for sharepointPowerShell crashcourse for sharepoint
PowerShell crashcourse for sharepoint
 
PowerShell and the Future of Windows Automation
PowerShell and the Future of Windows AutomationPowerShell and the Future of Windows Automation
PowerShell and the Future of Windows Automation
 
Managing enterprise with PowerShell remoting
Managing enterprise with PowerShell remotingManaging enterprise with PowerShell remoting
Managing enterprise with PowerShell remoting
 
Advanced Tools & Scripting with PowerShell 3.0 Jump Start - Certificate
Advanced Tools & Scripting with PowerShell 3.0 Jump Start - CertificateAdvanced Tools & Scripting with PowerShell 3.0 Jump Start - Certificate
Advanced Tools & Scripting with PowerShell 3.0 Jump Start - Certificate
 
PS scripting and modularization
PS scripting and modularizationPS scripting and modularization
PS scripting and modularization
 
PowerShell and WMI
PowerShell and WMIPowerShell and WMI
PowerShell and WMI
 
Best free tools for win database admin
Best free tools for win database adminBest free tools for win database admin
Best free tools for win database admin
 
Server Core2
Server Core2Server Core2
Server Core2
 
Automating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShellAutomating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShell
 
Introduction to powershell
Introduction to powershellIntroduction to powershell
Introduction to powershell
 
Managing SQLserver
Managing SQLserverManaging SQLserver
Managing SQLserver
 
Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!
 
From VB Script to PowerShell
From VB Script to PowerShellFrom VB Script to PowerShell
From VB Script to PowerShell
 

Semelhante a Practical PowerShell Programming for Professional People - DerbyCon 4

Возможности интерпретатора Python в NX-OS
Возможности интерпретатора Python в NX-OSВозможности интерпретатора Python в NX-OS
Возможности интерпретатора Python в NX-OSCisco Russia
 
Introducing Language-Oriented Business Applications - Markus Voelter
Introducing Language-Oriented Business Applications - Markus VoelterIntroducing Language-Oriented Business Applications - Markus Voelter
Introducing Language-Oriented Business Applications - Markus VoelterJAXLondon2014
 
Visual Studio .NET2010
Visual Studio .NET2010Visual Studio .NET2010
Visual Studio .NET2010Satish Verma
 
Let's contribute, HTML5Rocks/ko!
Let's contribute, HTML5Rocks/ko!Let's contribute, HTML5Rocks/ko!
Let's contribute, HTML5Rocks/ko!Chang W. Doh
 
Docopt, beautiful command-line options for R, user2014
Docopt, beautiful command-line options for R,  user2014Docopt, beautiful command-line options for R,  user2014
Docopt, beautiful command-line options for R, user2014Edwin de Jonge
 
Introduction to PHP - SDPHP
Introduction to PHP - SDPHPIntroduction to PHP - SDPHP
Introduction to PHP - SDPHPEric Johnson
 
Code in the cloud with eclipse che and docker / snowcamp.io 2017
Code in the cloud with eclipse che and docker /  snowcamp.io 2017Code in the cloud with eclipse che and docker /  snowcamp.io 2017
Code in the cloud with eclipse che and docker / snowcamp.io 2017Florent BENOIT
 
Scientist meets web dev: how Python became the language of data
Scientist meets web dev: how Python became the language of dataScientist meets web dev: how Python became the language of data
Scientist meets web dev: how Python became the language of dataGael Varoquaux
 
Introduction to PHP (SDPHP)
Introduction to PHP   (SDPHP)Introduction to PHP   (SDPHP)
Introduction to PHP (SDPHP)Eric Johnson
 
Python tools for testing web services over HTTP
Python tools for testing web services over HTTPPython tools for testing web services over HTTP
Python tools for testing web services over HTTPMykhailo Kolesnyk
 
Orange scrum – project management tool journey, with the evolution of php
Orange scrum – project management tool journey, with the evolution of phpOrange scrum – project management tool journey, with the evolution of php
Orange scrum – project management tool journey, with the evolution of phpAndolasoft Inc
 
Unleash your Symfony projects with eZ Platform
Unleash your Symfony projects with eZ PlatformUnleash your Symfony projects with eZ Platform
Unleash your Symfony projects with eZ PlatformSébastien Morel
 
Rapid Prototyping Chatter with a PHP/Hack Canvas App on Heroku
Rapid Prototyping Chatter with a PHP/Hack Canvas App on HerokuRapid Prototyping Chatter with a PHP/Hack Canvas App on Heroku
Rapid Prototyping Chatter with a PHP/Hack Canvas App on HerokuSalesforce Developers
 
Entrepreneur’s guide to programming
Entrepreneur’s guide to programmingEntrepreneur’s guide to programming
Entrepreneur’s guide to programmingChris Callahan
 
Top 100 PHP Questions and Answers
Top 100 PHP Questions and AnswersTop 100 PHP Questions and Answers
Top 100 PHP Questions and Answersiimjobs and hirist
 
Will iPython replace Bash?
Will iPython replace Bash?Will iPython replace Bash?
Will iPython replace Bash?Babel
 
Will iPython replace bash?
Will iPython replace bash?Will iPython replace bash?
Will iPython replace bash?Roberto Polli
 

Semelhante a Practical PowerShell Programming for Professional People - DerbyCon 4 (20)

Возможности интерпретатора Python в NX-OS
Возможности интерпретатора Python в NX-OSВозможности интерпретатора Python в NX-OS
Возможности интерпретатора Python в NX-OS
 
Introducing Language-Oriented Business Applications - Markus Voelter
Introducing Language-Oriented Business Applications - Markus VoelterIntroducing Language-Oriented Business Applications - Markus Voelter
Introducing Language-Oriented Business Applications - Markus Voelter
 
Pyhton-1a-Basics.pdf
Pyhton-1a-Basics.pdfPyhton-1a-Basics.pdf
Pyhton-1a-Basics.pdf
 
Govind.ppt.pptx
Govind.ppt.pptxGovind.ppt.pptx
Govind.ppt.pptx
 
Visual Studio .NET2010
Visual Studio .NET2010Visual Studio .NET2010
Visual Studio .NET2010
 
Let's contribute, HTML5Rocks/ko!
Let's contribute, HTML5Rocks/ko!Let's contribute, HTML5Rocks/ko!
Let's contribute, HTML5Rocks/ko!
 
Docopt, beautiful command-line options for R, user2014
Docopt, beautiful command-line options for R,  user2014Docopt, beautiful command-line options for R,  user2014
Docopt, beautiful command-line options for R, user2014
 
Introduction to PHP - SDPHP
Introduction to PHP - SDPHPIntroduction to PHP - SDPHP
Introduction to PHP - SDPHP
 
Code in the cloud with eclipse che and docker / snowcamp.io 2017
Code in the cloud with eclipse che and docker /  snowcamp.io 2017Code in the cloud with eclipse che and docker /  snowcamp.io 2017
Code in the cloud with eclipse che and docker / snowcamp.io 2017
 
Scientist meets web dev: how Python became the language of data
Scientist meets web dev: how Python became the language of dataScientist meets web dev: how Python became the language of data
Scientist meets web dev: how Python became the language of data
 
Introduction to PHP (SDPHP)
Introduction to PHP   (SDPHP)Introduction to PHP   (SDPHP)
Introduction to PHP (SDPHP)
 
Python tools for testing web services over HTTP
Python tools for testing web services over HTTPPython tools for testing web services over HTTP
Python tools for testing web services over HTTP
 
Orange scrum – project management tool journey, with the evolution of php
Orange scrum – project management tool journey, with the evolution of phpOrange scrum – project management tool journey, with the evolution of php
Orange scrum – project management tool journey, with the evolution of php
 
Unleash your Symfony projects with eZ Platform
Unleash your Symfony projects with eZ PlatformUnleash your Symfony projects with eZ Platform
Unleash your Symfony projects with eZ Platform
 
Python overview
Python overviewPython overview
Python overview
 
Rapid Prototyping Chatter with a PHP/Hack Canvas App on Heroku
Rapid Prototyping Chatter with a PHP/Hack Canvas App on HerokuRapid Prototyping Chatter with a PHP/Hack Canvas App on Heroku
Rapid Prototyping Chatter with a PHP/Hack Canvas App on Heroku
 
Entrepreneur’s guide to programming
Entrepreneur’s guide to programmingEntrepreneur’s guide to programming
Entrepreneur’s guide to programming
 
Top 100 PHP Questions and Answers
Top 100 PHP Questions and AnswersTop 100 PHP Questions and Answers
Top 100 PHP Questions and Answers
 
Will iPython replace Bash?
Will iPython replace Bash?Will iPython replace Bash?
Will iPython replace Bash?
 
Will iPython replace bash?
Will iPython replace bash?Will iPython replace bash?
Will iPython replace bash?
 

Último

Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Alkin Tezuysal
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...AliaaTarek5
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...Scott Andery
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfNeo4j
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesThousandEyes
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesKari Kakkonen
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rick Flair
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Farhan Tariq
 

Último (20)

Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
Enhancing User Experience - Exploring the Latest Features of Tallyman Axis Lo...
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdf
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examples
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...
 

Practical PowerShell Programming for Professional People - DerbyCon 4

  • 1. Practical PowerShell Programming for Professional People Ben Ten (@Ben0xA) Slides: http://www.slideshare.net/BenTen0xA DerbyCon 2014
  • 2. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) About Me Ben Ten (0xA) @Ben0xA - twitter Chicago - #burbsec Vice President Security Officer Developer PoshSec Framework Developer / Creator Gamer Geek
  • 3. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 4. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 5. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 6. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 7. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 8. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 9. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 10. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 11. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 12. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 13. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 14. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 15. SecurityFail Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 16. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Overview ●Languages and Development ●PowerShell Scripting ●Resources ●Q&A ●PSA: This is mostly live code scripting in PowerShell. Please code along with me!
  • 17. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Overview Feel free to interrupt and ask questions!
  • 18. Languages and Development Before we begin, a bit of a primer! Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) ●Styles of Coding ●Syntax ●Getting Help ●Starting Out
  • 19. Languages and Development Styles of Coding/Scripting/Development Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) ●Novice ●Avid Scripter ●Full Time Developer ●Code Monkey
  • 20. Languages and Development Styles of Coding/Scripting/Development Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) ●Novice ●Avid Scripter ●Full Time Developer ●Code Monkey
  • 21. Languages and Development Syntax syn•tax (sĭnˈtăksˌ) – the rules that govern how a script, or program, is developed in a given language. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 22. Languages and Development Syntax White Space, parens (), commas, periods, quotes (“ vs '), tabs, braces [], curly brackets {}, colons :, semi-colons ;, all play an integral part in the syntax of a language! Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 23. Languages and Development Getting Help! RTF Manual/Docs/Reference Often times, the documentation will have an answer for what you are trying to accomplish. *NOT ALWAYS THOUGH* Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 24. Languages and Development Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Getting Help! Interactive Help ● ? ●F1 ●Intellisense (Ctrl+Space) ●Get-Help
  • 25. Languages and Development Getting Help! Search Engines FTW! Google is not the end all in searches. For Development I prefer DuckDuckGo! https://duckduckgo.com Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 26. Languages and Development Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 27. Languages and Development @JimmyVo – DuckDuckVo! Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 28. PowerShell Overview PowerShell is a task automation and configuration management framework from Microsoft, consisting of a command-line shell and associated scripting language built on the .NET Framework. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 29. PowerShell Overview PowerShell was designed by : ● Jeffrey Snover (@jsnover) ●Bruce Payette (@BrucePayette) ● James Truher Initial release was November 14, 2006 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 30. PowerShell Overview PowerShell is a part of the Windows Management Framework. WMF 5.0 was released on April 3, 2014. For today's scripting we will be using WMF 3.0. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 31. PowerShell Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) You will need: ●Windows Management Framework 3.0 ●Microsoft .NET Framework 4.5 ●Text Editor (your choice) ●Sublime Text http://www.sublimetext.com/ ●Komodo Edit http://komodoide.com/komodo-edit/ ●PowerShell ISE (comes with WMF)
  • 32. PowerShell File Name Extensions .ps1 – Script Files .psm1 – Script Module Files .psd1 – Script Manifest Files .ps1xml – Formatting and Type Files .dll - Cmdlet and Provider Assemblies Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 33. PowerShell File Name Extensions .ps1 – Script Files .psm1 – Script Module Files .psd1 – Script Manifest Files .ps1xml – Formatting and Type Files .dll - Cmdlet and Provider Assemblies Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 34. PowerShell Cmdlets, Functions, and Scripts Oh My! From a functional standpoint, cmdlets, functions, and scripts are practically the same. They are a way to call a specific block of code. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 35. PowerShell Cmdlet: Written in a compiled .NET language. Easier to deploy. Help files are easier to write. Has support for parameter validation. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 36. PowerShell Function: Written in a PowerShell language. Has to be deployed with a library. Help is written inside the function. Parameter validation has to be done in the function itself. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 37. PowerShell Script: Written in a PowerShell language. Is invoked by calling the .ps1 file. Deployed by itself or in a manifest file. Can contain functions. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 38. PowerShell Set-ExecutionPolicy Before you can run your custom scripts you have to set the ExecutionPolicy to RemoteSigned. In PowerShell type: Set-ExecutionPolicy RemoteSigned Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 39. PowerShell Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 40. PowerShell HelloWorld.ps1 Enough of the primer! Let's get coding! This is where you code along with me if you can! Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 41. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 42. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 43. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 44. HelloWorld.ps1 Variable(s): a symbolic name associated with a value and whose associated value may be changed. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 45. HelloWorld.ps1 Hard-Coded: Typing the value directly into your script. Our “Hello World” text was hard-coded. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 46. HelloWorld.ps1 PowerShell Variables: A PowerShell variable is defined with the dollar sign $ followed by the name of the variable. For example: $message is a variable. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 47. HelloWorld.ps1 PowerShell Variables: Let's rewrite our HelloWorld.ps1 to use a variable $message with our text “Hello World”. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 48. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 49. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 50. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 51. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 52. HelloWorld.ps1 Quotes! Single vs Double Double Quotes (“) will attempt to resolve any variables before anything is printed to the screen. Single Quotes (') will print exactly what is typed between the quotes. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 53. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 54. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 55. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 56. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 57. HelloWorld.ps1 Backtick ` The backtick, or grave accent, is a special escape character. This means that you want the next character to be printed and not interpreted in anyway. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 58. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 59. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 60. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 61. HelloWorld.ps1 Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 62. Getting Input Write-Output is great. But how do you get information from a user? Read-Host Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 63. Getting Input Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 64. Getting Input Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 65. Conditional Logic A Condition is: a feature of a programming language which perform a different set of computations or actions depending on whether a programmer-specified boolean condition evaluates to true or false. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 66. Conditional Logic A Condition is: Is the stop light is green? Keep going. Is the stop light is red? Stop. Is the stop light is yellow? Floor it!!!! Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 67. Conditional Logic A Condition expressed: ● If - Beginning of the condition. ●Else - Evaluates only if preceding condition(s) is(are) false. ●ElseIf – Evaluates if preceding condition(s) is(are) false with a new condition. ●Switch – Multiple conditions for a single variable or object. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 68. Conditional Logic A Conditional Operator: -and = both conditions must be true. -or = only one of the conditions must be true. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 69. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) A Conditional Operator: -eq = Equals -lt = Less Than -gt = Greater Than -ne = Not Equal -ge = Great Than or Equal -le = Less Than or Equal
  • 70. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) A Conditional Operator: -Like -NotLike -Match -NotMatch -Contains -NotContains -In -NotIn -Replace
  • 71. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 72. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 73. Conditional Logic Operator Precedence: When operators have equal precedence, Windows PowerShell evaluates them from left to right. The exceptions are the assignment operators, the cast operators, and the negation operators (!, -not, -bnot), which are evaluated from right to left. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 74. Conditional Logic Operator Precedence: You can use enclosures, such as parentheses, to override the standard precedence order and force Windows PowerShell to evaluate the enclosed part of an expression before an unenclosed part. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 75. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 76. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 77. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 78. Conditional Logic Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 79. Parameters A Parameter is: A variable that allows you to pass an object to a Cmdlet, Function, or Script. Get-ChildItem Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 80. Parameters Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 81. Parameters Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Get-Help Get-ChildItem Get-ChildItem [[-Path] <String[]>] [[-Filter] <String>] [-Exclude <String[]> [-Name] [-Recurse] [-UseTransaction [<SwitchParameter>]] [<CommonParameters> Get-ChildItem [[-Filter] <String>] [-Exclude <String[]>] [-Force] [-Include -LiteralPath <String[]> [-UseTransaction [<SwitchParameter>]] [<CommonParame Get-ChildItem [-Attributes <FileAttributes]>] [-Directory] [-File] [-Force] [-UseTransaction] [<CommonParameters>]
  • 82. Parameters Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 83. Parameters Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 84. Objects vs Text PowerShell is Object Based. Even if you see text on the screen, that text is actually a “String” object. You can access the members of the object using the . operator after the variable name. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 85. Objects vs Text Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 86. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Piping Piping is: a way of moving something, unchanged, from one place to another.
  • 87. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Piping Piping is represented by the | (pipe) character. A pipe takes the object from the left side and passes it to the right side. Note: When passing to another cmdlet, $_ is used to reference the passed object.
  • 88. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Piping
  • 89. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Piping
  • 90. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Loops Loops: A way to perform the same block of code for a specific number of times, until a specific condition is met, or while a specific condition exists.
  • 91. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Loops Loops: ●ForEach ●ForEach-Object ●For ●While ●Do While ●Do Until
  • 92. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Loops
  • 93. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Loops
  • 94. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Loops
  • 95. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Comments Comments are defined by the # symbol. Block comments are enclosed with <# and #>. .SYNOPSIS .DESCRIPTION .PARAMETER .EXAMPLE
  • 96. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Comments
  • 97. Putting it all Together The final program! Requirements: ●Search all files. ●Find the ones that were modified in a specific date range. ●Create a list of those files and display them. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 98. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Pitfalls Don't overuse the Pipe! Not everything has to be done in a single line. It's more important that you understand the code before you try to condense it to a single line.
  • 99. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Pitfalls With Loops, start small then open the valve all the way! You can get more than you wanted, or get stuck in an endless loop. Especially true when doing File operations!
  • 100. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Resources Freenode (irc.freenode.net) #PowerShell, #pssec, #poshsec channels. Learn Windows PowerShell in a Month of Lunches ~ Don Jones Carlos Perez – PowerShell Workshop at DerbyCon.
  • 101. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Resources PoshSec – https://github.com/PoshSec PoshSec Framework PowerSploit – https://github.com/mattifestation/ Posh-SecMod – https://github.com/DarkOperator/
  • 102. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Resources http://www.slideshare.net/BenTen0xA/ practical-powershell-programming-for-professional- people
  • 103. Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) Thanks! @securitymoey @jaysonstreet @DerbyCon @tonikjdk @darkoperator @mattifestation @obscuresec @harmj0y
  • 104. Contact - Q&A Ben Ten (0xA) @Ben0xA - twitter http://ben0xa.com https://poshsec.org web@ben0xa.com Ben0xA – LinkedIn, Github, keybase, etc. irc.freenode.net #burbsec, #poshsec, #pssec http://www.slideshare.net/BenTen0xA Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA) QUESTIONS?!
  • 105. Thank You! Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)
  • 106. Thank You! Practical Powe rShell Programming for Professional People DerbyCon - Ben Ten (@Ben0xA)