pydorky 2.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/.devcontainer/devcontainer.json +17 -0
  2. package/.github/FUNDING.yml +15 -0
  3. package/.github/workflows/e2e-integration.yml +57 -0
  4. package/.github/workflows/publish.yml +24 -0
  5. package/.nvmrc +1 -0
  6. package/LICENSE +21 -0
  7. package/README.md +156 -0
  8. package/bin/index.js +19 -0
  9. package/bin/legacy.js +432 -0
  10. package/docs/doc#1 get-started/README.md +105 -0
  11. package/docs/doc#2 features-wishlist +33 -0
  12. package/docs/doc#2.5 python-port +31 -0
  13. package/docs/doc#3 the-correct-node-version +107 -0
  14. package/docs/doc#4 why-where-python +42 -0
  15. package/docs/doc#5 how-do-endpoints-cli-work +0 -0
  16. package/dorky-usage-aws.svg +1 -0
  17. package/dorky-usage-google-drive.svg +1 -0
  18. package/google-drive-credentials.json +16 -0
  19. package/openapi/openapi.yaml +257 -0
  20. package/package.json +46 -0
  21. package/python-client/README.md +19 -0
  22. package/python-client/dorky_client/__init__.py +3 -0
  23. package/python-client/dorky_client/client.py +32 -0
  24. package/python-client/pyproject.toml +13 -0
  25. package/python-client/tests/test_integration.py +20 -0
  26. package/rectdorky.png +0 -0
  27. package/server/index.js +193 -0
  28. package/server/package.json +12 -0
  29. package/todo/01-core-infrastructure.md +84 -0
  30. package/todo/02-storage-providers.md +104 -0
  31. package/todo/03-compression-formats.md +94 -0
  32. package/todo/04-python-client.md +126 -0
  33. package/todo/05-metadata-versioning.md +116 -0
  34. package/todo/06-performance-concurrency.md +130 -0
  35. package/todo/07-security-encryption.md +114 -0
  36. package/todo/08-developer-experience.md +175 -0
  37. package/todo/README.md +37 -0
  38. package/web-app/README.md +70 -0
  39. package/web-app/package-lock.json +17915 -0
  40. package/web-app/package.json +43 -0
  41. package/web-app/public/favicon.ico +0 -0
  42. package/web-app/public/index.html +43 -0
  43. package/web-app/public/logo192.png +0 -0
  44. package/web-app/public/logo512.png +0 -0
  45. package/web-app/public/manifest.json +25 -0
  46. package/web-app/public/robots.txt +3 -0
  47. package/web-app/src/App.css +23 -0
  48. package/web-app/src/App.js +84 -0
  49. package/web-app/src/App.test.js +8 -0
  50. package/web-app/src/PrivacyPolicy.js +26 -0
  51. package/web-app/src/TermsAndConditions.js +41 -0
  52. package/web-app/src/index.css +3 -0
  53. package/web-app/src/index.js +26 -0
  54. package/web-app/src/logo.svg +1 -0
  55. package/web-app/src/reportWebVitals.js +13 -0
  56. package/web-app/src/setupTests.js +5 -0
  57. package/web-app/tailwind.config.js +10 -0
