I have written a program in Go to create PDFs and zip files with LaTeX and operating system board tools (it has to work on Linux and Windows). A few days ago, Windows Defender classified my exe as a Trojan. Because I share the file with friends: How can I make sure that my program is not flagged as a virus?
The PDFs and zip file are created in an export folder. The following steps are carried out:
- The export folder is emptied.
- An image is tested for a specific size.
- .tex files are copied temporarily.
- LaTex/Docker is started and generates various PDFs using .tex files.
- A zip file is created.
- Temporarily copies are removed
- Some files created by LaTeX are deleted
- Text in the console is displayed in green or red.
I compiled the programm with:
GOOS=windows GOARCH=amd64 go build -o start_myprogramm.exe -ldflags="-s -w" src/,y-programm.go;
My import looks like this:
import (
"archive/zip"
"bufio"
"fmt"
"image"
_ "image/jpeg"
"io"
"log"
"os"
"os/exec"
"path/filepath"
"regexp"
"strings"
"sync"
"time"
"github.com/fatih/color"
)
I have read similar cases. Among other things, it said that you can sign the file. Could this be the solution to the problem?