Pretendo BOSS server implementation
Go to file
mrjvs e66bc817b1
Some checks failed
Build and Publish Docker Image / Build and Publish Docker Image (amd64) (push) Has been cancelled
Build and Publish Docker Image / Build and Publish Docker Image (arm64) (push) Has been cancelled
Merge branch 'master' into dev
2025-09-29 22:46:24 +02:00
.github/workflows Use actual main branch for latest tag 2025-09-17 00:18:18 +02:00
scripts chore: remove deprecated script 2025-09-14 19:22:54 +02:00
seeding chore: rename all files to include ".enc" 2025-09-14 19:26:27 +02:00
src Merge branch 'master' into dev 2025-09-29 22:46:24 +02:00
.dockerignore feat: Dockerize server 2024-07-02 14:34:35 -04:00
.editorconfig chore: add JSON and YML exceptions to editorconfig 2025-01-08 13:04:00 +00:00
.gitignore feat: add fully featured seeding command 2025-09-14 15:05:45 +02:00
boss feat: add util script to start BOSS CLI 2025-09-16 19:01:15 +02:00
Dockerfile chore: add libc compatiblity for dotnet (dont ask) 2025-09-19 22:30:25 +02:00
eslint.config.mjs chore: update common eslint to include global ignores 2025-01-19 23:39:05 +00:00
LICENSE Create LICENSE 2022-08-13 20:21:26 -04:00
package-lock.json Merge branch 'dev' into chore/cve-fixes 2025-09-19 20:56:57 +02:00
package.json Merge branch 'dev' into chore/cve-fixes 2025-09-19 20:56:57 +02:00
README.md chore: remove update-rotations.mjs and replace it with documentation on how to use the CLI 2025-09-17 12:08:32 +02:00
tsconfig.json chore; use tsup for building 2025-01-09 17:35:49 +00:00
tsup.config.ts feat: add foundation for a BOSS CLI 2025-09-03 22:20:50 +02:00

BOSS

Handles all BOSS (Background Online Storage Service) related tasks for the Pretendo network.

What does BOSS handle?

  • SpotPass on 3DS
  • Tasksheets and policy files for both WiiU and 3DS
  • Streetpass relay

Configuration

Configurations are loaded through environment variables. .env files are supported.

Environment variable Description Default
PN_BOSS_CONFIG_HTTP_PORT The HTTP port the server listens on None
PN_BOSS_CONFIG_LOG_FORMAT What logging format to use, possible options: pretty or json pretty
PN_BOSS_CONFIG_LOG_LEVEL What log level to use info
PN_BOSS_CONFIG_BOSS_WIIU_AES_KEY The BOSS WiiU AES key, needs to be dumped from a console None
PN_BOSS_CONFIG_BOSS_WIIU_HMAC_KEY The BOSS WiiU HMAC key, needs to be dumped from a console None
PN_BOSS_CONFIG_BOSS_3DS_AES_KEY The BOSS 3DS AES key, needs to be dumped from a console None
PN_BOSS_CONFIG_MONGO_CONNECTION_STRING MongoDB connection string None
PN_BOSS_CONFIG_GRPC_BOSS_SERVER_ADDRESS Address for the GRPC server to listen on None
PN_BOSS_CONFIG_GRPC_BOSS_SERVER_PORT Port for the GRPC server to listen on None
PN_BOSS_CONFIG_GRPC_BOSS_SERVER_API_KEY API key that services will use to connect to the BOSS GRPC server None
PN_BOSS_CONFIG_GRPC_ACCOUNT_SERVER_ADDRESS Address of the account GRPC server None
PN_BOSS_CONFIG_GRPC_ACCOUNT_SERVER_PORT Port of the account GRPC server None
PN_BOSS_CONFIG_GRPC_ACCOUNT_SERVER_API_KEY API key of the account GRPC server None
PN_BOSS_CONFIG_GRPC_FRIENDS_SERVER_ADDRESS Address of the friends GRPC server None
PN_BOSS_CONFIG_GRPC_FRIENDS_SERVER_PORT Port of the friends GRPC server None
PN_BOSS_CONFIG_GRPC_FRIENDS_SERVER_API_KEY API key of the friends GRPC server None
PN_BOSS_CONFIG_S3_ENDPOINT S3 server endpoint None
PN_BOSS_CONFIG_S3_REGION S3 server region None
PN_BOSS_CONFIG_S3_BUCKET S3 server bucket None
PN_BOSS_CONFIG_S3_ACCESS_KEY S3 access key None
PN_BOSS_CONFIG_S3_ACCESS_SECRET S3 access key secret None
PN_BOSS_CONFIG_CDN_DISK_PATH Storage path for the CDN, use as alternative for S3 None
PN_BOSS_CONFIG_STREETPASS_RELAY_ENABLED Should Streetpass Relay be enabled? false
PN_BOSS_CONFIG_STREETPASS_RELAY_CLEAN_OLD_DATA Should old Streetpass Relay data be automatically cleaned up? false
PN_BOSS_CONFIG_DOMAINS_NPDI What domain should the NPDI component use? npdi.cdn.pretendo.cc
PN_BOSS_CONFIG_DOMAINS_NPDL What domain should the NPDL component use? npdl.cdn.pretendo.cc
PN_BOSS_CONFIG_DOMAINS_NPFL What domain should the NPFL component use? npfl.c.app.pretendo.cc
PN_BOSS_CONFIG_DOMAINS_NPPL What domain should the NPPL component use? nppl.app.pretendo.cc,nppl.c.app.pretendo.cc
PN_BOSS_CONFIG_DOMAINS_NPTS What domain should the NPTS component use? npts.app.pretendo.cc
PN_BOSS_CONFIG_DOMAINS_SPR What domain should the SPR component use? service.spr.app.pretendo.cc

S3 server

The S3 server is optional, you can set PN_BOSS_CONFIG_CDN_DISK_PATH if you want to use a local folder as CDN source instead.

BOSS CLI

The CLI is a helper to interact with the content of the BOSS server.

npm run build
./boss --help

CLI configuration

Configurations are loaded through environment variables. .env files are supported.

Environment variable Description
PN_BOSS_CLI_GRPC_HOST The Host that the BOSS GRPC server is on. Example: localhost:5678 Required
PN_BOSS_CLI_GRPC_APIKEY Master API key of the BOSS GRPC server. Required
PN_BOSS_CLI_WIIU_AES_KEY The BOSS WiiU AES key, needs to be dumped from a console Optional
PN_BOSS_CLI_WIIU_HMAC_KEY The BOSS WiiU HMAC key, needs to be dumped from a console Optional
PN_BOSS_CLI_NPDI_URL The URL of the NPDI part the BOSS HTTP server, only needed when downloading Optional
PN_BOSS_CLI_NPDI_HOST The Host header for the NPDI requests. Use when you don't have NPDI exposed to the internet Optional

Common CLI operations

# Download taskfile and decrypt
./boss file ls <BOSS_APP_ID> <TASK_ID> # View list of files and their IDs
./boss file view --decrypt <BOSS_APP_ID> <TASK_ID> <DATA_ID> > output.txt # Download file and decrypt
# Update splatoon rotations
# Run the following for all of these BOSS app ids:
# - bb6tOEckvgZ50ciH
# - rjVlM7hUXPxmYQJh
# - zvGSM4kOrXpkKnpT
./boss file create <BOSS_APP_ID> schdat2 --name VSSetting.byaml --type AppData --notify-new app --file <FILE_PATH_FOR_VSSETTING>