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

security/acme-client: SFTP upload fails due to invalid action type #2671

Closed
3ster opened this issue Nov 29, 2021 · 1 comment
Closed

security/acme-client: SFTP upload fails due to invalid action type #2671

3ster opened this issue Nov 29, 2021 · 1 comment
Assignees
Labels
bug Production bug

Comments

@3ster
Copy link

3ster commented Nov 29, 2021

Important notices
Before you add a new report, we ask you kindly to acknowledge the following:

[x] I have read the contributing guide lines at https://github.com/opnsense/plugins/blob/master/CONTRIBUTING.md

[x] I have searched the existing issues and I'm convinced that mine is new.

[x] The title contains the plugin to which this issue belongs

Describe the bug
Uploading a certificate via SFTP automation to a remote server does not work due to the action type being "configd_upload_sftp" instead of "upload_sftp."

To Reproduce
Steps to reproduce the behavior:

  1. Create a new automation via Services->ACME Client->Automations with the Run Command set to "Upload certificate via SFTP" and a valid configuration
  2. Execute the automation
  3. Log entry "/usr/local/opnsense/scripts/OPNsense/AcmeClient/upload_sftp.php: Ignoring disabled or invalid automation [uuid]" is created.

Expected behavior
Certificate is uploaded to the remote machine.

Screenshots
n/a

Relevant log files
See above.

Additional context
Changing line 411 in /usr/local/opnsense/scripts/OPNsense/AcmeClient/upload_sftp.php from

if ($action->enabled && "upload_sftp" === (string)$action->type) {

to

if ($action->enabled && "configd_upload_sftp" === (string)$action->type) {

results in the automation working as expected.

Environment

OPNsense 21.7.6-amd64
os-acme-client 3.5

@fraenki fraenki self-assigned this Nov 29, 2021
@fraenki fraenki added the bug Production bug label Nov 29, 2021
fraenki added a commit to fraenki/plugins that referenced this issue Nov 29, 2021
@fraenki
Copy link
Member

fraenki commented Nov 29, 2021

Thanks for the report! This will be fixed in os-acme-client 3.6

For those in need for a hotfix:

opnsense-patch -c plugins 57ada90e890832b67ad93f54bed2ee26bde4b669

@fraenki fraenki closed this as completed Nov 29, 2021
@opnsense opnsense locked as resolved and limited conversation to collaborators Dec 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Production bug
Development

No branches or pull requests

2 participants