domingo, 28 de enero de 2024

C++ Std::Condition_Variable Null Pointer Derreference


This story is about a bug generated by g++ and clang compilers (at least)
The condition_variables is a feature on the standard library of c++ (libstdc++), when its compiled statically a weird asm code is generated.


Any example on the link below will crash if its compiled statically:
 https://en.cppreference.com/w/cpp/thread/condition_variable



In this case the condition_variable.wait() crashed, but this happens with other methods, a simple way to trigger it:




If this program is compiled dynamically the crash doesn't occur:

Looking the dissasembly there is a surprise created by the compiler:


Compilers:
    g++  9.2.1+20200130-2
    clang++ v9

Both compilers are generating the "call 0x00"

If we check this call in a dynamic compiled:




The implementation of condition_variable in github:
https://github.com/gcc-mirror/gcc/blob/b7c9bd36eaacac42631b882dc67a6f0db94de21c/libstdc%2B%2B-v3/include/std/condition_variable


The compilers can't copile well this code in static,  and same happens on  other condition_variable methods.
I would say the _lock is being assembled improperly in static, is not exacly a null pointer derreference but the effects are the same, executing code at address 0x00 which on linux is a crash on most of cases.

Related news
  1. Growth Hacker Tools
  2. Physical Pentest Tools
  3. Pentest Tools Website
  4. Pentest Tools Open Source
  5. Hacker Tools Software
  6. Github Hacking Tools
  7. Hacking Tools For Windows
  8. Pentest Box Tools Download
  9. New Hacker Tools
  10. Pentest Tools Android
  11. Pentest Tools Kali Linux
  12. Hacking App
  13. Hackrf Tools
  14. Pentest Tools Framework
  15. Pentest Tools Open Source
  16. Pentest Tools Android
  17. Pentest Tools
  18. Pentest Tools Review
  19. Hacker Tools Software
  20. Hack Tool Apk No Root
  21. Pentest Tools Url Fuzzer
  22. Hacking Tools Windows 10
  23. Physical Pentest Tools
  24. Pentest Tools For Windows
  25. Nsa Hack Tools Download
  26. Blackhat Hacker Tools
  27. Hacker Tools Windows
  28. Hacker Tools Linux
  29. Hack Tools
  30. Hacker Techniques Tools And Incident Handling
  31. Free Pentest Tools For Windows
  32. Bluetooth Hacking Tools Kali
  33. Hacking Tools Hardware
  34. Growth Hacker Tools
  35. Pentest Tools Nmap
  36. Hack Tools For Ubuntu
  37. How To Install Pentest Tools In Ubuntu
  38. Pentest Tools Nmap
  39. How To Hack
  40. Pentest Tools For Mac
  41. Hacking Tools Software
  42. Tools 4 Hack
  43. Hack App
  44. Hacking Tools For Windows Free Download
  45. Hacks And Tools
  46. Hackrf Tools
  47. Nsa Hack Tools
  48. Hack Tools Download
  49. Hacker Search Tools
  50. Hacking Tools Online
  51. Bluetooth Hacking Tools Kali
  52. Pentest Tools Nmap
  53. Free Pentest Tools For Windows
  54. Hacking Tools And Software
  55. Best Pentesting Tools 2018
  56. Tools 4 Hack
  57. Hacker Tools Apk
  58. Pentest Tools Framework
  59. Pentest Tools Website
  60. Hackrf Tools
  61. Pentest Tools Framework
  62. Hacker Tools
  63. Hacker Tools 2020
  64. Pentest Tools Kali Linux
  65. Hacker Tools 2020
  66. Pentest Tools Url Fuzzer
  67. Github Hacking Tools
  68. Pentest Tools For Mac
  69. Physical Pentest Tools
  70. Hacker Techniques Tools And Incident Handling
  71. Physical Pentest Tools
  72. Top Pentest Tools
  73. Hacker Tools Hardware
  74. Hacker Tools Software
  75. Hacker Tools Apk
  76. Hack Tools For Ubuntu
  77. Best Hacking Tools 2019
  78. Hacking Tools
  79. What Is Hacking Tools
  80. Pentest Tools Windows
  81. Pentest Tools Free
  82. Nsa Hack Tools
  83. Hacker Tools For Mac
  84. Pentest Recon Tools
  85. Termux Hacking Tools 2019
  86. Free Pentest Tools For Windows
  87. Pentest Tools Find Subdomains
  88. Hack Tools For Pc
  89. Tools 4 Hack
  90. Hack Website Online Tool
  91. Hacker Tools 2019
  92. Android Hack Tools Github
  93. Pentest Tools Github
  94. Hacking Tools For Pc
  95. Pentest Tools Apk
  96. Pentest Tools Free
  97. Hack Tools
  98. Hacker Tools For Mac
  99. Pentest Tools
  100. Hacker Tools For Ios
  101. Usb Pentest Tools
  102. Hacker Techniques Tools And Incident Handling
  103. Pentest Tools Windows
  104. Blackhat Hacker Tools
  105. Pentest Tools Review
  106. Hack Apps
  107. Nsa Hack Tools
  108. Hacker Tools Windows
  109. Pentest Tools Kali Linux
  110. Hack Rom Tools
  111. Pentest Tools For Ubuntu
  112. Android Hack Tools Github
  113. Underground Hacker Sites
  114. Pentest Tools Free
  115. Black Hat Hacker Tools
  116. Hacker Tools For Mac
  117. Pentest Tools Bluekeep
  118. Hack Tools
  119. Blackhat Hacker Tools
  120. What Is Hacking Tools
  121. Hack Tool Apk
  122. Hacks And Tools
  123. Hacker Tools For Pc
  124. Free Pentest Tools For Windows
  125. Black Hat Hacker Tools
  126. Hacker
  127. Hacking Tools For Mac
  128. What Is Hacking Tools
  129. Pentest Tools Port Scanner
  130. Hacker Tools Mac
  131. Hack Tool Apk
  132. Hacking Tools Hardware
  133. Nsa Hacker Tools
  134. How To Install Pentest Tools In Ubuntu
  135. Hacking Tools Kit
  136. Hacking Tools For Windows 7
  137. Pentest Tools Review
  138. Hacking Tools Windows
  139. Hacking Tools For Pc
  140. What Are Hacking Tools
  141. Pentest Tools Framework
  142. Hacking Tools 2019
  143. Beginner Hacker Tools
  144. Hak5 Tools
  145. Hacking Tools Name
  146. Pentest Tools For Ubuntu
  147. Hacking Tools Github
  148. Pentest Reporting Tools
  149. Hacking Tools Windows 10
  150. Pentest Tools Review
  151. Pentest Automation Tools
  152. How To Make Hacking Tools
  153. Physical Pentest Tools
  154. Hack Tools Github
  155. Wifi Hacker Tools For Windows

No hay comentarios:

Publicar un comentario