Category Archives: ISA

Powershell to insert at start of line and end of line

When I was creating the post Facebook Domain Name Sets for ISA I needed to insert data at the start and end of a line.  I used powershell to do this, and this is what I came up with:
Get-Content DNSList.txt | ForEach-Object {“%PREPEND%”+$_+”%APPEND%”}
DNSList.txt contains a list of text;
%PREPEND% is the data to add at the start of the line;
%APPEND% is the data to add to the end of the line.
In the Facebook ISA example, the actual code was (one line):
Get-Content | list.txt | ForEach-Obect {“<fpc4:Str dt:dt=`”string`”>*.”+$_”</fpc4:Str> “}
Notice the backticks infront of the “string” component.  This is to escape the quote marks to allow them to be included.
The output can be pasted into the relevant XML file and imported into ISA.

Facebook Domain Name Sets for ISA

Blocking / Allowing Facebook using Microsoft ISA can be difficult.  I have created a Domain Name Set for ISA that you can import.  They can be found:
ISA 2004 SP3:  here (zip file)
ISA 2006 SP1:  here (zip file)
Plain Text:  here (zip file)
It is very possible there are some non Facebook related websites in this list, so please verify these are suitable for use in your environment.  These domains can change over time, so if you find any that aren’t in the list, please let me know.