Sorcerer's IsleCode QueryParam Scanner / files

 1<cfcontent type="text/xml"/><cfoutput><?xml version="1.0" encoding="UTF-8"?>
 2<qpscanner>
 3	<cfset Data = rc.ScanResults.Data />
 4	<cfset Info = rc.ScanResults.Info />
 5	<info>
 6		<count>
 7			<alerts>#Info.Totals.AlertCount#</alerts>
 8			<riskfiles>#Info.Totals.RiskFileCount#</riskfiles>
 9			<queries>#Info.Totals.QueryCount#</queries>
10			<files>#Info.Totals.FileCount#</files>
11		</count>
12		<timetaken timeout="#Info.Timeout#">#Info.Totals.Time#</timetaken>
13	</info>
14
15	</cfoutput>
16	<cfoutput query="Data" group="FileId">
17		<file id="#XmlFormat(FileId)#">
18			<name>#XmlFormat(FileName)#</name>
19			<alertcount>#QueryAlertCount#</alertcount>
20			<queries>
21			<cfoutput>
22				<query id="#XmlFormat(QueryId)#">
23					<name>#XmlFormat(QueryName)#</name>
24					<cfif isNumeric(QueryStartLine)><startline>#QueryStartLine#</startline>
25					<endline>#QueryEndLine#</endline></cfif>
26					<cfif Len(ScopeList)><scopes>#XmlFormat(ScopeList)#</scopes></cfif>
27					<code>#XmlFormat(QueryCode)#</code>
28					<filteredcode>#XmlFormat(FilteredCode)#</filteredcode>
29					<cfif StructKeyExists(Data,'QuerySegments')>
30						<!--- Create new var otherwise struct referencing can be confused. --->
31						<cfset local.QuerySegmentsStruct = Data.QuerySegments[CurrentRow] />
32						<segments><cfif isStruct(QuerySegmentsStruct)>
33							<cfloop item="CurSeg" collection=#QuerySegmentsStruct#
34								><cfif isArray(QuerySegmentsStruct[CurSeg])
35									><cfloop index="CurSegItem" array=#QuerySegmentsStruct[CurSeg]#
36									><segment type="#CurSeg#">#XmlFormat(CurSegItem)#</segment></cfloop>
37								<cfelse
38									><segment type="#CurSeg#">#XmlFormat(QuerySegmentsStruct[CurSeg])#</segment></cfif>
39							</cfloop>
40						</cfif></segments>
41					</cfif>
42				</query>
43			</cfoutput>
44			</queries>
45		</file>
46	</cfoutput>
47	<cfoutput>
48
49</qpscanner></cfoutput>