Private/Parse-FODVulnerability.ps1

# Parse vulnerability
function Parse-FODVulnerability
{
    [cmdletbinding()]
    param($InputObject)

    foreach ($Vulnerability in $InputObject)
    {
        [PSCustomObject]@{
            PSTypeName = 'FOD.VulnerabilityObject'
            id = $Vulnerability.id
            releaseId = $Vulnerability.releaseId
            fisma = $Vulnerability.fisma
            severityString = $Vulnerability.severityString
            severity = $Vulnerability.severity
            category = $Vulnerability.category
            kingdom = $Vulnerability.kingdom
            owasp2004 = $Vulnerability.owasp2004
            owasp2007 = $Vulnerability.owasp2007
            owasp2010 = $Vulnerability.owasp2010
            owasp2013 = $Vulnerability.owasp2013
            owasp2017 = $Vulnerability.owasp2017
            cwe = $Vulnerability.cwe
            package = $Vulnerability.package
            primaryLocation = $Vulnerability.primaryLocation
            vulnId = $Vulnerability.vulnId
            analysisType = $Vulnerability.analysisType
            lineNumber = $Vulnerability.lineNumber
            hasComments = $Vulnerability.hasComments
            assignedUser = $Vulnerability.assignedUser
            scantype = $Vulnerability.scantype
            subtype = $Vulnerability.subtype
            primaryLocationFull = $Vulnerability.primaryLocationFull
            hasAttachments = $Vulnerability.hasAttachments
            pci1_1 = $Vulnerability.pci1_1
            pci1_2 = $Vulnerability.pci1_2
            pci2 = $Vulnerability.pci2
            sans2009 = $Vulnerability.sans2009
            sans2010 = $Vulnerability.sans2010
            sans2011 = $Vulnerability.sans2011
            wasc24_2 = $Vulnerability.wasc24_2
            isSuppressed = $Vulnerability.isSuppressed
            scanId = $Vulnerability.scanId
            pci3 = $Vulnerability.pci3
            instanceId = $Vulnerability.instanceId
            auditPendingAuditorStatus = $Vulnerability.auditPendingAuditorStatus
            auditorStatus = $Vulnerability.auditorStatus
            checkId = $Vulnerability.checkId
            closedDate = $Vulnerability.closedDate
            closedStatus = $Vulnerability.closedStatus
            developerStatus = $Vulnerability.developerStatus
            falsePositiveChallenge = $Vulnerability.falsePositiveChallenge
            introducedDate = $Vulnerability.introducedDate
            scanStartedDate = $Vulnerability.scanStartedDate
            scanCompletedDate = $Vulnerability.scanCompletedDate
            status = $Vulnerability.status
            bugSubmitted = $Vulnerability.bugSubmitted
            bugLink = $Vulnerability.bugLink
            auditPendingSuppression = $Vulnerability.auditPendingSuppression
            source = $Vulnerability.source
            sink = $Vulnerability.sink
            timeToFixDays = $Vulnerability.timeToFixDays
            Raw = $Vulnerability
        }
    }
}