Skip to content

Commit

Permalink
fix auxiliary files
Browse files Browse the repository at this point in the history
  • Loading branch information
Jamesits committed Jun 24, 2021
1 parent 52888f4 commit 170ea8f
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@ I am really poor and I really can't afford a license. I just want to get rid of

## Features

* Works for any version >=5 (we've tested this from 5.3 to 6.0 without any changes in the code)
* Supports Proxmox VE and Proxmox Mail Gateway
* Works for:
- Proxmox VE (5.x or later, tested up to 7.0)
- Proxmox Mail Gateway (5.x or later)
- Proxmox Backup Server (1.x)
* Non-intrusive, no changes to any system file, persists between system updates
* Comes with standard Debian package, easy to manage and automate
* You can uninstall at any time, hassle-free
* **No JavaScript**
* **No JavaScript is involved** in the whole process

## Installation

Expand Down
3 changes: 2 additions & 1 deletion scripts/purge
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
rm -f /etc/subscription
rm -f /etc/pmg/subscription
rm -f /etc/pmg/subscription
rm -f /etc/proxmox-backup/subscription
6 changes: 3 additions & 3 deletions usr/bin/pve-fake-subscription
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ from typing import List
from datetime import datetime, timedelta

# PVE & PMG: /usr/share/perl5/PVE/Subscription.pm
# PBS: /usr/lib/x86_64-linux-gnu/proxmox-backup/*
# PBS: /usr/lib/x86_64-linux-gnu/proxmox-backup/* (source code at `https://git.proxmox.com/git/proxmox-backup.git`)
shared_key_data = "kjfdlskfhiuewhfk947368"
server_key_file = "/etc/ssh/ssh_host_rsa_key.pub"

def get_timestamp() -> int:
return int(time.time())

# Perl's md5_base64_perl implementation
# Perl's md5_base64 implementation
def md5_base64_perl(x: str) -> str:
return base64.b64encode(hashlib.md5(x.encode()).digest()).strip(b'=').decode()

Expand Down Expand Up @@ -89,7 +89,7 @@ def generate_subscription_pbs(key: str, server_ids: List[str]) -> str:

return key + "\n" + csum + "\n" + data + "\n"

# key_pattern can be find in src/tools/subscription.rs
# Key pattern: pbst-xxxxxxxxxx
def activate_pbs(key: str, subscription_file: str) -> None:
# get machine ID
server_id = ""
Expand Down

0 comments on commit 170ea8f

Please sign in to comment.