You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When trying to launch a new GDB instance in the JVM with Ghidra, the following error message is generated:
Error Message
The specified procedure could not be found.
java.lang.UnsatisfiedLinkError: The specified procedure could not be found.
at jnr.ffi.provider.jffi.NativeLibrary.loadNativeLibraries(NativeLibrary.java:87)
at jnr.ffi.provider.jffi.NativeLibrary.getNativeLibraries(NativeLibrary.java:70)
at jnr.ffi.provider.jffi.NativeLibrary.getSymbolAddress(NativeLibrary.java:49)
at jnr.ffi.provider.jffi.NativeLibrary.findSymbolAddress(NativeLibrary.java:59)
at jnr.ffi.provider.jffi.AsmLibraryLoader.generateInterfaceImpl(AsmLibraryLoader.java:158)
at jnr.ffi.provider.jffi.AsmLibraryLoader.loadLibrary(AsmLibraryLoader.java:89)
at jnr.ffi.provider.jffi.NativeLibraryLoader.loadLibrary(NativeLibraryLoader.java:44)
at jnr.ffi.LibraryLoader.load(LibraryLoader.java:325)
at jnr.ffi.LibraryLoader.load(LibraryLoader.java:304)
at agent.gdb.pty.linux.Util.<clinit>(Util.java:27)
at agent.gdb.pty.linux.LinuxPty.openpty(LinuxPty.java:44)
at agent.gdb.pty.linux.LinuxPtyFactory.openpty(LinuxPtyFactory.java:26)
at agent.gdb.manager.impl.GdbManagerImpl.start(GdbManagerImpl.java:565)
at agent.gdb.model.impl.GdbModelImpl.startGDB(GdbModelImpl.java:137)
at agent.gdb.GdbInJvmDebuggerModelFactory.build(GdbInJvmDebuggerModelFactory.java:51)
at ghidra.app.plugin.core.debug.service.model.DebuggerConnectDialog.connect(DebuggerConnectDialog.java:238)
at java.desktop/javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1967)
at java.desktop/javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2308)
at java.desktop/javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:405)
at java.desktop/javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:262)
at java.desktop/javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:279)
at java.desktop/java.awt.Component.processMouseEvent(Component.java:6635)
at java.desktop/javax.swing.JComponent.processMouseEvent(JComponent.java:3342)
at java.desktop/java.awt.Component.processEvent(Component.java:6400)
at java.desktop/java.awt.Container.processEvent(Container.java:2263)
at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5011)
at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321)
at java.desktop/java.awt.Component.dispatchEvent(Component.java:4843)
at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4918)
at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Container.java:4547)
at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Container.java:4488)
at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2307)
at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2772)
at java.desktop/java.awt.Component.dispatchEvent(Component.java:4843)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:772)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95)
at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:745)
at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:743)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:742)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:117)
at java.desktop/java.awt.WaitDispatchSupport$2.run(WaitDispatchSupport.java:190)
at java.desktop/java.awt.WaitDispatchSupport$4.run(WaitDispatchSupport.java:235)
at java.desktop/java.awt.WaitDispatchSupport$4.run(WaitDispatchSupport.java:233)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.desktop/java.awt.WaitDispatchSupport.enter(WaitDispatchSupport.java:233)
at java.desktop/java.awt.Dialog.show(Dialog.java:1070)
at java.desktop/java.awt.Component.show(Component.java:1716)
at java.desktop/java.awt.Component.setVisible(Component.java:1663)
at java.desktop/java.awt.Window.setVisible(Window.java:1031)
at java.desktop/java.awt.Dialog.setVisible(Dialog.java:1005)
at docking.DockingDialog.setVisible(DockingDialog.java:353)
at docking.DockingWindowManager.lambda$doShowDialog$6(DockingWindowManager.java:1750)
at ghidra.util.Swing.doRun(Swing.java:292)
at ghidra.util.Swing.runNow(Swing.java:208)
at ghidra.util.Swing.runNow(Swing.java:163)
at docking.DockingWindowManager.doShowDialog(DockingWindowManager.java:1754)
at docking.DockingWindowManager.showDialog(DockingWindowManager.java:1703)
at docking.AbstractDockingTool.showDialog(AbstractDockingTool.java:154)
at ghidra.app.plugin.core.debug.service.model.DebuggerModelServicePlugin.doShowConnectDialog(DebuggerModelServicePlugin.java:686)
at ghidra.app.plugin.core.debug.service.model.DebuggerModelServiceProxyPlugin.showConnectDialog(DebuggerModelServiceProxyPlugin.java:270)
at ghidra.app.services.DebuggerModelService.showConnectDialog(DebuggerModelService.java:356)
at ghidra.app.plugin.core.debug.gui.target.DebuggerTargetsProvider$ConnectAction.actionPerformed(DebuggerTargetsProvider.java:110)
at docking.menu.ToolBarItemManager.lambda$actionPerformed$0(ToolBarItemManager.java:128)
at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
---------------------------------------------------
Build Date: 2021-May-21 1607 EDT
Ghidra Version: 10.0-BETA
Java Home: C:\Program Files\AdoptOpenJDK\jdk-11.0.9.101-hotspot
JVM Version: AdoptOpenJDK 11.0.9.1
OS: Windows 10 10.0 amd64
Workstation: Gabe-R-Laptop
To Reproduce
Steps to reproduce the behavior:
Load binary file into Ghidra for Analysis
Use CodeBrowser to Analyze File
Open Analyzed file in Debugger
Add debugger target using the Create a new connection to an debugging agent button
Set debugger to 'IN-VM GNU gdb local debugger`
Set GDB launch command to arm-none-eabi-gdb.exe (assuming this on on PATH)
Press Connect
Expected behavior
Debugger is launched successfully.
Environment (please complete the following information):
OS: Windows 10 21H2
Java Version: 11.0.9.1
Ghidra Version: 10.0BETA
Ghidra Origin: ghidra-sre.org
Additional context
The stack trace mentions Linux at some points. Perhaps the Linux code instead of Windows code is being called?
@marsfan We're aware of this issue, and, if you're interested, maybe scan the Discussion under"GNU gdb local agent via GADP/TCP". The issue basically comes down to the lack of a Pty equivalent on Windows. @DrChat suggested using ConPTY - we haven't had a chance to look into that. The current viable solution is to use the SSH client rather than the "local" clients. Requires installing SSH on your box, and again details in that Discussion (a ways down).
Describe the bug
When trying to launch a new GDB instance in the JVM with Ghidra, the following error message is generated:
Error Message
To Reproduce
Steps to reproduce the behavior:
Create a new connection to an debugging agent
buttonarm-none-eabi-gdb.exe
(assuming this on on PATH)Connect
Expected behavior
Debugger is launched successfully.
Environment (please complete the following information):
Additional context
The stack trace mentions Linux at some points. Perhaps the Linux code instead of Windows code is being called?
I was following the instructions on https://wrongbaud.github.io/posts/ghidra-debugger/
The text was updated successfully, but these errors were encountered: