mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2026-09-28 17:11:11 -09:00
Merge remote-tracking branch 'origin/patch'
This commit is contained in:
@@ -325,6 +325,11 @@ import pdb # imports Python's pdb
|
||||
import pdb_ # imports Ghidra's pdb
|
||||
```
|
||||
## Change History
|
||||
__2.2.1:__
|
||||
* PyGhidra now launches with the current working directory removed from `sys.path` to prevent
|
||||
the potential for importing invalid modules from random `ghidra/` or `java/` directories that may
|
||||
exist in the user's current working directory.
|
||||
|
||||
__2.2.0:__
|
||||
* [`pyghidra.open_program()`](#pyghidraopen_program) and
|
||||
[`pyghidra.run_script()`](#pyghidrarun_script) now accept a `nested_project_location` parameter
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
##
|
||||
__version__ = "2.2.0"
|
||||
__version__ = "2.2.1"
|
||||
|
||||
# stub for documentation and typing
|
||||
# this is mostly to hide the function parameter
|
||||
|
||||
@@ -429,6 +429,10 @@ class PyGhidraLauncher:
|
||||
**jpype_kwargs
|
||||
)
|
||||
|
||||
# Remove CWD from sys.path so we don't try to import from unintentional directories
|
||||
# (i.e, an unrelated "ghidra" directory the user may have created)
|
||||
sys.path.remove(os.getcwd())
|
||||
|
||||
# Install hooks into python importlib
|
||||
sys.meta_path.append(_PyGhidraImportLoader())
|
||||
sys.meta_path.append(_GhidraBundleFinder())
|
||||
|
||||
Reference in New Issue
Block a user