Skip to content

Commit

Permalink
Redact private fields in dump
Browse files Browse the repository at this point in the history
  • Loading branch information
oyvindwe committed May 12, 2024
1 parent 0f2c64b commit 6ecc4f6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions connectlife/dump.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ async def main():

api = ConnectLifeApi(args.username, args.password)
appliances = await api.get_appliances_json()
# Redact private fields
for appliance in appliances:
appliance["deviceId"] = "<redacted>"
appliance["puid"] = "<redacted>"
appliance["wifiId"] = "<redacted>"
print(json.dumps([order_dict(a) for a in appliances], indent=2))

if __name__ == "__main__":
Expand Down

0 comments on commit 6ecc4f6

Please sign in to comment.