Skip to content

Commit

Permalink
Change ReservationID from UUID to str
Browse files Browse the repository at this point in the history
UUIDs are 128 bits long and, in string format, consist of 36 characters.
This is a much larger set of possible values than is required for our
purposes. Furthermore, we can increase entropy by increasing the
character set used in generating ReservationIDs. This will allow us to
have a large enough set of possible values using much less characters,
allowing agent binary download URLs to be significantly shortened.

Issue guardicore/monkey#4187
  • Loading branch information
mssalvatore committed Jun 10, 2024
1 parent ed1f1fd commit 6c1489c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ The format is based on [Keep a
Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to
the [PEP 440 version scheme](https://peps.python.org/pep-0440/#version-scheme).

## [v0.8.0] - 2024-06-10
### Changed
- `ReservationID` from a UUID to a string.
https://github.com/guardicore/monkey/issues/4187

## [v0.7.0] - 2024-05-14
### Changed
- The `agent_binary_transform` parameter to `agent_binary_wrapper_template` in
Expand Down
3 changes: 1 addition & 2 deletions agentpluginapi/agent_binary_request.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
from dataclasses import dataclass
from typing import TypeAlias
from uuid import UUID

from monkeytypes import Event, OperatingSystem

ReservationID: TypeAlias = UUID
ReservationID: TypeAlias = str


@dataclass(frozen=True)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ paths = ["agentpluginapi", "vulture_allowlist.py"]

[tool.poetry]
name = "monkey-agentpluginapi"
version = "v0.7.0"
version = "v0.8.0"
description = "Interfaces and components that comprise the Infection Monkey Agent Plugin API"
authors = [
"Ilija Lazoroski <[email protected]>",
Expand Down

0 comments on commit 6c1489c

Please sign in to comment.