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

Remove APPIMAGETOOL_FORCE_SIGN env var #20

Merged
merged 1 commit into from
Jul 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions src/appimagetool.c
Original file line number Diff line number Diff line change
Expand Up @@ -1034,12 +1034,7 @@ main (int argc, char *argv[])

if (sign) {
if (!sign_appimage(destination, sign_key, verbose)) {
if (getenv(FORCE_SIGN_ENV_VAR) != NULL) {
fprintf(stderr, "ERROR: signing failed, aborting\n");
exit(1);
} else {
fprintf(stderr, "ERROR: signing failed, continuing\n");
}
die("Signing failed, aborting");
}
}

Expand Down
4 changes: 2 additions & 2 deletions src/appimagetool_sign.c
Original file line number Diff line number Diff line change
Expand Up @@ -358,9 +358,9 @@ bool sign_appimage(char* appimage_filename, char* key_id, bool verbose) {
if (sscanf(engine_info->version, "%u.%u", &major, &minor) == 2) {
if (major == 2) {
if (minor == 0) {
fprintf(stderr, "[sign] warning: loopback pinentry mode not supported with gpg 2.0.x, %s may not work\n", FORCE_SIGN_ENV_VAR);
fprintf(stderr, "[sign] warning: loopback pinentry mode not supported with gpg 2.0.x, signing may fail silently\n");
} else if (minor == 1) {
fprintf(stderr, "[sign] warning: gpg 2.1.x detected, %s can only work with allow-loopback-entry set within the gpg-agent configuration\n", FORCE_SIGN_ENV_VAR);
fprintf(stderr, "[sign] warning: gpg 2.1.x detected, signing may fail silently unless allow-loopback-entry is set within the gpg-agent configuration\n");
}
} else {
fprintf(stderr, "[sign] error: unsupported engine version, aborting\n");
Expand Down
2 changes: 0 additions & 2 deletions src/appimagetool_sign.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#pragma once

static const char* const FORCE_SIGN_ENV_VAR = "APPIMAGETOOL_FORCE_SIGN";

bool sign_appimage(char* appimage_filename, char* key_id, bool verbose);

/**
Expand Down