Skip to content

Commit a88b449

Browse files
authored
Merge pull request #56 from AsBuiltReport/dev
v1.4.2 release
2 parents 37d88f7 + 26755cf commit a88b449

File tree

4 files changed

+24
-7
lines changed

4 files changed

+24
-7
lines changed

AsBuiltReport.Core.psd1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
# Version number of this module.
1515

16-
ModuleVersion = '1.4.1'
16+
ModuleVersion = '1.4.2'
1717

1818
# Supported PSEditions
1919
# CompatiblePSEditions = 'Desktop'
@@ -28,7 +28,7 @@
2828
# CompanyName = ''
2929

3030
# Copyright statement for this module
31-
Copyright = '(c) 2024 Tim Carman. All rights reserved.'
31+
Copyright = '(c) 2025 Tim Carman. All rights reserved.'
3232

3333
# Description of the functionality provided by this module
3434
Description = 'A PowerShell module which provides the core framework for generating As-Built documentation for many common datacentre systems.'

CHANGELOG.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,16 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [1.4.2] - 2025-01-30
9+
10+
### Fixed
11+
- Fix password shown in plain text (Fix [#55](https://github.com/AsBuiltReport/AsBuiltReport.Core/issues/55))
12+
- Prevent execution from Windows PowerShell ISE (Fix [#52](https://github.com/AsBuiltReport/AsBuiltReport.Core/issues/52))
13+
814
## [1.4.1] - 2024-12-02
915

1016
### Changed
11-
* Update GitHub release workflow to add post to Bluesky social platform
17+
- Update GitHub release workflow to add post to Bluesky social platform
1218

1319
### Fixed
1420
- Set `$OutputFolderPath` variable as Global variable (Fix [#53](https://github.com/AsBuiltReport/AsBuiltReport.Core/issues/53))

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ Get-Help New-AsBuiltReportConfig -Full
213213
Here are some examples to get you going.
214214

215215
```powershell
216-
# Generate a VMware vSphere As Built report in HTML & Word formats. Perform a health check to highlight particular issues which exist within the Vmware vSphere environment. Save the report to the 'H:\Documents\' folder.
216+
# Generate a VMware vSphere As Built report in HTML & Word formats. Perform a health check to highlight particular issues which exist within the VMware vSphere environment. Save the report to the 'H:\Documents\' folder.
217217
New-AsBuiltReport -Report 'VMware.vSphere' -Target '192.168.1.100' -Username 'admin' -Password 'admin' -Format HTML,Word -EnableHealthCheck -OutputFolderPath 'H:\Documents\'
218218
219219
# Generate a Nutanix Prism Element As Built Report using specified username and password credentials. Specify the report configuration file to be used. Export report to Text, HTML & DOCX formats. Use the default report style. Save the report to the '/Users/Tim/Documents' folder. Display verbose messages to the console.

Src/Public/New-AsBuiltReport.ps1

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ function New-AsBuiltReport {
140140

141141
[Parameter(
142142
Position = 3,
143-
Mandatory = $true,
143+
Mandatory = $false,
144144
HelpMessage = 'Please provide the password to connect to the target system',
145145
ParameterSetName = 'UsernameAndPassword'
146146
)]
@@ -244,9 +244,20 @@ function New-AsBuiltReport {
244244

245245
try {
246246

247+
if ($psISE) {
248+
Write-Error -Message "AsBuiltReport cannot be run from Windows PowerShell ISE. Please use a PowerShell command window instead."
249+
break
250+
}
251+
247252
# If Username and Password parameters used, convert specified Password to secure string and store in $Credential
248-
if (($Username -and $Password)) {
249-
$SecurePassword = ConvertTo-SecureString $Password -AsPlainText -Force
253+
if ($Username) {
254+
if (-not $Password) {
255+
# If the Password parameter is not provided, prompt for it securely
256+
$SecurePassword = Read-Host "Password for user $Username" -AsSecureString
257+
} else {
258+
# If the Password parameter is provided, convert it to secure string
259+
$SecurePassword = ConvertTo-SecureString $Password -AsPlainText -Force
260+
}
250261
$Credential = New-Object System.Management.Automation.PSCredential ($Username, $SecurePassword)
251262
}
252263

0 commit comments

Comments
 (0)