-
Notifications
You must be signed in to change notification settings - Fork 19
OMS-1050 Fixed UserKey form #208
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Conversation
|
I was unable to reproduce the bug on netbox v4.3.7 with the latest secrets package 2.3.2. So, I'm not sure if this fix is valid |
I was able to reproduce this issue with Secrets v2.3.2. When a 1024-length key is entered in the form, it causes a break. Iβve resolved this by fixing the formβs post method |
On my End also, this bug is not reproducible @kprince28 |
Just try one thing, generate the 1024 length RSA key from somewhere and add that key in the userform manually and test the behaviour and let me know. |
@kprince28 Yes, The error is reproducible only if we are pasting Publick Key (PEM) from outside, and this issue is fixed in this PR |
This reverts commit e01773a.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes RSA key generation and forms in the netbox_secrets plugin by addressing template context issues and improving UserKey activation logic.
- Updates template context to use standardized 'object' key instead of 'userkey'
- Adds return URL handling to the UserKey form
- Refines UserKey activation condition to prevent conflicts when Secrets already exist
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| netbox_secrets/views.py | Updates template context with standardized object key and return URL |
| netbox_secrets/models/secrets.py | Improves UserKey activation logic with additional Secret existence check |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
To use Codex here, create a Codex account and connect to github. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <[email protected]> Signed-off-by: Prince Kumar <[email protected]>
Minimum allowed line rate is |
# Conflicts: # setup.py
ποΈ Jira Issue
π οΈ Type of Change
π― Targeted Branch
devπ§ͺ Testing
β Test Coverage
π Checklist
πΈ Screenshots (if applicable)
π Related PRs
π§© Additional Information