Skip to content
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

[JENKINS-47514] Don't let shell process password characters #379

Merged
merged 3 commits into from
Nov 10, 2018

Conversation

MarkEWaite
Copy link
Contributor

Avoid the risks that come when a user provided string is passed to the echo command (Windows and Linux). Place the strings inside a file and cat or type the file instead.

Use cat (Linux) and type (Windows) of files rather than echo of strings
to send username and password to the git ssh commands to reduce the risk
and complication of shell escaping username and password text provided
by end users.
The Linux based ssh commands perform expansion of '%' in arguments to ssh,
even if the '%' character is in the name of the file or directory.
Command line git shallow clone is only workable with command line git
1.9 and newer.  Earlier versions cause strange behaviors in the plugin.
Rather than complicate things with spurious failures on older command
line git implementations (like CentOS 6 and CentOS 7).
@MarkEWaite MarkEWaite merged commit c7b5fb1 into jenkinsci:master Nov 10, 2018
@MarkEWaite MarkEWaite deleted the master-PR207-retry-2 branch November 10, 2018 19:07
@MarkEWaite MarkEWaite added this to the 3.0 milestone Dec 11, 2018
@MarkEWaite MarkEWaite added bug Incorrect or flawed behavior and removed bugfix labels Nov 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Incorrect or flawed behavior
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant