Page 1 of 6

PureBasic 6.04 LTS is out !

Posted: Sun Dec 03, 2023 6:02 pm
by Fred
Hi there,

13-12-2023 - final version is out !

06-12-2023 - beta 2 is out, with an optional switch to enable DLL preloading protection as it's not working on XP.

Code: Select all

- Added /DLLPROTECTION flag in commandline and a switch in 'Compiler options' to enable DLL preloading protection
Here is a new bug fix version, mainly to remove possible DLL injection in Windows created executables (thanks to @Kukulkan for the sponsoring !). So all PureBasic programs by default will be protected from this, but if you load another DLL manually (with OpenLibrary()) or if you link to a third party lib (with Import/EndImport) you should check if it is still safe. It also includes quite some OS X fixes:

Bugfixes for this version:This list was created automatically. All updated bug threads from the date of the last final version have been determined.

Have fun,

The Fantaisie Software Team.

Re: PureBasic 6.04 beta 1 is out !

Posted: Sun Dec 03, 2023 6:22 pm
by ChrisR
Not even a break after 6.03 and 6.04 is already on road.
I thought the next version would be 6.10?
Thanks and thanks to Kukulkan for his sponsoring 8)

Re: PureBasic 6.04 beta 1 is out !

Posted: Sun Dec 03, 2023 6:55 pm
by GeoTrail
Awesome ๐Ÿ‘๐Ÿป
Merry Xmas Fred and everyone else โ„๏ธ

Re: PureBasic 6.04 beta 1 is out !

Posted: Sun Dec 03, 2023 7:14 pm
by jacdelad
Thanks Fred and team! Mac users should be happy too.

Re: PureBasic 6.04 beta 1 is out !

Posted: Sun Dec 03, 2023 7:21 pm
by GG
Thanks Fred and Team and sponsoring users.

Re: PureBasic 6.04 beta 1 is out !

Posted: Sun Dec 03, 2023 8:44 pm
by marcoagpinto
Heya,

Thanks to the team for a new release.

Is the IDE the faster one you were working on, Fred?

Thanks!

Re: PureBasic 6.04 beta 1 is out !

Posted: Sun Dec 03, 2023 9:10 pm
by User_Russian
Error while initializing the application (0xc0000135)
Windows XP is not supported in this version?

add
This is because of the manifest in resources!
When I removed the manifest from the resources, the application worked on Windows XP.

Re: PureBasic 6.04 beta 1 is out !

Posted: Sun Dec 03, 2023 11:01 pm
by Little John
User_Russian wrote: Sun Dec 03, 2023 9:10 pm
Error while initializing the application (0xc0000135)
Windows XP is not supported in this version?

add
This is because of the manifest in resources!
When I removed the manifest from the resources, the application worked on Windows XP.
The manifest is probably important for protection against DLL injection.
Fred wrote: Yes, XP is history since 9 years: https://learn.microsoft.com/en-us/lifec ... windows-xp . We try to keep the compatibilty for the produced executables, but we don't officially support it anymore. You need a more recent Windows to install it (or you can try copy the files from another Windows if you really want to use it on XP).
Thanks to Fred for PB 6.04!
Thanks to Kukulkan for sponsoring!

Re: PureBasic 6.04 beta 1 is out !

Posted: Mon Dec 04, 2023 12:48 am
by User_Russian
Little John wrote: Sun Dec 03, 2023 11:01 pmThe manifest is probably important for protection against DLL injection.
What if my applications donโ€™t need injection protection, but running on older operating systems is important?
This protection should be optional, not forced without the ability to disable it!

Re: PureBasic 6.04 beta 1 is out !

Posted: Mon Dec 04, 2023 7:10 am
by Little John
Please don't ignore the 2nd part of my previous post.
It's not surprising that newer programs don't run on older operating systems.
The world is evolving, and so are operating systems and PureBasic.
If you are running an OS from the museum, you can use a PB version from the PureBasic museum.

Re: PureBasic 6.04 beta 1 is out !

Posted: Mon Dec 04, 2023 10:09 am
by Fred
6.0X branch should be working on XP, so I will may be add a flag to enable the protection for now so it stays compatible. If done, this flag will be removed for 6.10 as it won't support XP anymore.

Re: PureBasic 6.04 beta 1 is out !

Posted: Mon Dec 04, 2023 11:30 am
by User_Russian
Little John wrote: Sun Dec 03, 2023 11:01 pmThe manifest is probably important for protection against DLL injection.
I just checked and this manifest does not protect against dll injection using the function CreateRemoteThread.

Code: Select all

Procedure InjectDll(PID, DllName.s)
  Protected Result=#False, hProcess
  Protected *pDLLPath, *pLL, hThr, WR, ThrID
  
  hProcess=OpenProcess_(#PROCESS_CREATE_THREAD | #PROCESS_QUERY_INFORMATION|
                        #PROCESS_VM_OPERATION | #PROCESS_VM_WRITE|
                        #PROCESS_VM_READ, #False, PID)
  
  If hProcess
    *pDLLPath=VirtualAllocEx_(hProcess, 0, StringByteLength(DllName)+4, #MEM_COMMIT, #PAGE_READWRITE)
    If *pDLLPath
      *pLL=GetProcAddress_(GetModuleHandle_("Kernel32.dll"), "LoadLibraryW")
      WriteProcessMemory_(hProcess, *pDLLPath, DllName, StringByteLength(DllName)+SizeOf(Character), @WR)
      hThr=CreateRemoteThread_(hProcess, 0, 0, *pLL, *pDLLPath, 0, @ThrID)
      If hThr
        CloseHandle_(hThr)
        Result=#True
      EndIf
    EndIf
    
    CloseHandle_(hProcess)
  EndIf
    
  ProcedureReturn Result 
EndProcedure 
Therefore, I consider this manifest useless!
It should be optional and turn off in "Compiler Options".

Re: PureBasic 6.04 beta 1 is out !

Posted: Mon Dec 04, 2023 11:44 am
by Fred
You miss completely the point here, it's not about runtime DLL injection but when the executable is loading. The new manifest protect PB from this and it's fine.

Re: PureBasic 6.04 beta 1 is out !

Posted: Mon Dec 04, 2023 12:09 pm
by User_Russian
This should be optional and the checkbox should be in "Compiler Options".

Re: PureBasic 6.04 beta 1 is out !

Posted: Mon Dec 04, 2023 1:40 pm
by Fred
It won't be optional, you don't want your program to be explicitly vulnerable.