Skip to content

fix: yaml secret file parsing #3837

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

Merged
merged 2 commits into from
Jul 10, 2025

Conversation

sidwebworks
Copy link
Member

Description 📣

Fix YAML content type handling in secrets import - #3832

image

Type ✨

  • Bug fix
  • New feature
  • Improvement
  • Breaking change
  • Documentation

Tests 🛠️


@maidul98
Copy link
Collaborator

maidul98 commented Jun 21, 2025

🎉 Snyk checks have passed. No issues have been found so far.

security/snyk check is complete. No issues have been found. (View Details)

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Summary

Added robust YAML parsing support for secret file imports with proper handling of multiline strings and content types.

  • New content-type detection in frontend/src/pages/secret-manager/SecretDashboardPage/components/SecretDropzone/SecretDropzone.tsx now properly identifies YAML files with content types 'text/yaml', 'application/x-yaml', and 'application/yaml'
  • Added dedicated parseYaml function in frontend/src/components/utilities/parseSecrets.ts that correctly processes multiline string formats using YAML block scalar styles (|, |-, >)
  • Security: Ensure input validation and sanitization are robust when parsing user-provided YAML files to prevent potential injection attacks or malformed data
  • Documentation: No docs update in /docs folder for this new YAML import feature - customers need to know supported YAML formats and limitations

2 files reviewed, 2 comments
Edit PR Review Bot Settings | Greptile

Copy link
Contributor

@scott-ray-wilson scott-ray-wilson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sidwebworks sidwebworks merged commit ba0f6e6 into Infisical:main Jul 10, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants