{"id":40724322,"url":"https://github.com/deltaga/appxbackup.module","last_synced_at":"2026-01-22T15:21:01.284Z","repository":{"id":333221870,"uuid":"1135292752","full_name":"DeltaGa/AppxBackup.Module","owner":"DeltaGa","description":"Windows Application Package Backup \u0026 Restoration Toolkit","archived":false,"fork":false,"pushed_at":"2026-01-18T01:50:25.000Z","size":131,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-18T13:51:35.647Z","etag":null,"topics":["application","application-backup","appx","backup","microsoft-store","microsoft-store-app","msix","windows","windows-10","windows-11","windows-server-2019","windows-store","windows-store-app"],"latest_commit_sha":null,"homepage":"","language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DeltaGa.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-01-15T22:39:01.000Z","updated_at":"2026-01-18T13:46:36.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/DeltaGa/AppxBackup.Module","commit_stats":null,"previous_names":["deltaga/appxbackup.module"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/DeltaGa/AppxBackup.Module","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeltaGa%2FAppxBackup.Module","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeltaGa%2FAppxBackup.Module/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeltaGa%2FAppxBackup.Module/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeltaGa%2FAppxBackup.Module/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DeltaGa","download_url":"https://codeload.github.com/DeltaGa/AppxBackup.Module/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeltaGa%2FAppxBackup.Module/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28634785,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-21T04:47:28.174Z","status":"ssl_error","status_checked_at":"2026-01-21T04:47:22.943Z","response_time":86,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["application","application-backup","appx","backup","microsoft-store","microsoft-store-app","msix","windows","windows-10","windows-11","windows-server-2019","windows-store","windows-store-app"],"created_at":"2026-01-21T14:00:59.631Z","updated_at":"2026-01-21T14:01:23.901Z","avatar_url":"https://github.com/DeltaGa.png","language":"PowerShell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AppxBackup PowerShell Module v2.0.1\n\n## Windows Application Package Backup \u0026 Restoration Toolkit\n\n**Version:** 2.0.1  \n**Release Date:** January 15, 2026  \n**PowerShell:** 5.1+ (7.5+ Recommended)\n\n---\n\n## Table of Contents\n\n- [Overview](#overview)\n- [System Requirements](#system-requirements)\n- [Installation](#installation)\n- [Workflow Example](#workflow-example)\n- [Available Commands](#available-commands)\n- [Usage Examples](#usage-examples)\n- [Troubleshooting](#troubleshooting)\n- [Limitations](#limitations)\n- [Module Architecture](#module-architecture)\n- [Support](#support)\n- [Changelog](#changelog)\n- [Citations](#citations)\n\n---\n\n## Overview\n\nAppxBackup is a **complete 2026 rewrite** of the 2016 original APPX backup script, transformed into a production-grade PowerShell module. This toolkit provides **end-to-end** Windows Store/MSIX application backup and restoration.\n\n### Key Capabilities\n\n **Complete Backup-to-Installation Pipeline** - One-command backup, one-command restore  \n **Automatic Certificate Management** - Self-signed cert creation and system trust  \n **Native Windows SDK Integration** - MakeAppx and SignTool automation with tool-specific optimization  \n **Modern MSIX Support** - Full support for MSIX + legacy APPX formats  \n **Externalized Configuration** - Configuration values in JSON for easy customization\n\n---\n\n## System Requirements\n\n### Minimum Requirements\n\n- **PowerShell:** 5.1+\n- **OS:** Windows 10 1809 / Windows Server 2019\n- **Windows SDK:** 10.0.26100.0+ (includes MakeAppx, SignTool)\n- **Disk Space:** 100 MB temporary storage\n- **Memory:** 512 MB available RAM\n\n### Recommended Configuration\n\n- **PowerShell:** 7.5+\n- **OS:** Windows 11 24H2 / Windows Server 2022\n- **Windows SDK:** 10.0.26100.0+ (includes MakeAppx, SignTool)\n- **Disk Space:** 1 GB+ for large packages\n- **Memory:** 2 GB+ available RAM\n\n### Administrator Privileges\n\nRequired for:\n- Installing certificates to LocalMachine store\n- Accessing WindowsApps folder on some systems\n\nNot required for:\n- Basic backup operations (CurrentUser cert store)\n- Package creation\n- Most module functions\n\n---\n\n## Installation\n\n### Quick Start (Developer Mode)\n\n```powershell\n# 1. Clone or extract the module\ncd \"C:\\Path\\To\\AppxBackup.Module\"\n\n# 2. Import the module\n.\\Import-AppxBackup.ps1\n\n# 3. Verify installation\nGet-Command -Module AppxBackup\n```\n\n### Production Installation\n\n```powershell\n# Install to PowerShell Modules directory\n$modulePath = \"$env:USERPROFILE\\Documents\\PowerShell\\Modules\\AppxBackup\"\nCopy-Item -Path \".\\AppxBackup.Module\" -Destination $modulePath -Recurse -Force\n\n# Import globally\nImport-Module AppxBackup -Force\n\n# Verify\nGet-Module AppxBackup\n```\n\n---\n\n## Workflow Example\n\n### Scenario: Backup and Restore WorkMate App\n\n#### Step 1: Backup the Application\n\n```powershell\n# Find the installed app\n$app = Get-AppxPackage -Name \"*WorkMate*\"\n\n# Create complete backup (package + certificate)\nBackup-AppxPackage -PackagePath $app.InstallLocation -OutputPath \"D:\\Backups\"\n```\n\n**Output:**\n```\n=== Backup-AppxPackage v2.0 ===\nPackage: 2242AppsTeam.WorkMate v7.5.4.0\n\n[Stage 1/6] Validating inputs...                         ✓\n[Stage 2/6] Creating package...                          ✓ (6.4s, 47.95 MB)\n[Stage 3/6] Creating certificate...                      ✓\n[Stage 4/6] Installing certificate to Trusted Root...    ✓\n[Stage 5/6] Signing package...                           ✓\n\n✓ Certificate installed successfully - package is ready to install\n\nTo install the package, run:\n  Install-AppxBackup -PackagePath 'D:\\Backups\\WorkMate_7.5.4.0_x64.appx'\n```\n\n**Files Created:**\n```\nD:\\Backups\\\n├── 2242AppsTeam.WorkMate_7.5.4.0_x64__v313ts49xh8we.appx  (47.95 MB, signed)\n└── 2242AppsTeam.WorkMate_7.5.4.0_x64__v313ts49xh8we.cer  (certificate)\n```\n\n#### Step 2: Install on Another Machine\n\n```powershell\n# Single command - auto-detects certificate\nInstall-AppxBackup -PackagePath \"D:\\Backups\\WorkMate_7.5.4.0_x64.appx\"\n```\n\n**Output:**\n```\n=== APPX Package Installation Script ===\n\n[1/3] Package Analysis\n  Package: WorkMate_7.5.4.0_x64.appx\n  Certificate: Auto-detected (WorkMate_7.5.4.0_x64.cer)\n\n[2/3] Certificate Installation\n  Target Store: Cert:\\LocalMachine\\Root\n  Status: Installed successfully\n  Thumbprint: 439F89C615A7468BF196D8951BBA4640C10D7D3F\n\n[3/3] Package Installation\n  Installing package...\n  Status: Installed successfully\n  Name: 2242AppsTeam.WorkMate\n  Version: 7.5.4.0\n\n=== Installation Complete ===\n```\n\n---\n\n## Available Commands\n\n### Public Functions\n\n| Function | Description |\n|----------|-------------|\n| **`Backup-AppxPackage`** | Complete backup with cert creation and signing |\n| **`Install-AppxBackup`** | Installation with auto-cert handling and dependency orchestration |\n| **`New-AppxBackupCertificate`** | Create self-signed certificates (4096-bit RSA) |\n| **`Get-AppxBackupInfo`** | Analyze backup packages without installing |\n| **`Export-AppxDependencies`** | Extract and document package dependencies |\n| **`Test-AppxPackageIntegrity`** | Validate package structure and signatures |\n| **`Test-AppxBackupCompatibility`** | Check system compatibility before restore |\n| **`Get-AppxToolPath`** | Locate Windows SDK tools (MakeAppx, SignTool) |\n\n### Private Functions (Internal)\n\n- `Get-AppxConfiguration` - Configuration loader from JSON files\n- `Get-AppxDefault` - Configuration value accessor with hierarchical fallback\n- `Invoke-ProcessSafely` - Robust external process execution with timeout\n- `Get-AppxManifestData` - XML manifest parsing with namespace handling\n- `New-AppxPackageInternal` - Core packaging logic with multi-tier fallback\n- `Test-AppxToolAvailability` - SDK tool validation and caching\n- `Resolve-AppxDependencies` - Recursive dependency graph analysis\n- `ConvertTo-SecureFilePath` - Path validation and sanitization\n- `Write-AppxLog` - Structured logging with level filtering\n- `New-AppxBackupZipArchive` - ZIP archive creation for dependency packages\n- `New-AppxBackupManifest` - Installation manifest generation\n- `New-AppxDependencyCertificate` - Dependency-specific certificate creation\n\n---\n\n## Usage Examples\n\n### Basic Operations\n\n#### 1. Simple Backup\n```powershell\n$app = Get-AppxPackage -Name \"Microsoft.WindowsCalculator\"\nBackup-AppxPackage -PackagePath $app.InstallLocation -OutputPath \"C:\\Backups\"\n```\n\n#### 2. Backup with Custom Certificate\n```powershell\nBackup-AppxPackage -PackagePath $app.InstallLocation `\n    -OutputPath \"C:\\Backups\" `\n    -CertificateSubject \"CN=MyCompany Code Signing\" `\n    -CertificatePassword (ConvertTo-SecureString \"MyPassword\" -AsPlainText -Force)\n```\n\n#### 3. Skip Certificate (Use Existing)\n```powershell\nBackup-AppxPackage -PackagePath $app.InstallLocation `\n    -OutputPath \"C:\\Backups\" `\n    -NoCertificate\n```\n\n### Dependency Operations\n\n#### 4. Backup with Dependencies (ZIP Archive)\n```powershell\n# Creates .appxpack file with main package and all dependencies\nBackup-AppxPackage -PackagePath $app.InstallLocation `\n    -OutputPath \"C:\\Backups\" `\n    -IncludeDependencies\n```\n\n#### 5. Dependency Analysis Only (No Backup)\n```powershell\n# Creates PackageName_Dependencies.json without creating backup\nBackup-AppxPackage -PackagePath $app.InstallLocation `\n    -OutputPath \"C:\\Backups\" `\n    -DependencyReportOnly\n```\n\n### Batch Operations\n\n#### 6. Backup All Apps from a Publisher\n```powershell\nGet-AppxPackage -Publisher \"*Microsoft*\" | \n    ForEach-Object {\n        Backup-AppxPackage -PackagePath $_.InstallLocation `\n            -OutputPath \"D:\\Backups\\Microsoft\" `\n            -Verbose\n    }\n```\n\n### Installation Operations\n\n#### 7. Install Standalone Package\n```powershell\nInstall-AppxBackup -PackagePath \"C:\\Backups\\MyApp.appx\"\n```\n\n#### 8. Install ZIP Archive with Dependencies\n```powershell\nInstall-AppxBackup -PackagePath \"C:\\Backups\\MyApp.appxpack\"\n```\n\n#### 9. Install for Current User Only (No Admin)\n```powershell\nInstall-AppxBackup -PackagePath \"C:\\Backups\\MyApp.appx\" `\n    -CertStoreLocation CurrentUser\n```\n\n#### 10. Force Reinstall\n```powershell\nInstall-AppxBackup -PackagePath \"C:\\Backups\\MyApp.appx\" -Force\n```\n\n#### 11. Skip Certificate (Already Trusted)\n```powershell\nInstall-AppxBackup -PackagePath \"C:\\Backups\\MyApp.appx\" -SkipCertificate\n```\n\n#### 12. Allow Unsigned Packages (Developer Mode)\n```powershell\nInstall-AppxBackup -PackagePath \"C:\\Backups\\MyApp.appx\" -AllowUnsigned\n```\n\n---\n\n## Troubleshooting\n\n### Common Errors and Solutions\n\n#### Error: 0x800B0109 (Certificate Not Trusted)\n\n**Cause:** Certificate not in Trusted Root store  \n**Solution:**\n```powershell\n# Run as Administrator\nImport-Certificate -FilePath \"path\\to\\cert.cer\" `\n    -CertStoreLocation \"Cert:\\LocalMachine\\Root\"\n```\n\n#### Error: 0x80073CF9 (Already Installed)\n\n**Cause:** Package already installed  \n**Solution:**\n```powershell\nInstall-AppxBackup -PackagePath \"package.appx\" -Force\n```\n\n#### Error: MakeAppx Not Found\n\n**Cause:** Windows SDK not installed  \n**Solution:**\n1. Install Windows SDK from Microsoft\n\n#### Error: Access Denied (WindowsApps)\n\n**Cause:** Insufficient permissions  \n**Solution:**\n- Module automatically uses multi-tier copy fallback\n- Robocopy → Copy-Item → .NET APIs\n- No manual intervention needed\n\n---\n\n## Limitations\n\n### Dependency Repackaging Behavior\n\nThe `-IncludeDependencies` parameter repackages applications with their framework dependencies into a single `.appxpack` archive. Some applications cannot be successfully repackaged and restored. If a repackaged application fails to install, the application cannot be used from the backup. Reinstall from the Microsoft Store.\n\n---\n\n## Module Architecture\n\n```\nAppxBackup.Module/\n├── AppxBackup.psd1           # Module manifest\n├── AppxBackup.psm1           # Module loader\n├── Import-AppxBackup.ps1     # Quick import helper\n│\n├── Config/                   # Externalized configuration\n│   ├── ModuleDefaults.json           # Core module constants\n│   ├── MimeTypes.json                # MIME type mappings\n│   ├── ToolConfiguration.json        # Tool-specific settings\n│   ├── WindowsReservedNames.json     # Reserved filenames\n│   ├── PackageConfiguration.json     # Package-related constants\n│   └── ZipPackagingConfiguration.json # ZIP archive settings\n│\n├── Public/                   # Exported functions\n│   ├── Backup-AppxPackage.ps1          # Main backup function\n│   ├── Install-AppxBackup.ps1          # Package installer (Restore-AppxPackage alias)\n│   ├── New-AppxBackupCertificate.ps1   # Certificate creation\n│   ├── Get-AppxBackupInfo.ps1          # Package analysis\n│   ├── Export-AppxDependencies.ps1     # Dependency export\n│   ├── Test-AppxPackageIntegrity.ps1   # Integrity validation\n│   ├── Test-AppxBackupCompatibility.ps1 # Compatibility check\n│   └── Get-AppxToolPath.ps1            # Tool locator\n│\n├── Private/                  # Internal functions\n│   ├── Get-AppxConfiguration.ps1       # Configuration loader\n│   ├── Get-AppxDefault.ps1             # Configuration value accessor\n│   ├── Invoke-ProcessSafely.ps1        # Process execution\n│   ├── Get-AppxManifestData.ps1        # Manifest parsing\n│   ├── New-AppxPackageInternal.ps1     # Core packaging logic\n│   ├── Test-AppxToolAvailability.ps1   # Tool validation\n│   ├── Resolve-AppxDependencies.ps1    # Dependency resolution\n│   ├── ConvertTo-SecureFilePath.ps1    # Path sanitization\n│   ├── Write-AppxLog.ps1               # Logging system\n│   ├── New-AppxBackupZipArchive.ps1    # ZIP archive creation\n│   ├── New-AppxBackupManifest.ps1      # Installation manifest generation\n│   └── New-AppxDependencyCertificate.ps1 # Dependency certificate creation\n│\n└── Examples/                 # Usage examples\n    └── UsageExamples.md\n```\n---\n\n### Configuration System\n\nAll hardcoded values are externalized to JSON configuration files in the `Config/` directory:\n\n- **ModuleDefaults.json** - Path limits, timeouts, buffer sizes, disk space thresholds, etc.\n- **MimeTypes.json** - Comprehensive MIME type database for Content_Types.xml generation\n- **ToolConfiguration.json** - Tool-specific timeouts, async wait times, exit code interpretation\n- **WindowsReservedNames.json** - Windows reserved filenames for validation\n- **PackageConfiguration.json** - Package extensions, signature files, compression levels, namespaces\n\n---\n\n## Support\n\n### Getting Help\n\n- **Documentation:** Enter `help Command` (e. g. `help Backup-AppxPackage`)\n- **Examples:** See `/Examples/UsageExamples.md`\n- **Issues:** Check logs in `$env:TEMP\\AppxBackup_*.log`\n\n### Reporting Issues\n\nWhen reporting issues, include:\n1. PowerShell version (`$PSVersionTable`)\n2. Windows version (`Get-ComputerInfo | Select OSName, OSVersion`)\n3. Error message and stack trace\n4. Log file from `$env:TEMP\\AppxBackup_*.log`\n\n---\n\n## Changelog\n\n### Version 2.0.1 (January 20, 2026)\n\n#### Dependency Packaging\n- Replaced bundle system with ZIP archives (.appxpack) containing packages, certificates, and metadata\n- Metadata-driven installation orchestration with ordered dependency resolution\n\n#### Configuration System\n- Introduced external JSON-based configuration system for module extensibility\n\n#### Manifest Parsing\n- Rewrote Get-AppxManifestData with multi-tier fallback strategies for namespace resolution\n- Handles malformed and non-standard manifests without hard dependency on Microsoft schemas\n\n#### Certificate Management\n- Automatic installation to Trusted Root store immediately after creation\n- Privilege escalation fallback with intelligent warnings\n- Individual certificates for each dependency in ZIP archives\n\n#### SDK Tool Validation\n- Test-AppxToolAvailability now returns tool path string instead of boolean\n- Mandatory validation in Backup-AppxPackage with installation diagnostics and PATH analysis\n\n#### Process Execution\n- Unified process safety with tool-specific timeouts\n- Output buffer limit per stream to prevent memory exhaustion\n\n#### Installation\n- Extended Install-AppxBackup to support ZIP archives with nested package handling\n- Improved progress reporting with separate extraction, validation, and installation stages\n\n#### Future Changes (Planned)\n- Extend Get-AppxBackupInfo to analyze .appxpack files with full metadata extraction\n- Extend Test-AppxPackageIntegrity to validate .appxpack archive structure and signatures\n- Extend Test-AppxBackupCompatibility to assess system compatibility for .appxpack installation\n\n---\n\n## Citations\n\n### Original Repository\n\n[**mjmeans/Appx-Backup**](https://github.com/mjmeans/Appx-Backup): PowerShell script to backup an installed Windows Store App to an installable Appx file. (2016). *GitHub*.\n\n---\n\n© 2026 DeltaGa. All rights reserved.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeltaga%2Fappxbackup.module","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeltaga%2Fappxbackup.module","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeltaga%2Fappxbackup.module/lists"}