Browse Source

use SHA512 to sign files

Darien Raymond 8 năm trước cách đây
mục cha
commit
3e395e93ac
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      tools/build/go.go

+ 1 - 1
tools/build/go.go

@@ -35,7 +35,7 @@ func buildV2Ray(targetFile string, version string, goOS GoOS, goArch GoArch) err
 
 func signFile(file string) error {
 	pass := os.Getenv("GPG_SIGN_PASS")
-	cmd := exec.Command("gpg", "--no-tty", "--batch", "--passphrase", pass, "--output", file+".sig", "--detach-sig", file)
+	cmd := exec.Command("gpg", "--digest-algo", "SHA512", "--no-tty", "--batch", "--passphrase", pass, "--output", file+".sig", "--detach-sig", file)
 	cmd.Env = append(cmd.Env, os.Environ()...)
 	output, err := cmd.CombinedOutput()
 	if len(output) > 0 {