Thursday, August 22, 2013

tangled in PowerShell scripts

Recently bogged some Windows Power shell codes.
It does following batch jobs according to the file list on AWS S3 storage. To make the list, I've modified a sample code of AWS S3 Java SDK.
  1. invoke Java code (slightly modified AWS S3 Java SDK sample, too) which downloads netsh-made network trace log file which zipped in .cab or .gz format from AWS S3
  2. unzip .cab or zipped trace file,
  3. invoke Microsoft Network Monitor 3.4 with command line options to extract KerberosV5 specific packets and save to another network trace file
  4. invoke Network Monitor again to extract more detail KerberosV5 error packets, and saved its counts to 'YYYYMMDD-HH-krb-err-ERRTYPE.txt' file. This process is iterated for each ERRTYPE.
Most of difficulties come from PowerShell specific features to handle command pipeline and asynchronous unzip process execution. Later on, I may have time to describe details of them.

bye for now.

No comments:

Post a Comment