Skip to content

Commit

Permalink
2.2.0.0 branch for release (#157)
Browse files Browse the repository at this point in the history
* Added IISSite composite resource

* Update documentation

* Added IISSite composite resource

* Update documentation

* Updates from pr comments

* Updates from PR Review

* Update xWebAdministration to 2.1.0.0

* Update to resolve test errors

* Reverting xWebAdministration back to 2.2.0.0

* Updates from pr review

* Update to get-resourcetitle

* Updates for IIS Server DSC

* Updates to resolve PR comments

* Fix for failing test

* Updates for IIS Server DSC

* Fix for failing test

* Updates to resolve PR comments

* Update to fix test

* Updated for instance parameter

* Added IISSite composite resource

* Update documentation

* Updates from pr comments

* Updates from PR Review

* Update xWebAdministration to 2.1.0.0

* Update to resolve test errors

* Reverting xWebAdministration back to 2.2.0.0

* Updates from pr review

* Update to get-resourcetitle

* Updates to resolve PR comments

* Update for PR comments

* Updates for OracleJRE composite resource fixes #153 (#154)

* Updates for OracleJRE composite resource

* Update formatting

* Adds FireFox Composite Issue#119 (#155)

* End of day check in

* mid day check in

* firefox composite is working, needs tests

* updates for failing tests

* update for tests.

* update for tests

* Update to pas tests

* update for parameter update

* Update for small things

* update to changelog

* Update to add Unit Test

* updates for PR

* update for PR

* update for bug fix and add integration test

* update for test

* Update to fix issue

* update

* update for fix

* update for minor fixes

* updates for PR comments
  • Loading branch information
chasewilson authored and athaynes committed Oct 9, 2018
1 parent 6ef32e7 commit c86ec1c
Show file tree
Hide file tree
Showing 27 changed files with 648 additions and 17 deletions.
13 changes: 12 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,22 @@

* Added the following DSC Composite Resources
* Microsoft Office 2013 STIGs
* FireFox STIG
* IIS Site STIG
* IIS Server STIG
* Oracle JRE STIG
* Windows10 STIG

* Added required module "PolicyFileEditor" for applying Office HKey_Current_User settings
* Newly required modules
* PolicyFileEditor
* FileContentDsc
* WindowsDefenderDSC
* xWebAdministration
* xWinEventLog

* Updated required module versions
* xDnsServer from 1.9.0.0 to 1.11.0.0
* SecurityPolicyDsc from 2.2.0.0 to 2.4.0.0

## 2.1.0.0

Expand Down
2 changes: 1 addition & 1 deletion DSCResources/Browser/Browser.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ModuleVersion = '1.0.0.0'
GUID = '2c710cae-34b9-4557-b19b-7e1da84485ab'

# Author of this module
Author = 'Wade Baker'
Author = 'Microsoft Corporation'

# Company or vendor of this module
CompanyName = 'Microsoft Corporation'
Expand Down
2 changes: 1 addition & 1 deletion DSCResources/DotNetFramework/DotNetFramework.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
GUID = '4b1b6e2b-afa0-4396-876e-f7d3ad1efca3'

# Author of this module
Author = 'LaNika Dillon'
Author = 'Microsoft Corporation'

# Company or vendor of this module
CompanyName = 'Microsoft Corporation'
Expand Down
46 changes: 46 additions & 0 deletions DSCResources/FireFox/FireFox.psd1
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.

@{
# Script module or binary module file associated with this manifest.
RootModule = 'FireFox.schema.psm1'

# Version number of this module.
ModuleVersion = '1.0.0.0'

# ID used to uniquely identify this module
GUID = '4b1b6e2b-afa0-4396-876e-f7d3ad1efca3'

# Author of this module
Author = 'Microsoft Corporation'

# Company or vendor of this module
CompanyName = 'Microsoft Corporation'

# Copyright statement for this module
Copyright = '(c) 2018 Microsoft. All rights reserved.'

# Description of the functionality provided by this module
Description = 'Module for managing the FireFox DISA STIGs'

# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
FunctionsToExport = @('FireFox')

# Cmdlets to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no cmdlets to export.
CmdletsToExport = @()

# Variables to export from this module
VariablesToExport = '*'

# Aliases to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no aliases to export.
AliasesToExport = @()

# Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.
PrivateData = @{

PSData = @{

} # End of PSData hashtable

} # End of PrivateData
}
96 changes: 96 additions & 0 deletions DSCResources/FireFox/FireFox.schema.psm1
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.

using module ..\helper.psm1
using module ..\..\PowerStig.psm1

<#
.SYNOPSIS
A composite DSC resource to manage the Firefox STIG settings
.PARAMETER StigVersion
The version of the STIG to apply and monitor
.PARAMETER Exception
A hash table of key value pairs that are injected into the STIG data and applied to
the target node. The title of STIG setting is tagged with the text ‘Exception’ to identify
the exceptions to policy across the data center when you centralize DSC log collection.
.PARAMETER OrgSettings
The path to the XML file that contains the local organizations preferred settings for STIG
items that have allowable ranges.
.PARAMETER SkipRule
The SkipRule Node is injected into the STIG data and applied to the target node. The title
of STIG settings are tagged with the text 'Skip' to identify the skips to policy across the
data center when you centralize DSC log collection.
.PARAMETER SkipRuleType
All STIG rule IDs of the specified type are collected in an array and passed to the Skip-Rule
function. Each rule follows the same process as the SkipRule parameter.
#>
Configuration FireFox
{
[CmdletBinding()]
param
(
[Parameter()]
[string]
$InstallDirectory = "$env:ProgramFiles\Mozilla Firefox",

[Parameter()]
[ValidateSet('4.21')]
[ValidateNotNullOrEmpty()]
[version]
$StigVersion,

[Parameter()]
[ValidateNotNullOrEmpty()]
[psobject]
$Exception,

[Parameter()]
[psobject]
$OrgSettings,

[Parameter()]
[psobject]
$SkipRule,

[Parameter()]
[psobject]
$SkipRuleType
)

##### BEGIN DO NOT MODIFY #####
<#
The exception, skipped rule, and organizational settings functionality
is universal across all composites, so the code to process it is in a
central file that is dot sourced into each composite.
#>
$dscResourcesPath = Split-Path -Path $PSScriptRoot -Parent
$userSettingsPath = Join-Path -Path $dscResourcesPath -ChildPath 'stigdata.usersettings.ps1'
. $userSettingsPath
##### END DO NOT MODIFY #####

$technology = [Technology]::Mozilla
$technologyVersion = [TechnologyVersion]::New( 'All', $technology )
$technologyRole = [TechnologyRole]::New( 'FireFox', $technologyVersion )
$stigDataObject = [StigData]::New( $StigVersion, $OrgSettings, $technology,
$technologyRole, $technologyVersion, $Exception,
$SkipRuleType, $SkipRule )
#### BEGIN DO NOT MODIFY ####
# $StigData is used in the resources that are dot sourced below
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseDeclaredVarsMoreThanAssignments",'')]
$stigData = $stigDataObject.StigXml

# $resourcePath is exported from the helper module in the header

# This is required to process Skipped rules
Import-DscResource -ModuleName PSDesiredStateConfiguration -ModuleVersion 1.1
. "$resourcePath\windows.Script.skip.ps1"
##### END DO NOT MODIFY #####

Import-DscResource -ModuleName FileContentDsc -ModuleVersion 1.1.0.108
. "$resourcePath\firefox.ReplaceText.ps1"
}
4 changes: 2 additions & 2 deletions DSCResources/IisServer/IisServer.schema.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ Configuration IisServer
[ValidateNotNullOrEmpty()]
[psobject]
$Exception,

[Parameter()]
[ValidateNotNullOrEmpty()]
[psobject]
Expand Down Expand Up @@ -123,7 +123,7 @@ Configuration IisServer

Import-DscResource -ModuleName xPSDesiredStateConfiguration -ModuleVersion 8.3.0.0
. "$resourcePath\windows.xRegistry.ps1"

Import-DscResource -ModuleName xWebAdministration -ModuleVersion 2.2.0.0
. "$resourcePath\windows.xIisMimeTypeMapping.ps1"
. "$resourcePath\windows.WebConfigProperty.ps1"
Expand Down
2 changes: 1 addition & 1 deletion DSCResources/Office/Office.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
GUID = '345c2922-2447-46ad-bd5a-0c169bd31203'

# Author of this module
Author = 'Jeff Salas'
Author = 'Microsoft Corporation'

# Company or vendor of this module
CompanyName = 'Microsoft Corporation'
Expand Down
48 changes: 48 additions & 0 deletions DSCResources/OracleJRE/OracleJRE.psd1
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.

@{

# Script module or binary module file associated with this manifest.
RootModule = 'OracleJRE.schema.psm1'

# Version number of this module.
ModuleVersion = '1.0.0.0'

# ID used to uniquely identify this module
GUID = '16db8a8b-7ca9-4558-be63-1c88ef394d92'

# Author of this module
Author = 'Microsoft Corporation'

# Company or vendor of this module
CompanyName = 'Microsoft Corporation'

# Copyright statement for this module
Copyright = '(c) 2018 Microsoft. All rights reserved.'

# Description of the functionality provided by this module
Description = 'Module for managing the OracleJRE 8 DISA STIGs'

# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
FunctionsToExport = @('OracleJRE')

# Cmdlets to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no cmdlets to export.
CmdletsToExport = @()

# Variables to export from this module
VariablesToExport = '*'

# Aliases to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no aliases to export.
AliasesToExport = @()

# Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.
PrivateData = @{

PSData = @{

} # End of PSData hashtable

} # End of PrivateData

}
109 changes: 109 additions & 0 deletions DSCResources/OracleJRE/OracleJRE.schema.psm1
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.

using module ..\helper.psm1
using module ..\..\PowerStig.psm1

<#
.SYNOPSIS
A composite DSC resource to manage the OracleJRE 8 STIG settings
.PARAMETER ConfigPath
The path to OracleJRE 8 config file
.PARAMETER PropertiesPath
The path to OracleJRE 8 properties file
.PARAMETER StigVersion
The version of OracleJRE 8 STIG to apply and/or monitor
.PARAMETER Exception
A hashtable of StigId=Value key pairs that are injected into the STIG data and applied to
the target node. The title of STIG settings are tagged with the text ‘Exception’ to identify
the exceptions to policy across the data center when you centralize DSC log collection.
.PARAMETER OrgSettings
The path to the xml file that contains the local organizations preferred settings for STIG
items that have allowable ranges.
.PARAMETER SkipRule
The SkipRule Node is injected into the STIG data and applied to the taget node. The title
of STIG settings are tagged with the text 'Skip' to identify the skips to policy across the
data center when you centralize DSC log collection.
.PARAMETER SkipRuleType
All STIG rule IDs of the specified type are collected in an array and passed to the Skip-Rule
function. Each rule follows the same process as the SkipRule parameter.
#>
Configuration OracleJRE
{
[CmdletBinding()]
param
(
[Parameter(Mandatory = $true)]
[string]
$ConfigPath,

[Parameter(Mandatory = $true)]
[string]
$PropertiesPath,

[Parameter()]
[ValidateSet('1.5')]
[ValidateNotNullOrEmpty()]
[version]
$StigVersion,

[Parameter()]
[ValidateNotNullOrEmpty()]
[psobject]
$Exception,

[Parameter()]
[ValidateNotNullOrEmpty()]
[psobject]
$OrgSettings,

[Parameter()]
[ValidateNotNullOrEmpty()]
[psobject]
$SkipRule,

[Parameter()]
[ValidateNotNullOrEmpty()]
[psobject]
$SkipRuleType
)

##### BEGIN DO NOT MODIFY #####
<#
The exception, skipped rule, and organizational settings functionality
is universal across all composites, so the code to process it is in a
central file that is dot sourced into each composite.
#>
$dscResourcesPath = Split-Path -Path $PSScriptRoot -Parent
$userSettingsPath = Join-Path -Path $dscResourcesPath -ChildPath 'stigdata.usersettings.ps1'
. $userSettingsPath
##### END DO NOT MODIFY #####

$technology = [Technology]::Windows
$technologyVersion = [TechnologyVersion]::New( "All", $technology )
$technologyRole = [TechnologyRole]::New( "OracleJRE8", $technologyVersion )
$stigDataObject = [StigData]::New( $StigVersion, $orgSettingsObject, $technology,
$technologyRole, $technologyVersion, $Exception,
$SkipRuleType, $SkipRule )
#### BEGIN DO NOT MODIFY ####
# $StigData is used in the resources that are dot sourced below
[Diagnostics.CodeAnalysis.SuppressMessageAttribute("PSUseDeclaredVarsMoreThanAssignments",'')]
$StigData = $StigDataObject.StigXml

# $resourcePath is exported from the helper module in the header

# This is required to process Skipped rules
Import-DscResource -ModuleName PSDesiredStateConfiguration -ModuleVersion 1.1
. "$resourcePath\windows.Script.skip.ps1"
##### END DO NOT MODIFY #####

Import-DscResource -ModuleName FileContentDsc -ModuleVersion 1.1.0.108
. "$resourcePath\oraclejre.KeyValuePairFile.ps1"
}
Loading

0 comments on commit c86ec1c

Please sign in to comment.