Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: Creating a bundle always fails as Windows Defender kicks in

  1. #1
    thinBasic MVPs
    Join Date
    Sep 2006
    Posts
    3,294
    Blog Entries
    2
    Rep Power
    346

    Creating a bundle always fails as Windows Defender kicks in

    Hi folks,

    is it possible to create a bundle where Windows Defender is not kicking in? I tried not to use UPX but the same error happened.

    Michael

  2. #2
    thinBasic MVPs
    Join Date
    Oct 2012
    Location
    Germany
    Age
    52
    Posts
    1,484
    Blog Entries
    2
    Rep Power
    165
    Actually bundle always fails when i try.


    Mal deutsch ( i dont know the english captions)

    gehe bei den neuen windows-einstellungen und tipp ins suchfeld "Windows-Sicherheit" minus/bindestrich sonst wird es nich gefunden

    Gehe zu "Viren- uund Bedohungsschutz" wennn du Schalter für "Echtzeitschutz" und "cloudbasierter Schutz" siehst bist Du auf der richtigen seite. <die rechte hälfte gannz bis unten scrollen
    Da steht Ausschlüsse. und untendrunter ein link
    Ausschlusse hinzufügen oder entfernen.
    Klick da
    Dann musst du noch mal bestätigen das du tust was du willst,(als admin mindestens) dann gibts einen Button "+ Ausschluss hinzufügen"
    klick da und wähle ordner: suche thinbasic installationsordner und setzt den in die liste. Dann mach das gleiche mit einem ordner in dem du deine scripts speeicherst. - also wo deine datenquellen für bundle stehen mindestens.
    dann klick nochmal und wähle statt ordner dateityp und setze ".tbasic*" ein - das sollte alles abdecken. mit oder ohne punkt, beides geht ".inc" oder sonstige files die du verwendest vorsichtshalber - kanns ja später wieder löschen.


    '' # tb_Admin_always.tBasic" -save using this name for example 
    
    
    
    
    string lc(),  sFile = replace$(app_inifile,"Ini","Reg")
    parse app_path, lc,"\"
    save_file(sFile ,UTF8ToWideChar$( strformat$("{1} Registry Editor {2} 5.00{3}{3}[HKEY_{4}_USER\Software\Microsoft\{1} NT\{4}{2}" & _
       "\AppCompatFlags\Layers]{3}{5}{6}{7}{6}{8}{6}{7}_Bundle_UI{9}{3}{5}{6}{7}{6}{8}{6}{8}{9}{3}{5}{6}{7}{6}{7}{9}{3}", 
       "Windows","Version", $CRLF,"CURRENT", $DQ & lc(1), "\\",lc(2),"thinAir",".exe""=""~ RUNASADMIN" &  $DQ)) )
     
     
    Select case msgbox "Written a reg-import-file to " & app_scriptpath & crlf & _
        "Do you want to merge it into your registry now? (Admin privileges required)" & crlf & _
        "You can however import it by right-click in explorer and choose to merge,"   & crlf & _
        "reg import " & $DQ & sFile & $DQ                                             & crlf & _
        "from an elevated command prompt or or in a batch file."                      & crlf & _ 
        "Or directly through filemenu, import within regedit, however the filename"   & crlf & _ 
        "is stored to the clipboard now.", %MB_YesNoCancel |  %MB_IconQuestion,
       "Do you have administrative rights?"
         
        case %IDYes
           lc(1)= shell_captureoutput (sFile,"", %SW_Hide, 300) 
            if  lenf(lc(1)) > 5 then 
                msgbox lc(1), %MB_IconInformation, "reply of os"
            elseif  leftf$(lc(1),2) = "-1" then 
                 msgbox "Returned value -1 (True)" , %MB_IconInformation, "reply of os"
             else 
                 msgbox "no returned value implies it was not merged ", %MB_IconExclamation, "no reply of os"
             endif 
        case %IDNO
            ' delete the file to prevent from accidental merging it 
            shell( "Explorer.exe -o ", App_Scriptpath  )      
            
      end select
      
      
      clipboard_settext(sFile)
      shell("regedt32","")
              
      ' - - -
    
    execute as Admin to run thinbasic thinair & bundle as Admin always.
    or just execute. open the folder of the script and right-click the written .reg-File , choose Merge (as admin) to import into the registry.


  3. #3
    thinBasic MVPs
    Join Date
    Sep 2006
    Posts
    3,294
    Blog Entries
    2
    Rep Power
    346
    And that only help myself. As soon as you want to distribute your script, you would run into trouble.
    Its the O2 part of thinBasic that is most likely responsible for the false flags of virus checkers.

  4. #4
    thinBasic MVPs
    Join Date
    Oct 2012
    Location
    Germany
    Age
    52
    Posts
    1,484
    Blog Entries
    2
    Rep Power
    165
    but i did not use O2 - oxygen- not i the script above nor when bundling. Even as System (default in WinPE) which has higher rank and more rights than admins- it says "bundle not ok". Not even when i log is as trustedInstaller - the most powerful rank- it will not bundlee. Not when i use 1,2,3 or none different modules. i dont hink its the av alone since the path is excluded for defender. I have no system path nor subfolderof asystem path in use. And it will not bundle. I have it in win 10 and win 11 , on to hd installed windows or in from virtual booted windows . i have the issue in 3 different thinBasicinstallations where none shares a path with the current os.Also intentionally use of such path does not change a thing.
    = does not make it worse than not functioning


  5. #5
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    55
    Posts
    8,665
    Blog Entries
    2
    Rep Power
    10
    Do not know if it can help but I did many changes in latest Beta I'm working on and not yet published.
    Link is: https://www.thinbasic.biz/projects/t...c_1.11.7.0.zip

    I'm using at work in dozen of bundled script without problems.
    I've tested under Trend Micro, Cynet, MS Defender ... all enterprise editions and no problems so far.
    Petr is using under its own company AV and didn't reported problems so far.

    This version has many new features still to be finished and documented but should not create problems.
    Let me know if it helps

    Thanks
    Eros
    www.thinbasic.com | www.thinbasic.com/community/ | psch.thinbasic.com
    Win10Pro 64bit - 8GB Ram - Intel i7 M620 2.67GHz - NVIDIA Quadro FX1800M 1GB

  6. #6
    thinBasic MVPs
    Join Date
    Sep 2006
    Posts
    3,294
    Blog Entries
    2
    Rep Power
    346
    Thanks Eros, I will give this a try on the weekend and report back. Would be awesome if bundles wouldn't be a problem to distribute anymore. I could get our IT provider to get a bundle to install but if the virus checker kicks in, that would be a nogo.

  7. #7
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,104
    Blog Entries
    5
    Rep Power
    729
    Hi Mike,

    we will try to submit the thinBundle to all vendors with each new build.

    Regarding your distribution of your apps created with bundle:

    We cannot offer an systematic solution for generated EXEs, because if we buy certificate and sign bundled exe/thinBasic.exe with trusted certificates, it will become trusted even if it executes "evil" script by 3rd party.

    The affordable solution for you as an indie developer could be:
    - you can generate certificate for free, and you can ask your users to trust your certificate (how described under "Generate a certificate using Makecert" here: https://stackoverflow.com/questions/...ndows-exe-file)
    - use that certificate to sign your tools/games

    (this does not guarantee anything yet, but it will remove "unknown publisher" alert on Windows and prepares you for the next step)

    - additionally, I would still recommend to submit the signed EXE to major AV vendors for check and whitelisting - you can "automate" the check by submitting file via https://www.virustotal.com/gui/home/upload and the contacting only those vendors, which triggered false positive.

    Each company behind Antivirus software uses a bit different approach, so there is sadly no magic to guarantee no issues under all AV vendors.


    Petr
    Last edited by Petr Schreiber; 12-02-2022 at 19:19.
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

  8. #8

    I'm having trouble making Bundles

    I tried to make a Bundle and it fails on the last step!! I have McAfee AV, but it does not report anything blocked!

  9. #9
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    55
    Posts
    8,665
    Blog Entries
    2
    Rep Power
    10
    Ciao Gary,

    last step thinBundle waits for 3 seconds in order to give AV software enough time to scan final executable and release it or not.
    I think in your case your AV intercepts something it doesn't like or has not enough time to finish the job.

    As a first try ... try to disable UPX compression and see if it makes any difference.
    If it works ... your final .EXE will be a bigger but we can work on this and find a solution in next thinBasic release.

    Let me know.
    Eros
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	Capture.jpg 
Views:	6 
Size:	69.9 KB 
ID:	10287  
    www.thinbasic.com | www.thinbasic.com/community/ | psch.thinbasic.com
    Win10Pro 64bit - 8GB Ram - Intel i7 M620 2.67GHz - NVIDIA Quadro FX1800M 1GB

  10. #10

    Bundle fails

    I tried turning off the compression, but it still fails. I too would be willing to bet it has something to do with the Anti-Virus! If I can figure out how to turn off the AV I will do that, otherwise, it is not a big deal!

Page 1 of 2 12 LastLast

Similar Threads

  1. Bundle .exe needs UAC? Any way to prevent this?
    By EmbeddedMan in forum thinBundle
    Replies: 18
    Last Post: 16-12-2016, 18:52
  2. TB 1.19.15.0 Bundle problem
    By EmbeddedMan in forum thinBasic General
    Replies: 8
    Last Post: 15-09-2015, 23:35
  3. Bundle updates
    By RobertoBianchi in forum thinBundle
    Replies: 4
    Last Post: 06-11-2008, 20:31
  4. Using BUNDLE in 1.4.0.1 under WINDOWS-98SE
    By GSAC3 in forum thinBundle bugs report
    Replies: 4
    Last Post: 08-10-2007, 15:16

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •