Enhance ServiceNow integration with improved logging, validation, and documentation#215
Draft
jagger wants to merge 4 commits into
Draft
Enhance ServiceNow integration with improved logging, validation, and documentation#215jagger wants to merge 4 commits into
jagger wants to merge 4 commits into
Conversation
… documentation ## Discovery Script Improvements (ServiceNow Account Discovery.ps1) ### Logging Enhancements - Moved log path definitions to top of script with configurable $logFolder variable - Added helper functions: Get-TruncatedSecret, Get-SanitizedHeaders, Write-ApiCallLog - Added debug logging for all input parameters with truncated secrets (5 chars + ***) - Added API call logging for all REST method calls with sanitized Authorization headers - Changed results output from text append to JSON format with Out-File -Force ### Input Validation - Added validation for DiscoveryMode (must be "Advanced" or "Default") - Added validation for baseURL (must start with "https://") - Added placeholder detection to catch unsubstituted Secret Server variables - Validation logs errors before throwing exceptions for easier troubleshooting ### Code Quality - Renamed functions to use PowerShell approved verbs: - isadmin -> Test-IsAdminUser - isSvcAcct -> Test-IsServiceAccount - isLocal -> Test-IsLocalUser - get-SvcAccounts -> Get-ServiceAccounts - Fixed hardcoded URL bug in Get-LocalUsers function (now uses $api variable) ## XML Template Fixes ### ServiceNow Privileged Account Template.xml - Fixed "ClientUD" typo to "ClientID" - Fixed "Local-Account-Groud-Ids" typo to "Local-Account-Group-Ids" - Added description for Local-Account-Group-Ids field - Set Password and Client-Secret fields as password type (masked in UI) ### ServiceNow User Template.xml - Fixed "assocated" typo to "associated" ## Documentation Updates ### Main readme.md - Added Native Support Notice about Secret Server's built-in ServiceNow support - Added link to official Delinea documentation - Noted this repo offers alternate implementation with discovery features ### Instructions.md - Added missing # header marker - Fixed missing bullet points in Prerequisites section - Fixed "training slash" -> "trailing slash" typo - Fixed "ministrative" -> "administrative" typo ### Discovery/readme.md - Added Log Files documentation section - Added Input Validation documentation - Added Discovery Mode Options table - Fixed multiple typos and formatting issues ### Remote Password Changer/readme.md - Fixed double slash in link path - Fixed double colon in Category field - Fixed triple asterisks in bold formatting - Fixed "fill outhe" -> "fill out the" typo - Fixed "pasge" -> "page" typo - Fixed missing bold closing tag ### Templates/readme.md (New) - Created new readme documenting available templates - Added native support notice - Added field descriptions for both templates - Added import instructions 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
jagger
force-pushed
the
feature/servicenow-improvements
branch
from
January 8, 2026 18:13
e06112b to
0dfe8c3
Compare
ServiceNow Heartbeat.ps1: - Fixed "Argumnts" -> "Arguments" in comment - Fixed "Vaeiables" -> "Variables" in region name - Fixed invalid env var path "$env:Program Files" -> "$env:ProgramFiles" - Fixed missing closing brace in Write-Log function - Fixed parameter name mismatch "$privassword" -> "$privPassword" - Renamed function "get-pwd-verification" -> "Test-PasswordVerification" - Fixed parameter/variable mismatch $PWD/$Password ServiceNow Remote Password Changer.ps1: - Fixed "Argumnts" -> "Arguments" in comment - Fixed "Vaeiables" -> "Variables" in region name - Fixed invalid env var path "$env:Program Files" -> "$env:ProgramFiles" - Fixed "#endregikon" -> "#endregion" typo - Fixed parameter name mismatch "$privassword" -> "$privPassword" - Fixed "Funtions" -> "Functions" in region name - Fixed function name "get-ServiceNowUserInfo" -> "Get-ServiceNowUserInfo" 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Added notice about Secret Server's native out-of-box ServiceNow password changing and heartbeat support with link to official docs. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…atibility Update the ServiceNow User template and discovery output to use 'host' field instead of 'Tenant-URL'/'tenant-url' for compatibility with Secret Server's native ServiceNow RPC implementation. Changes: - ServiceNow User Template.xml: Renamed displayname, name, and fieldslugname - Discovery script: Updated output field name in both Default and Advanced modes - Discovery readme: Updated scan template instructions and SQL report - RPC readme: Updated Password Type Fields and field mapping sections - Templates readme: Updated User Template field documentation 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR enhances the ServiceNow Secret Server integration with significant improvements to logging, input validation, code quality, and documentation.
Discovery Script Improvements
XML Template Fixes
Documentation Updates
Generated with Claude Code