@@ -0,0 +1,114 @@
1
+ # Security & Encryption
2
+
3
+ Client-side encryption, key management, and secure authentication.
4
+
5
+ ## P1: Client-Side Encryption at Rest
6
+
7
+ ### AES-256 Encryption
8
+ - [ ] Implement AES-256-GCM encryption
9
+ - [ ] Use `crypto` module in Node.js
10
+ - [ ] Support encryption in Python with `cryptography`
11
+ - [ ] Encrypt before upload, decrypt after download
12
+
13
+ ### Key Management (User-Provided)
14
+ - [ ] Allow user to provide encryption key (password or raw key)
15
+ - [ ] Derive key from password using PBKDF2 (cost factor 100k+)
16
+ - [ ] Store key securely (not in config, in key ring)
17
+ - [ ] Add `--encrypt-key <path>` flag to CLI
18
+
19
+ ### Encryption Metadata
20
+ - [ ] Store encryption algorithm and parameters in metadata
21
+ - [ ] Store salt for key derivation
22
+ - [ ] Store IV for GCM in metadata (safe to store)
23
+ - [ ] Prevent accidental download without decryption
24
+
25
+ ### CLI Support
26
+ - [ ] Add `--encrypt` flag to upload command
27
+ - [ ] Add `--decrypt` flag to download command
28
+ - [ ] Prompt for password if not provided
29
+ - [ ] Support keychain integration (macOS Keychain, Windows Credential Manager)
30
+
31
+ ## P1: Selective File Encryption
32
+
33
+ ### Pattern-Based Encryption
34
+ - [ ] Create `.dorkyencrypt` file (like `.gitignore`)
35
+ - [ ] Support patterns: `*.key`, `secrets/*`, `*.pem`, etc.
36
+ - [ ] Encrypt matching files automatically on upload
37
+ - [ ] Decrypt on download transparently
38
+
39
+ ### Obfuscation Mode (Optional)
40
+ - [ ] Implement faster obfuscation (XOR, Base64) for non-sensitive data
41
+ - [ ] Use `--obfuscate` flag (less secure, faster)
42
+ - [ ] Document security limitations clearly
43
+
44
+ ## P2: KMS Integration
45
+
46
+ ### AWS KMS
47
+ - [ ] Use AWS KMS for key management
48
+ - [ ] Generate data keys from KMS master key
49
+ - [ ] Encrypt/decrypt using AWS SDK
50
+ - [ ] Support assume role for cross-account KMS
51
+ - [ ] Add `--kms-key-id=<arn>` flag
52
+
53
+ ### Google Cloud KMS
54
+ - [ ] Use Google Cloud KMS
55
+ - [ ] Similar flow to AWS KMS
56
+ - [ ] Support project ID and key ring configuration
57
+ - [ ] Add `--gcp-kms-key=<resource-name>` flag
58
+
59
+ ### Azure Key Vault
60
+ - [ ] Use Azure Key Vault for key management
61
+ - [ ] Support managed identity authentication
62
+ - [ ] Add `--azure-key-vault-url=<url>` flag
63
+
64
+ ### KMS Metadata
65
+ - [ ] Store which KMS was used in metadata
66
+ - [ ] Store wrapped key in metadata
67
+ - [ ] Support key rotation with rekeying
68
+
69
+ ## P2: Authentication & Authorization
70
+
71
+ ### API Key Support
72
+ - [ ] Generate API keys for programmatic access
73
+ - [ ] Hash keys server-side (not plaintext)
74
+ - [ ] Support key expiration and rotation
75
+ - [ ] Add `dorky auth generate-key` command
76
+
77
+ ### JWT Tokens
78
+ - [ ] Support JWT tokens for authentication
79
+ - [ ] Issue tokens with short TTL (1 hour)
80
+ - [ ] Refresh tokens for longer sessions
81
+ - [ ] Add claims for user ID, project, scopes
82
+
83
+ ### Role-Based Access Control (RBAC)
84
+ - [ ] Define roles: admin, writer, reader
85
+ - [ ] Enforce at API level (who can upload, delete, etc.)
86
+ - [ ] Support resource-level permissions (bucket, artifact, folder)
87
+ - [ ] Audit role changes
88
+
89
+ ## P3: Advanced Security
90
+
91
+ ### Public Key Cryptography
92
+ - [ ] Support RSA or ECDH for key agreement
93
+ - [ ] Allow sharing encrypted files with specific users
94
+ - [ ] Implement key exchange protocol
95
+
96
+ ### Multi-User Encryption
97
+ - [ ] Encrypt file once, share with multiple users
98
+ - [ ] Each user has encrypted copy of data key
99
+ - [ ] Support adding/removing users from access list
100
+
101
+ ### Compliance Features
102
+ - [ ] Support FIPS 140-2 mode (restricted algorithms)
103
+ - [ ] Audit all encryption operations
104
+ - [ ] Log key access and rotation
105
+
106
+ ### Secret Rotation
107
+ - [ ] Auto-rotate encryption keys on schedule
108
+ - [ ] Re-encrypt existing files with new key
109
+ - [ ] Track which key was used for each file
110
+
111
+ ---
112
+
113
+ **Status**: Encryption design ready, implementation pending
114
+ **Next**: Implement AES-256-GCM, user key management, selective encryption patterns
@@ -0,0 +1,175 @@
1
+ # Developer Experience
2
+
3
+ Documentation, configuration, testing, and error handling.
4
+
5
+ ## P0: Documentation
6
+
7
+ ### README Updates
8
+ - [ ] Update main README with current architecture (HTTP service + thin clients)
9
+ - [ ] Add architecture diagram (ASCII or SVG)
10
+ - [ ] Add quick start guide for Node and Python
11
+ - [ ] Add cloud provider setup instructions (S3, GCS, Azure)
12
+ - [ ] Add troubleshooting section
13
+
14
+ ### API Documentation
15
+ - [ ] Generate API docs from OpenAPI spec (Swagger UI)
16
+ - [ ] Host Swagger UI at `/api/docs`
17
+ - [ ] Add cURL examples for each endpoint
18
+ - [ ] Document error codes and response formats
19
+
20
+ ### CLI Documentation
21
+ - [ ] Document all CLI commands and flags
22
+ - [ ] Add `dorky --help` output
23
+ - [ ] Create `docs/cli-reference.md`
24
+ - [ ] Add usage examples for common workflows
25
+
26
+ ### Guides
27
+ - [ ] Create `docs/guides/` directory
28
+ - [ ] Add guide: "Using S3 with Dorky"
29
+ - [ ] Add guide: "Data compression strategies"
30
+ - [ ] Add guide: "Python integration"
31
+ - [ ] Add guide: "GitHub Actions integration"
32
+
33
+ ### Architecture Document
34
+ - [ ] Document system design and decisions
35
+ - [ ] Explain HTTP service role
36
+ - [ ] Explain client library architecture
37
+ - [ ] Diagram: local CLI → HTTP service → cloud storage
38
+
39
+ ## P1: Configuration Management
40
+
41
+ ### Project Config File (`.dorkyrc`)
42
+ - [ ] TOML or YAML format
43
+ - [ ] Store bucket URL, credentials, compression settings
44
+ - [ ] Support environment variable overrides
45
+ - [ ] Example `.dorkyrc.example` in repo
46
+
47
+ ### User Configuration
48
+ - [ ] Support `~/.dorky/config` for user defaults
49
+ - [ ] Support `~/.dorky/credentials` for secrets
50
+ - [ ] Add `dorky config set <key> <value>` command
51
+ - [ ] Add `dorky config get <key>` command
52
+ - [ ] Add `dorky config list` command
53
+
54
+ ### Environment Variables
55
+ - [ ] `DORKY_URL` — service base URL
56
+ - [ ] `DORKY_BUCKET_URL` — cloud bucket URL
57
+ - [ ] `DORKY_ACCESS_KEY` — cloud credentials
58
+ - [ ] `DORKY_SECRET_KEY` — cloud credentials
59
+ - [ ] `DORKY_COMPRESS` — default compression type
60
+ - [ ] Document all variables in README
61
+
62
+ ### Init Command
63
+ - [ ] `dorky init` — interactive setup wizard
64
+ - [ ] Detect cloud provider from credentials
65
+ - [ ] Create `.dorkyrc` with initial config
66
+ - [ ] Test bucket connection
67
+ - [ ] Offer to add `.dorkyrc` to `.gitignore`
68
+
69
+ ## P1: Testing & CI
70
+
71
+ ### Unit Tests
72
+ - [ ] Test upload/download logic
73
+ - [ ] Test compression/decompression
74
+ - [ ] Test metadata operations
75
+ - [ ] Test error handling and retries
76
+ - [ ] Target 80%+ code coverage
77
+
78
+ ### Integration Tests
79
+ - [ ] Test against local HTTP server
80
+ - [ ] Test all storage backends (S3, GCS, local)
81
+ - [ ] Test CLI commands end-to-end
82
+ - [ ] Test compression options
83
+ - [ ] Test various file sizes (small, large, >1GB)
84
+
85
+ ### E2E Tests
86
+ - [ ] Test full workflow: init → stage → commit → push → pull
87
+ - [ ] Test multi-file operations
88
+ - [ ] Test concurrent uploads
89
+ - [ ] Test error recovery (network interruption, etc.)
90
+
91
+ ### Test Infrastructure
92
+ - [ ] Use Jest for Node tests
93
+ - [ ] Use pytest for Python tests
94
+ - [ ] Use Docker for consistent test environment
95
+ - [ ] Add CI workflows (GitHub Actions)
96
+ - [ ] Run tests on Node 16 + 20
97
+ - [ ] Run Python tests on 3.8, 3.9, 3.10, 3.11
98
+
99
+ ### CI Workflows
100
+ - [ ] Lint (ESLint for Node, pylint/black for Python)
101
+ - [ ] Type check (TypeScript, mypy)
102
+ - [ ] Unit tests on every PR
103
+ - [ ] Integration tests on main branch
104
+ - [ ] E2E tests before release
105
+
106
+ ## P2: Error Handling & Diagnostics
107
+
108
+ ### Error Messages
109
+ - [ ] Clear, actionable error messages
110
+ - [ ] Suggest fixes when possible
111
+ - [ ] Include error codes (e.g., `E001: Invalid bucket URL`)
112
+ - [ ] Don't expose internal stack traces to users
113
+
114
+ ### Verbose Mode
115
+ - [ ] `--verbose` / `-v` flag for detailed output
116
+ - [ ] Log all HTTP requests/responses
117
+ - [ ] Show timing information
118
+ - [ ] Include diagnostics (network, disk, permissions)
119
+
120
+ ### Debug Mode
121
+ - [ ] `--debug` flag for maximum verbosity
122
+ - [ ] Dump request/response bodies
123
+ - [ ] Show internal state
124
+ - [ ] Enable profiling
125
+
126
+ ### Logging
127
+ - [ ] Structured logging (JSON format option)
128
+ - [ ] Log to file: `~/.dorky/logs/`
129
+ - [ ] Log rotation (keep last 10 files)
130
+ - [ ] Log level configuration (info, debug, trace)
131
+
132
+ ### Diagnostics Command
133
+ - [ ] `dorky diagnose` — check system health
134
+ - [ ] Verify bucket connectivity
135
+ - [ ] Check permissions
136
+ - [ ] Verify file system space
137
+ - [ ] Test network speed
138
+ - [ ] Report diagnostics bundle for issue reporting
139
+
140
+ ## P2: IDE Integration
141
+
142
+ ### VS Code Extension
143
+ - [ ] Create VS Code extension for Dorky
144
+ - [ ] File explorer integration
145
+ - [ ] Show sync status icon
146
+ - [ ] Quick actions: upload file, download artifact
147
+ - [ ] Status bar: connection status, last sync time
148
+
149
+ ### Editor Integration
150
+ - [ ] Context menu: "Upload to Dorky", "Sync with Dorky"
151
+ - [ ] Sync status in file decorations (✓, !, ↑, ↓)
152
+ - [ ] Preview artifact metadata
153
+ - [ ] Show file history (versions)
154
+
155
+ ## P3: Advanced Developer Tools
156
+
157
+ ### GitHub Integration
158
+ - [ ] GitHub Action: Upload artifacts from CI/CD
159
+ - [ ] GitHub Action: Download artifacts from Dorky
160
+ - [ ] Example workflows in `docs/examples/`
161
+
162
+ ### SDK & Libraries
163
+ - [ ] TypeScript SDK with full type definitions
164
+ - [ ] Python SDK with type hints (mypy compatible)
165
+ - [ ] Generate SDKs from OpenAPI spec
166
+
167
+ ### API Playground
168
+ - [ ] Interactive API explorer (Swagger UI)
169
+ - [ ] Example code generation (cURL, Python, Node, etc.)
170
+ - [ ] Request/response history
171
+
172
+ ---
173
+
174
+ **Status**: Documentation started, config/testing/diagnostics pending
175
+ **Next**: Update README with architecture, create `.dorkyrc` support, add unit/integration tests
package/todo/README.md ADDED
@@ -0,0 +1,37 @@
1
+ # Pydorky Feature Implementation Roadmap
2
+
3
+ This folder tracks features to implement, organized by priority and category.
4
+ Each file represents a feature area with actionable tasks.
5
+
6
+ ## Priority Legend
7
+ - **P0**: Critical / blocking other work
8
+ - **P1**: High priority / near-term
9
+ - **P2**: Medium priority / planned
10
+ - **P3**: Nice-to-have / backlog
11
+
12
+ ## Status Legend
13
+ - [ ] Not started
14
+ - [~] In progress
15
+ - [x] Completed
16
+
17
+ ## Feature Areas
18
+ 1. **Core Infrastructure** — HTTP service, CLI foundation, Node version alignment
19
+ 2. **Storage Providers** — Cloud integrations (S3, GCS, Azure), BYOB support
20
+ 3. **Compression & Formats** — gzip, lz4, brotli, Parquet conversions
21
+ 4. **Python Client** — PyPI package, async/sync clients, CLI parity
22
+ 5. **Metadata & Versioning** — Artifact versioning, conflict detection, time travel
23
+ 6. **Performance & Concurrency** — Parallel uploads, streaming, incremental updates
24
+ 7. **Security & Encryption** — Client-side encryption, KMS integration
25
+ 8. **Developer Experience** — Docs, config, testing, error handling
26
+
27
+ ## Key Milestones
28
+ - [ ] Phase 1: Core HTTP service + Node CLI (P0)
29
+ - [ ] Phase 2: Python client + storage providers (P0-P1)
30
+ - [ ] Phase 3: Compression + metadata versioning (P1-P2)
31
+ - [ ] Phase 4: Performance optimization (P2)
32
+ - [ ] Phase 5: Security & encryption (P2-P3)
33
+
34
+ ---
35
+
36
+ **Last Updated**: 2025-12-28
37
+ **Status**: Roadmap created, ready for implementation
@@ -0,0 +1,70 @@
1
+ # Getting Started with Create React App
2
+
3
+ This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
4
+
5
+ ## Available Scripts
6
+
7
+ In the project directory, you can run:
8
+
9
+ ### `npm start`
10
+
11
+ Runs the app in the development mode.\
12
+ Open [http://localhost:3000](http://localhost:3000) to view it in your browser.
13
+
14
+ The page will reload when you make changes.\
15
+ You may also see any lint errors in the console.
16
+
17
+ ### `npm test`
18
+
19
+ Launches the test runner in the interactive watch mode.\
20
+ See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
21
+
22
+ ### `npm run build`
23
+
24
+ Builds the app for production to the `build` folder.\
25
+ It correctly bundles React in production mode and optimizes the build for the best performance.
26
+
27
+ The build is minified and the filenames include the hashes.\
28
+ Your app is ready to be deployed!
29
+
30
+ See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.
31
+
32
+ ### `npm run eject`
33
+
34
+ **Note: this is a one-way operation. Once you `eject`, you can't go back!**
35
+
36
+ If you aren't satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
37
+
38
+ Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you're on your own.
39
+
40
+ You don't have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn't feel obligated to use this feature. However we understand that this tool wouldn't be useful if you couldn't customize it when you are ready for it.
41
+
42
+ ## Learn More
43
+
44
+ You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
45
+
46
+ To learn React, check out the [React documentation](https://reactjs.org/).
47
+
48
+ ### Code Splitting
49
+
50
+ This section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting)
51
+
52
+ ### Analyzing the Bundle Size
53
+
54
+ This section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size)
55
+
56
+ ### Making a Progressive Web App
57
+
58
+ This section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app)
59
+
60
+ ### Advanced Configuration
61
+
62
+ This section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration)
63
+
64
+ ### Deployment
65
+
66
+ This section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment)
67
+
68
+ ### `npm run build` fails to minify
69
+
70
+ This section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify)