Skip to content

Commit

Permalink
add secret bypassing
Browse files Browse the repository at this point in the history
  • Loading branch information
Brain-dawg committed Feb 9, 2025
1 parent 3d5323a commit 40085c3
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2 deletions.
1 change: 0 additions & 1 deletion mge/functions.nut
Original file line number Diff line number Diff line change
Expand Up @@ -2552,7 +2552,6 @@
function allmeat() {
return
}

"4player" : function() {
return
}
Expand Down
2 changes: 1 addition & 1 deletion mge/vpi/vpi.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ def ExtractCallsFromFile(path):
data = json.loads(contents)

ident = Decrypt(**data["Identity"])
if (ident != vpi_config.SECRET):
if (ident != vpi_config.SECRET and not vpi_config.BYPASS_SECRET):
LOGGER.warning("Invalid identification in file: %s; ignoring", path)
return

Expand Down
1 change: 1 addition & 0 deletions mge/vpi/vpi_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
# This should be the same token returned in the GetSecret function in vpi.nut
# It's used to identify files created by VPI
SECRET = r""
BYPASS_SECRET = False #do not set this to true unless you know what you're doing
if (not SECRET):
raise RuntimeError("Please set your secret token")

Expand Down

0 comments on commit 40085c3

Please sign in to comment.