Skip to content

Commit

Permalink
[Docs] Typos fixes (#1160)
Browse files Browse the repository at this point in the history
## Description

This PR fixes several typos in the doucmentation.
No code was changed.
  • Loading branch information
Mic92 authored Dec 27, 2024
1 parent 283a7f6 commit 5225358
Show file tree
Hide file tree
Showing 10 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions docs/api/gef.md
Original file line number Diff line number Diff line change
Expand Up @@ -1156,7 +1156,7 @@ register_architecture(
```

`register_architecture` is **DEPRECATED** and will be removed in the future.
Using the decorator `register_architecture` is unecessary
Using the decorator `register_architecture` is unnecessary


---
Expand Down Expand Up @@ -7576,7 +7576,7 @@ usage() → None
---

## <kbd>class</kbd> `GefTmuxSetup`
Setup a confortable tmux debugging environment.
Setup a comfortable tmux debugging environment.

<a href="https://cs.github.com/hugsy/gef?q=GefTmuxSetup.__init__"><img align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square"></a>

Expand Down
2 changes: 1 addition & 1 deletion docs/commands/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ gef➤ gef config pcustom.struct_path
```

Of course you can edit the values. For example, if you want the screen to be cleared before
displaying the current context when reaching a breakpoing:
displaying the current context when reaching a breakpoint:

```text
gef➤ gef config context.clear_screen 1
Expand Down
2 changes: 1 addition & 1 deletion docs/commands/dereference.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
The `dereference` command (also aliased `telescope` for PEDA former users) aims to simplify the
dereferencing of an address in GDB to determine the content it actually points to.

It is a useful convienence function to spare to process of manually tracking values with successive
It is a useful convenience function to spare to process of manually tracking values with successive
`x/x` in GDB.

`dereference` takes three optional arguments, a start address (or symbol or register, etc) to
Expand Down
2 changes: 1 addition & 1 deletion docs/commands/gef-remote.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[`target remote`](https://sourceware.org/gdb/onlinedocs/gdb/Remote-Debugging.html#Remote-Debugging)
is the traditional GDB way of debugging process or system remotely. However this command by itself
does a limited job (80's bandwith FTW) to collect more information about the target, making the
does a limited job (80's bandwidth FTW) to collect more information about the target, making the
process of debugging more cumbersome. GEF greatly improves that state with the `gef-remote` command.

📝 **Note**: If using GEF, `gef-remote` **must** be your way or debugging remote processes, never
Expand Down
2 changes: 1 addition & 1 deletion docs/commands/gef.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,5 +141,5 @@ different branch through the `gef.default_branch` configuration setting:
gef➤ gef config gef.default_branch my_other_branch
```

The files will be dowloaded in the path configured in the `gef.extra_plugins_dir` setting, allowing
The files will be downloaded in the path configured in the `gef.extra_plugins_dir` setting, allowing
to reload it easily without having to re-download.
2 changes: 1 addition & 1 deletion docs/commands/heap-analysis-helper.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ gef➤ heap-analysis
[+] Tracking malloc()
[+] Tracking free()
[+] Disabling hardware watchpoints (this may increase the latency)
[+] Dynamic breakpoints correctly setup, GEF will break execution if a possible vulnerabity is found.
[+] Dynamic breakpoints correctly setup, GEF will break execution if a possible vulnerability is found.
[+] To disable, clear the malloc/free breakpoints (`delete breakpoints`) and restore hardware breakpoints (`set can-use-hw-watchpoints 1`)
```

Expand Down
2 changes: 1 addition & 1 deletion docs/commands/memory.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ register addresses, lengths, and grouping size.

![memory watch](https://i.imgur.com/NXYwSwW.png)

_Note_: this command **shoud NOT** be mistaken with the [GDB `watch`
_Note_: this command **should NOT** be mistaken with the [GDB `watch`
command](https://sourceware.org/gdb/current/onlinedocs/gdb/Set-Watchpoints.html) meant to set
breakpoints on memory access (read,write,exec).

Expand Down
16 changes: 8 additions & 8 deletions gef.py
Original file line number Diff line number Diff line change
Expand Up @@ -2329,7 +2329,7 @@ def get_zone_base_address(name: str) -> int | None:
# Architecture classes
#

@deprecated("Using the decorator `register_architecture` is unecessary")
@deprecated("Using the decorator `register_architecture` is unnecessary")
def register_architecture(cls: Type["Architecture"]) -> Type["Architecture"]:
return cls

Expand Down Expand Up @@ -2480,7 +2480,7 @@ def endianness(self) -> Endianness:
elif "big endian" in output:
self._endianness = Endianness.BIG_ENDIAN
else:
raise OSError(f"No valid endianess found in '{output}'")
raise OSError(f"No valid endianness found in '{output}'")
return self._endianness

def get_ith_parameter(self, i: int, in_func: bool = True) -> tuple[str, int | None]:
Expand Down Expand Up @@ -6046,7 +6046,7 @@ class SearchPatternCommand(GenericCommand):
_example_ = [f"{_cmdline_} AAAAAAAA",
f"{_cmdline_} 0x555555554000 little stack",
f"{_cmdline_} AAAA 0x600000-0x601000",
f"{_cmdline_} --regex 0x401000 0x401500 ([\\\\x20-\\\\x7E]{{2,}})(?=\\\\x00) <-- It matchs null-end-printable(from x20-x7e) C strings (min size 2 bytes)"]
f"{_cmdline_} --regex 0x401000 0x401500 ([\\\\x20-\\\\x7E]{{2,}})(?=\\\\x00) <-- It matches null-end-printable(from x20-x7e) C strings (min size 2 bytes)"]

def __init__(self) -> None:
super().__init__()
Expand Down Expand Up @@ -9691,7 +9691,7 @@ def setup(self) -> None:
gdb.execute("set can-use-hw-watchpoints 0")

info("Dynamic breakpoints correctly setup, "
"GEF will break execution if a possible vulnerabity is found.")
"GEF will break execution if a possible vulnerability is found.")
warn(f"{Color.colorify('Note', 'bold underline yellow')}: "
"The heap analysis slows down the execution noticeably.")

Expand Down Expand Up @@ -10000,13 +10000,13 @@ def load_plugin(fpath: pathlib.Path) -> bool:

def load_plugins_from_directory(plugin_directory: pathlib.Path):
nb_added = -1
nb_inital = len(__registered_commands__)
nb_initial = len(__registered_commands__)
start_time = time.perf_counter()
for entry in plugin_directory.glob("**/*.py"):
load_plugin(entry)

try:
nb_added = len(__registered_commands__) - nb_inital
nb_added = len(__registered_commands__) - nb_initial
if nb_added > 0:
self.load()
nb_failed = len(__registered_commands__) - len(self.commands)
Expand Down Expand Up @@ -10733,7 +10733,7 @@ def reset_caches(self) -> None:
continue
obj.cache_clear()
except Exception:
# we're reseting the cache here, we don't care if (or which) exception triggers
# we're resetting the cache here, we don't care if (or which) exception triggers
continue
return

Expand Down Expand Up @@ -10972,7 +10972,7 @@ def parse_monitor_info_mem() -> Generator[Section, None, None]:
@staticmethod
def parse_gdb_maintenance_info_sections() -> Generator[Section, None, None]:
"""Get the memory mapping from GDB's command `maintenance info sections` (limited info). In some cases (i.e. coredumps),
the memory info collected by `info proc sections` is insufficent."""
the memory info collected by `info proc sections` is insufficient."""
stream = StringIO(gdb.execute("maintenance info sections", to_string=True))

for line in stream:
Expand Down
2 changes: 1 addition & 1 deletion scripts/new-release.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

"""
Small script to generate the changelog for a new release. It uses information from
both git and Github to create teh changelog in Markdown, which can be simply copy/pasted
both git and Github to create the changelog in Markdown, which can be simply copy/pasted
to the Github release page.
The script requires a Github token to be set in the environment variable `GITHUB_REPO_TOKEN`.
Expand Down
4 changes: 2 additions & 2 deletions tests/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ def findlines(substring: str, buffer: str) -> List[str]:

def removeafter(substring: str, buffer: str, included: bool = False) -> str:
"""Returns a copy of `buffer` truncated after `substring` is found. If
`included` is True, the result also includes the subtring.
`included` is True, the result also includes the substring.
Args:
substring (str)
Expand All @@ -235,7 +235,7 @@ def removeafter(substring: str, buffer: str, included: bool = False) -> str:

def removeuntil(substring: str, buffer: str, included: bool = False) -> str:
"""Returns a copy of `buffer` truncated until `substring` is found. If
`included` is True, the result also includes the subtring.
`included` is True, the result also includes the substring.
Args:
substring (str)
Expand Down

0 comments on commit 5225358

Please sign in to comment.