Commit graph

46 commits

Author SHA1 Message Date
581ffff661 run docker as a service 2025-05-22 14:16:16 -04:00
8fc00ab762 Merge branch 'develop' of git.gay:pupsie/vrcauthproxy into develop 2025-05-22 14:12:24 -04:00
ce4679b9f8 move around c/i and add publish script 2025-05-22 14:11:52 -04:00
MiscFrizzy
6da03c2920 refactor: setup a docs directory for different readme's 2025-05-22 14:06:01 -04:00
MiscFrizzy
032a0f17f6 Updates LICENSE for active mainter org 2025-05-22 14:04:07 -04:00
dotfrizzy
fadc13b6e6
Merge pull request 'feat/redis-session-store' (#2) from feat/redis-session-store into develop
Reviewed-on: https://git.gay/Pupsie/VRCAuthProxy/pulls/2
2025-05-20 22:12:00 +02:00
Cyan Kneelawk
312e94aaf3
Log whether cookies could be reused 2025-04-28 13:35:26 -07:00
Cyan Kneelawk
972493ace8
Update docker dotnet to 9.0 to match csproj 2025-04-25 16:48:53 -07:00
MiscFrizzy
cb8718c9b8 feat(build): builds develop branch to latest docker tag in workflow 2025-04-07 16:48:17 -04:00
MiscFrizzy
4936481ffc ### Commit Message Summary
**Enhancements to Redis Integration and Testing**

- **RedisService.cs**:
  - Implemented a Redis service for storing and retrieving authentication tokens.
  - Added methods for saving, retrieving, and removing tokens using Redis.
  - Introduced a constructor for dependency injection to facilitate testing.

- **RedisFixture.cs**:
  - Created a test fixture to ensure a Redis instance is available for integration tests.
  - Implemented a check to verify if Redis is running before executing tests.

- **ProgramRedisIntegrationTests.cs**:
  - Added integration tests to validate the login process and token storage in Redis.
  - Implemented tests to check the reuse of stored tokens and the correct handling of authentication.

- **RedisIntegrationTests.cs**:
  - Developed integration tests for saving, retrieving, and deleting authentication tokens in Redis.
  - Ensured that all tokens are correctly stored and can be retrieved as expected.

- **RedisServiceTests.cs**:
  - Created unit tests using an in-memory implementation of the Redis service for isolated testing.
  - Validated the functionality of saving, retrieving, and removing tokens without a real Redis connection.

### Notes
- All tests are designed to ensure the reliability of the Redis integration and the overall functionality of the VRCAuthProxy service.
- Integration tests are marked to skip execution unless a Redis instance is available.
2025-04-07 08:04:52 -04:00
MiscFrizzy
30d631d246 feat: An Initias Redis Store Implementation
- **docker-compose.yml**
  - Added Redis service configuration to support token storage.
  - Set up health checks and volume for Redis persistence.
  - Configured VRCAuthProxy service to depend on Redis.

- **HttpClientCookieContainer.cs**
  - Added `Username` property to support user-specific token management.

- **Program.cs**
  - Integrated Redis for storing and retrieving authentication tokens.
  - Updated login and token rotation logic to utilize Redis.
  - Improved async/await usage for better reliability.

- **VRCAuthProxy.csproj**
  - Added `StackExchange.Redis` package for Redis connectivity.
  - Corrected `Otp.NET` package reference.

- **API.cs**
  - Updated `TotpVerifyResponse` and `User` classes to be nullable-aware.

- **RedisService.cs**
  - Implemented Redis service for managing authentication tokens.
  - Added methods for saving, retrieving, and deleting tokens.
2025-04-07 07:47:27 -04:00
MiscFrizzy
eb4349031b ### Commit Summary
- **TestSetup.cs**
  - Updated `CreateTestConfig` method to initialize `Config` with required properties using object initializer syntax.

- **ProxyIntegrationTests.cs**
  - Added null checks for `mockServer.Urls` before accessing it to prevent potential null reference exceptions.
  - Improved error handling for mock server URL access.

- **VRChatAuthenticationTests.cs**
  - Added null checks for `mockServer.Urls` before accessing it to prevent potential null reference exceptions.
  - Enhanced the mock server setup to include null checks for request body content.

- **Config.cs**
  - Added the `required` modifier to non-nullable properties in `ConfigAccount` and `iConfig` classes.
  - Updated the `Load` method to initialize the `Config` instance with required properties using object initializer syntax.

- **Program.cs**
  - Added a null check for `result.CloseStatus` in WebSocket handling to prevent potential null reference exceptions.
2025-04-07 07:30:34 -04:00
MiscFrizzy
861bedcf43 feat(ci): Add support for version tagging in Docker build workflow
- Updated the build workflow to trigger on version tags (e.g., v1.0.0) pushed to the main branch.
- Configured the Docker image to be tagged with the version and pushed to the GitHub Container Registry.
- Ensured that the workflow continues to build on pushes to the develop branch and supports manual triggering.
2025-04-07 07:06:15 -04:00
MiscFrizzy
6ea5de613c
Update README.md
grrr this one badge
2025-04-07 06:57:17 -04:00
MiscFrizzy
fb46a1185e
Update README.md
formating syntax
2025-04-07 06:49:05 -04:00
MiscFrizzy
a5eb2cfe6b Fix forgot badge deets 2025-04-07 06:47:16 -04:00
MiscFrizzy
8fdc1523ab Updates dependencies badge 2025-04-07 06:44:48 -04:00
MiscFrizzy
24d0601168 feat(docs): Add badges for version, dependencies, and license to README.md
- Added a version badge to indicate the current version of the project.
- Included a dependencies badge to show the status of project dependencies.
- Added a license badge to clarify the licensing of the project.

chore(ci): Update test workflow to improve coverage reporting

- Updated the test.yml workflow to include coverage reporting using Codecov.
- Ensured that the workflow runs on pushes and pull requests to main and develop branches.
2025-04-07 06:38:22 -04:00
MiscFrizzy
319f1071bf feat(ci): Add GitHub Actions workflows for test automation and status badges
Add comprehensive test automation setup with GitHub Actions:
- Create test.yml for running tests on main/develop branches
- Add pr-test.yml for PR validation with test results comments
- Add update-badges.yml for dynamic test status badge updates
- Configure code coverage reporting with Codecov integration

Documentation:
- Add BADGE_SETUP.md with instructions for configuring test status badges
- Add WORKFLOWS_GUIDE.md explaining CI/CD workflow setup
- Update README.md with build and test status badges

Test Framework:
- Configure test project to use .NET 9.0
- Set up test coverage reporting with coverlet
- Add integration tests with WireMock for API mocking
- Add unit tests for configuration and HTTP client components
- Document testing strategy in TestingStrategy.md

Build:
- Add Dockerfile.test for containerized testing
- Update .gitignore for test artifacts
- Configure test dependencies in VRCAuthProxy.Tests.csproj

This change enables automated testing on PRs and branches, with visual status indicators and detailed test results in PR comments.
2025-04-07 06:30:31 -04:00
MiscFrizzy
23b5a504b5 readme footer formatting pt 2, im blind it seems 2025-03-27 20:44:03 -04:00
MiscFrizzy
26c4afa0b5 readme formating 2025-03-27 20:42:48 -04:00
MiscFrizzy
3b7cb9faeb Adds contributors section to readme 2025-03-27 20:41:57 -04:00
MiscFrizzy
9578f95227 Small licences adendum addition, updates readme with upcoming features list 2025-03-27 16:51:53 -04:00
MiscFrizzy
a11cb9e2e8 README Docs Updates 2025-03-27 05:28:25 -04:00
MiscFrizzy
8fbfa79690 README doc updates 2025-03-27 04:25:18 -04:00
MiscFrizzy
801954d7e7 Adds VRC related license addendum 2025-03-27 03:10:40 -04:00
MiscFrizzy
46f894ff46 Preparing for 1.0/public release
- Adds initial README
- Adds MPL 2.0 License
- Cleans up old files
2025-03-27 02:05:54 -04:00
23371e7fee
add curl to container 2025-02-26 13:15:18 -05:00
7152c90d96 pridevrcommunity > pridevrinc 2025-02-22 12:56:26 -05:00
9a409bcab0 if rotating account does not work, re login 2025-02-22 12:54:55 -05:00
aefed18612 add account rotating on 401 and 429 2025-01-11 20:49:48 -05:00
93d3cae034 no way it was that simple. 2025-01-10 14:45:36 -05:00
3b31613bf8 forgot to revert dockerfile as well 2025-01-10 14:38:46 -05:00
cb8b4b5f0c revert all that because somehow it fixes it???? 2025-01-10 14:37:00 -05:00
266dc9232e different constructor for the HttpRequestMessage? 2025-01-10 14:25:53 -05:00
c98a16439f fix ssl error? 2025-01-10 14:18:23 -05:00
03628aa2e5 dont add content headers if there is no contemnt 2025-01-10 13:57:11 -05:00
dc9dc182c9 forgot i changed dockerfile path 2025-01-10 13:52:27 -05:00
255b273f65 feat: support websockets 2024-12-22 19:22:15 -05:00
5e19348a11 remove dependency on VRChat.API 2024-12-14 11:35:37 -05:00
db4c283210 move dockerfile to correct spot 2024-12-13 13:13:24 -05:00
d3d92332a0 proxy user agent 2024-12-10 18:04:50 -05:00
21a9fca745 use asp.net in dockerfile 2024-11-11 14:26:16 -05:00
1edb1dc835 mispelled vrcauthproxy 2024-11-11 14:22:32 -05:00
d39b5528ef fix build.ymlll 2024-11-11 14:19:30 -05:00
22c2de9cc6 Initial Commit 2024-11-11 14:15:51 -05:00