dsccommunity / dsccommunity/SqlServerDsc

SqlLogin: Resource refactoring proposal

Open
#2,173 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted resource proposal
Dominant language
PowerShell
Stars
385
Forks
224
PR merge metrics
No merged PRs in 30d

Description

Resource proposal

A class-based SqlLogin resource would ensure SQL Server logins exist, are enabled or disabled, and have correct properties. Commands would include Get-SqlDscLogin, New-SqlDscLogin, Remove-SqlDscLogin, Enable-SqlDscLogin, Disable-SqlDscLogin, and Test-SqlDscIsLoginEnabled.

Proposed properties
Property Type qualifier Data type Description Default value Allowed values
Ensure Key String Whether the login should be Present or Absent Present Present, Absent
Name Key String Login name None Any valid login name
LoginType Write String Type of login (SQL, Windows, etc.) None SQLLogin, WindowsUser, etc.
DefaultDatabase Write String Default database for login None Any valid database name
Enabled Write Boolean Whether the login is enabled True True, False
Password Write SecureString Password for SQL logins None Valid password
Special considerations or limitations

Must support both SQL and Windows logins, handle enable/disable scenarios, and ensure idempotency. Contributors should ensure sensitive data is handled securely and account for permissions required to manage logins.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files, tests, or entry points are named. Start by locating existing class-based resources and their tests, then compare their patterns with the proposed SqlLogin commands and properties; done means SQL and Windows logins are managed idempotently, including presence, removal, enablement, passwords, and secure handling.

Written by the indexing model from the issue text.

Assessment

Tech stack
powershell, sql
Domain
databases
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.