Parse Text Data

Identify Similar String Patterns you own this product

This project is part of the liveProject series Parse Text Data with PowerShell
prerequisites
intermediate PowerShell (use variables, common PowerShell built-in cmdlets, conditional and loop statements)
skills learned
read text files • use complex regex patterns including lookaround, regex quantifiers, and ranges • use the switch statement and its regex parameter to extract substrings from text files • arrays and array indexing using expressions • edit text using replace operations • write to text files
Fernando Corrales
1 week · 4-6 hours per week · INTERMEDIATE

pro $24.99 per month

  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose one free eBook per month to keep
  • exclusive 50% discount on all purchases

lite $19.99 per month

  • access to all Manning books, including MEAPs!

team

5, 10 or 20 seats+ for your team - learn more


Look inside

XYZ Services Company, the consulting and outsourcing firm you work for, recently experienced a massive failure in its IT Infrastructure. While it’s working on getting the environment back up and running, the company urgently needs to identify potential vulnerabilities in the digital signatures used by the employees for two-factor authentication. Applying PowerShell scripting best practices, you’ll write a script that uses the switch statement and its regex parameter to extract a list of digital signatures from an input file, identify matching strings that satisfy specific conditions, classify them as required, and send them to log files. When you’re done, the information security officer will thank you for helping prevent future security issues.

This project is designed for learning purposes and is not a complete, production-ready application or solution.

book resources

When you start your liveProject, you get full access to the following books for 90 days.

project author

Fernando Corrales
Fernando Corrales is a cloud engineer with several years of IT experience in multinational companies. He’s worked extensively with VMware products, focusing on private cloud automation with PowerCLI and PowerShell, in addition to delivering PowerShell training for some of his recent employers. Fernando holds several technical degrees from the Tecnológico de Costa Rica and has a personal blog: fercorrales.com.

prerequisites

This liveProject is for technology administrators and intermediate-level PowerShell users who want to learn or expand their text and string parsing skills. To begin these liveProjects you’ll need to be familiar with the following:

TOOLS
  • Intermediate PowerShell 7
  • Visual Studio Code with PowerShell extension

you will learn

In this liveProject, you’ll learn how to use the switch statement and its regex parameter and how to write regular expression patterns to find strings that satisfy specified conditions.

  • Extract a list of values using the Select-String cmdlet to further analyze each match using a switch construct
  • Use the Select-String cmdlet to find regex matches and write the matching values to a file
  • Work with advanced regular expressions, including negative lookbehind, negative lookahead, quantifiers, alternation and ranges
  • Use the replace operator to modify text strings
  • Use the cnotmatch operator to find strings that don't match specified regex patterns
  • Get property values using the dot method
  • Work with arrays and array indexes
  • Use the Get-Date cmdlet to generate strings in date and/or time format
  • Read and write text to a file using PowerShell
  • Display objects on the screen

features

Self-paced
You choose the schedule and decide how much time to invest as you build your project.
Project roadmap
Each project is divided into several achievable steps.
Get Help
While within the liveProject platform, get help from other participants and our expert mentors.
Compare with others
For each step, compare your deliverable to the solutions by the author and other participants.
book resources
Get full access to select books for 90 days. Permanent access to excerpts from Manning products are also included, as well as references to other resources.

choose your plan

team

monthly
annual
$49.99
$499.99
only $41.67 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • Identify Similar String Patterns project for free