Python Forum
My .exe made using Python being detected as a virus
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
My .exe made using Python being detected as a virus
#1
I am currently trying to make simple code that misspells a word and copies it to your clipboard but when I share it to another computer it is detected by antivirus as a trojan. Is there anything I can do to prevent this from happening?
Here is my code:

import random
import pyperclip

filler = []
valid = False


def charGen(x):
    if x == 6:
        return "b"
    elif x == 5:
        return "a"
    elif x == 4:
        return "n"
    elif x == 3:
        return "a"
    elif x == 2:
        return "n"
    elif x == 1:
        return "a"


while not valid:
    word = "b"
    filler = []

    length = random.randint(3, 7)

    word = word + charGen((random.choice([4, 5])))

    for a in range(length):
        filler.append(charGen(random.randint(1, 6)))
        word += filler[a]

    word = word + "a"

    if word.find('n') >= 0:
        print(word)
        valid = True

    for b in range(len(word)-1):
        if word[b] == word [b+1]:
            valid = False
pyperclip.copy(word)
(tbh, the reason the charGen function has so many repeating words is because it was originally intended for another word)
Reply


Messages In This Thread
My .exe made using Python being detected as a virus - by 100grassfed - Jun-15-2021, 03:19 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  python not detected on computer adriennn 3 1,307 Nov-18-2023, 02:46 PM
Last Post: snippsat
  python --version yields no output, not detected by other programs ten 3 3,579 Jun-25-2020, 04:48 AM
Last Post: perfringo
  Executable looks like virus to windows samuelbachorik 4 3,140 Apr-27-2020, 02:46 PM
Last Post: samuelbachorik
  How can I make this Python script add a limit to trades made with API? streetlaw 0 2,077 Oct-12-2018, 11:41 AM
Last Post: streetlaw
  Python files made on linux don't work on windows sylas 2 3,353 Oct-10-2018, 05:34 AM
Last Post: sylas
  Simple Python Virus microwavedelf 4 10,619 Sep-14-2018, 09:50 PM
Last Post: EhsojSide
  Go to line starting with and variable not detected morgandebray 5 3,535 Aug-09-2018, 09:00 AM
Last Post: morgandebray
  "Widget Javascript not detected" error BobLoblaw 0 4,373 Oct-07-2017, 04:48 PM
Last Post: BobLoblaw
  Object Detection that records the number of secs the face is not detected trabis03 1 2,595 Jul-21-2017, 04:14 PM
Last Post: nilamo

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020