From a018c0bb4143d4dc548c3ec10ec6327470a748b6 Mon Sep 17 00:00:00 2001 From: Daniel Sincere <103295874+DanielSincere@users.noreply.github.com> Date: Tue, 15 Oct 2024 09:02:12 -0400 Subject: [PATCH] Rename (#17) --- .env.development.sample | 2 +- .env.testing.sample | 2 +- .github/workflows/CI.yml | 9 +++--- Deploy/Fly.io/Dockerfile | 2 +- Deploy/Fly.io/README.md | 4 +-- Deploy/Heroku/Dockerfile | 2 +- Deploy/Heroku/README.md | 8 ++--- ...espace.yml => 0-sincereauth-namespace.yml} | 4 +-- ...e.yml => 1-sincereauth-secrets.sample.yml} | 8 ++--- ...auth-redis.yml => 2-sincereauth-redis.yml} | 14 ++++----- ...-release.yml => 3-sincereauth-release.yml} | 26 ++++++++-------- ...yml => 4-sincereauth-scheduled-queues.yml} | 30 +++++++++---------- ...ed-queues.yml => 5-sincereauth-queues.yml} | 30 +++++++++---------- ...6-fqauth-app.yml => 6-sincereauth-app.yml} | 30 +++++++++---------- ...-service.yml => 7-sincereauth-service.yml} | 6 ++-- Deploy/Kubernetes/README.md | 8 ++--- Deploy/README.md | 4 +-- Dockerfile | 10 +++---- Documentation/svg/architecture.svg | 8 ++--- Documentation/svg/flow-microservice.svg | 4 +-- Documentation/svg/flow-refresh-apple-ids.svg | 8 ++--- Documentation/svg/flow-refresh-token.svg | 6 ++-- Documentation/svg/flow-signin.svg | 6 ++-- Documentation/svg/flow-signup.svg | 6 ++-- Package.resolved | 24 +++++++-------- Package.swift | 18 +++++------ README.md | 16 +++++----- .../local-postgres/LocalPostgres.config.swift | 6 ++-- .../SIWAController.authorize.swift | 0 .../SIWAController.notify.swift | 0 .../SignInWithApple/SIWAController.swift | 0 .../Apple/SignInWithApple/SIWAModel.swift | 0 .../client/AppleAuthTokenResult.swift | 0 .../SignInWithApple/client/SIWAClient.swift | 0 .../client/SIWAClientSecret.swift | 0 .../client/Services.siwaClient.swift | 0 .../jobs/ConsentRevokedJob.swift | 0 .../jobs/EmailDisabledJob.swift | 0 .../jobs/EmailEnabledJob.swift | 0 .../EnqueueRefreshTokenJobsScheduledJob.swift | 0 .../jobs/RefreshTokenJob.swift | 0 .../jobs/SIWAAccountDeletedJob.swift | 0 .../json/AppleAuthTokenBody.swift | 0 .../json/AppleErrorResponse.swift | 0 .../SignInWithApple/json/AppleJsonBool.swift | 0 .../json/AppleJsonString.swift | 0 .../json/AppleSingleOrArray.swift | 0 .../json/AppleTokenRefreshResponse.swift | 0 .../json/AppleTokenResponse.swift | 0 .../json/SIWAServerNotification.swift | 0 .../jwt/LiveSIWAProvider.swift | 0 .../SignInWithApple/jwt/SIWAVerifier.swift | 0 .../jwt/Services.siwaVerifier.swift | 0 .../repo/SIWADeactivateRepo.swift | 0 .../repo/SIWAReadyForReverifyRepo.swift | 0 .../SignInWithApple/repo/SIWASignUpRepo.swift | 0 .../Auth/AuthConstant.swift | 0 .../Auth/AuthHelper.login.swift | 4 +-- .../Auth/AuthResponse.swift | 0 .../Auth/FQAuthSessionToken.init.swift | 4 +-- .../RefreshToken/RefreshTokenController.swift | 0 .../Auth/RefreshToken/RefreshTokenModel.swift | 0 .../RefreshTokenRequestBody.swift | 0 .../Auth/User/UserController.swift | 6 ++-- .../Auth/User/UserModel.findBy.swift | 0 .../Auth/User/UserModel.swift | 0 ...eanupExpiredRefreshTokenScheduledJob.swift | 0 .../Auth/db/DBSeal.swift | 0 .../Auth/jwt/JWK.authPublic.swift | 0 .../Auth/jwt/JWKS.public.swift | 0 .../Auth/jwt/JWKSController.swift | 0 .../Auth/jwt/JWTVerifying.swift | 0 .../Auth/jwt/ecdsa-keys.swift | 0 .../Auth/jwt/jwt-identifiers.swift | 0 .../Auth/jwt/jwt-signers.swift | 0 .../EnvVars.swift | 0 .../Main.swift | 0 .../configure/configure.swift | 0 .../configure/configureCommands.swift | 0 .../configure/configureMigrations.swift | 0 .../configure/configurePostgres.swift | 0 .../configure/configureQueues.swift | 0 .../configure/configureRedis.swift | 0 .../configure/configureRoutes.swift | 2 +- .../configure/configureServices.swift | 0 .../configure/configureSigning.swift | 0 .../migrations/AddRolesToUserMigration.swift | 0 .../migrations/CreateFunctionMigration.swift | 0 .../CreateRefreshTokenMigration.swift | 0 .../migrations/CreateSiwaMigration.swift | 0 .../migrations/CreateUserMigration.swift | 0 .../PostgresDatabase.exec.swift | 0 .../PostgresDatabase/PostgresMigration.swift | 0 .../PostgresScriptMigration.swift | 0 .../lib/Service/Application.Services.swift | 0 .../lib/Service/Request.Services.swift | 0 .../lib/Service/Service.swift | 0 .../web/Admin/-.listUsers.swift | 0 .../web/Admin/AdminWebController.swift | 4 +-- .../web/LoginController.swift | 0 .../.gitignore | 0 .../Apple/Fixtures.swift | 0 .../Apple/SIWAClientTests.swift | 2 +- .../Apple/SIWADeactivateUserRepoTests.swift | 2 +- .../Apple/SIWAModelTests.swift | 2 +- .../Apple/SIWAReadyForReverifyRepoTests.swift | 2 +- .../SIWAServerNotificationDecodingTests.swift | 20 ++++++------- .../SIWAServerNotificationEncodingTests.swift | 2 +- .../SIWAServerNotificationRequestTests.swift | 2 +- .../Apple/SIWASignInRequestTests.swift | 2 +- .../Apple/SIWASignUpRepoTests.swift | 2 +- .../Apple/SIWASignUpRequestTests.swift | 2 +- .../factories/AppleIdentityTokenFactory.swift | 0 .../Apple/factories/SIWAUser.swift | 2 +- .../Apple/fakes/FakeJWTSigners.swift | 2 +- .../Apple/fakes/FakeSIWAClient.swift | 6 ++-- .../Apple/fakes/FakeSIWAVerifier.swift | 4 +-- .../Apple/jobs/ConsentRevokedJobTest.swift | 2 +- .../Apple/jobs/EmailDisabledJobTest.swift | 2 +- .../Apple/jobs/EmailEnabledJobTest.swift | 2 +- .../jobs/SIWAAccountDeletedJobTest.swift | 2 +- ...SIWAReadyForReverifyScheduledJobTest.swift | 2 +- .../Apple/jobs/SIWARefreshTokenJobTest.swift | 2 +- .../AppleTokenResponse.meaninglessStub.swift | 2 +- .../CryptoTests.swift | 2 +- ...ExpiredRefreshTokenScheduledJobTests.swift | 2 +- .../RefreshTokenControllerTests.swift | 2 +- .../RefreshToken/RefreshTokenModelTests.swift | 2 +- .../RoutesTests.swift | 2 +- .../Services/DependencyInjectionTests.swift | 2 +- .../asserts/XCTAssertNearlyEqual.swift | 0 .../asserts/XCTAssertNearlyNow.swift | 0 .../helpers/Application.resetDatabase.swift | 2 +- .../helpers/Application.resetQueue.swift | 0 .../helpers/Queue.nextPayload.swift | 0 heroku.yml | 6 ++-- 136 files changed, 203 insertions(+), 204 deletions(-) rename Deploy/Kubernetes/{0-fqauth-namespace.yml => 0-sincereauth-namespace.yml} (54%) rename Deploy/Kubernetes/{1-fqauth-secrets.sample.yml => 1-sincereauth-secrets.sample.yml} (91%) rename Deploy/Kubernetes/{2-fqauth-redis.yml => 2-sincereauth-redis.yml} (70%) rename Deploy/Kubernetes/{3-fqauth-release.yml => 3-sincereauth-release.yml} (68%) rename Deploy/Kubernetes/{5-fqauth-queues.yml => 4-sincereauth-scheduled-queues.yml} (64%) rename Deploy/Kubernetes/{4-fqauth-scheduled-queues.yml => 5-sincereauth-queues.yml} (66%) rename Deploy/Kubernetes/{6-fqauth-app.yml => 6-sincereauth-app.yml} (70%) rename Deploy/Kubernetes/{7-fqauth-service.yml => 7-sincereauth-service.yml} (67%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/SIWAController.authorize.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/SIWAController.notify.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/SIWAController.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/SIWAModel.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/client/AppleAuthTokenResult.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/client/SIWAClient.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/client/SIWAClientSecret.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/client/Services.siwaClient.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jobs/ConsentRevokedJob.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jobs/EmailDisabledJob.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jobs/EmailEnabledJob.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jobs/EnqueueRefreshTokenJobsScheduledJob.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jobs/RefreshTokenJob.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jobs/SIWAAccountDeletedJob.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/AppleAuthTokenBody.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/AppleErrorResponse.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/AppleJsonBool.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/AppleJsonString.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/AppleSingleOrArray.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/AppleTokenRefreshResponse.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/AppleTokenResponse.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/json/SIWAServerNotification.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jwt/LiveSIWAProvider.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jwt/SIWAVerifier.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/jwt/Services.siwaVerifier.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/repo/SIWADeactivateRepo.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/repo/SIWAReadyForReverifyRepo.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Apple/SignInWithApple/repo/SIWASignUpRepo.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/AuthConstant.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/AuthHelper.login.swift (86%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/AuthResponse.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/FQAuthSessionToken.init.swift (84%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/RefreshToken/RefreshTokenController.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/RefreshToken/RefreshTokenModel.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/RefreshToken/RefreshTokenRequestBody.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/User/UserController.swift (84%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/User/UserModel.findBy.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/User/UserModel.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/db/CleanupExpiredRefreshTokenScheduledJob.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/db/DBSeal.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/jwt/JWK.authPublic.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/jwt/JWKS.public.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/jwt/JWKSController.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/jwt/JWTVerifying.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/jwt/ecdsa-keys.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/jwt/jwt-identifiers.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Auth/jwt/jwt-signers.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/EnvVars.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/Main.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configure.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configureCommands.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configureMigrations.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configurePostgres.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configureQueues.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configureRedis.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configureRoutes.swift (94%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configureServices.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/configureSigning.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/migrations/AddRolesToUserMigration.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/migrations/CreateFunctionMigration.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/migrations/CreateRefreshTokenMigration.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/migrations/CreateSiwaMigration.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/configure/migrations/CreateUserMigration.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/lib/PostgresDatabase/PostgresDatabase.exec.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/lib/PostgresDatabase/PostgresMigration.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/lib/PostgresDatabase/PostgresScriptMigration.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/lib/Service/Application.Services.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/lib/Service/Request.Services.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/lib/Service/Service.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/web/Admin/-.listUsers.swift (100%) rename Sources/{FQAuthServer => SincereAuthServer}/web/Admin/AdminWebController.swift (76%) rename Sources/{FQAuthServer => SincereAuthServer}/web/LoginController.swift (100%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/.gitignore (100%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/Fixtures.swift (100%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWAClientTests.swift (99%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWADeactivateUserRepoTests.swift (98%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWAModelTests.swift (96%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWAReadyForReverifyRepoTests.swift (99%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWAServerNotificationDecodingTests.swift (95%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWAServerNotificationEncodingTests.swift (97%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWAServerNotificationRequestTests.swift (99%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWASignInRequestTests.swift (98%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWASignUpRepoTests.swift (98%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/SIWASignUpRequestTests.swift (98%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/factories/AppleIdentityTokenFactory.swift (100%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/factories/SIWAUser.swift (93%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/fakes/FakeJWTSigners.swift (93%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/fakes/FakeSIWAClient.swift (84%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/fakes/FakeSIWAVerifier.swift (89%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/jobs/ConsentRevokedJobTest.swift (97%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/jobs/EmailDisabledJobTest.swift (97%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/jobs/EmailEnabledJobTest.swift (96%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/jobs/SIWAAccountDeletedJobTest.swift (97%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/jobs/SIWAReadyForReverifyScheduledJobTest.swift (98%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/jobs/SIWARefreshTokenJobTest.swift (99%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Apple/stubs/AppleTokenResponse.meaninglessStub.swift (91%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/CryptoTests.swift (89%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/RefreshToken/CleanupExpiredRefreshTokenScheduledJobTests.swift (98%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/RefreshToken/RefreshTokenControllerTests.swift (98%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/RefreshToken/RefreshTokenModelTests.swift (96%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/RoutesTests.swift (89%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/Services/DependencyInjectionTests.swift (89%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/asserts/XCTAssertNearlyEqual.swift (100%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/asserts/XCTAssertNearlyNow.swift (100%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/helpers/Application.resetDatabase.swift (94%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/helpers/Application.resetQueue.swift (100%) rename Tests/{FQAuthServerTests => SincereAuthServerTests}/helpers/Queue.nextPayload.swift (100%) diff --git a/.env.development.sample b/.env.development.sample index 00de8e2..c33a0ed 100644 --- a/.env.development.sample +++ b/.env.development.sample @@ -1,4 +1,4 @@ -DATABASE_URL=postgres://fqauth:FQAuthServer@localhost/fqauth_dev +DATABASE_URL=postgres://sincereauth:SincereAuthServer@localhost/sincereauth_dev REDIS_URL=redis://localhost APPLE_SERVICES_KEY=com.fullqueuedeveloper.FQAuthServer APPLE_SERVICES_KEY_ID=com.fullqueuedeveloper.FQAuthServer diff --git a/.env.testing.sample b/.env.testing.sample index cd212f5..ebd4f4a 100644 --- a/.env.testing.sample +++ b/.env.testing.sample @@ -1,5 +1,5 @@ DB_SYMMETRIC_KEY=9/Vk5Rlzctc5tyX0SCmIJaRzEg+QgwWjlTzD0LMPqNY= -DATABASE_URL=postgres://fqauth:FQAuthServer@localhost/fqauth_test +DATABASE_URL=postgres://sincereauth:SincereAuthServer@localhost/sincereauth_test REDIS_URL=redis://localhost APPLE_SERVICES_KEY_ID=com.fullqueuedeveloper.FQAuthServer APPLE_TEAM_ID=FQDV1234 diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index cd434eb..fd4995b 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -108,7 +108,7 @@ jobs: build-mac: name: Build on Mac - runs-on: macos-12 + runs-on: macos-13 steps: - uses: swift-actions/setup-swift@v1 with: @@ -154,14 +154,15 @@ jobs: swift-version: 5.9 - run: swift --version - uses: actions/checkout@v3 - - run: swift run FQAuthServer migrate -y --env test + - run: swift run SincereAuthServer migrate -y --env test - run: swift test test-mac: name: Test on Mac - runs-on: macos-12 + runs-on: macos-13 steps: - run: | + brew install postgresql brew services start postgresql echo "Check PostgreSQL service is running" i=10 @@ -191,7 +192,7 @@ jobs: - run: swift --version - uses: shogo82148/actions-setup-redis@v1 - uses: actions/checkout@v3 - - run: swift run FQAuthServer migrate -y --env test + - run: swift run SincereAuthServer migrate -y --env test - run: swift test env: DATABASE_URL: "postgresql://myuser:mypassword@localhost/mydatabase" diff --git a/Deploy/Fly.io/Dockerfile b/Deploy/Fly.io/Dockerfile index ac972ec..307b12f 100644 --- a/Deploy/Fly.io/Dockerfile +++ b/Deploy/Fly.io/Dockerfile @@ -1 +1 @@ -FROM ghcr.io/fullqueuedeveloper/fqauth:0.2.3 \ No newline at end of file +FROM ghcr.io/fullqueuedeveloper/sincereauth:0.2.3 \ No newline at end of file diff --git a/Deploy/Fly.io/README.md b/Deploy/Fly.io/README.md index 77ff4a3..5c86de9 100644 --- a/Deploy/Fly.io/README.md +++ b/Deploy/Fly.io/README.md @@ -5,9 +5,9 @@ 1. Provision a Postgres database 2. Provision a Redis instance -## Setup FQAuth +## Setup SincereAuth -1. Clone the FQAuth repo. +1. Clone the SincereAuth repo. 2. Set environment variables using `flyctl secrets set MY_SECRET=value` - `AUTH_PRIVATE_KEY`: Base64. Output of `swish generate-jwt-key` diff --git a/Deploy/Heroku/Dockerfile b/Deploy/Heroku/Dockerfile index bc53f87..6309ce1 100644 --- a/Deploy/Heroku/Dockerfile +++ b/Deploy/Heroku/Dockerfile @@ -1 +1 @@ -FROM ghcr.io/fullqueuedeveloper/fqauth:0.2.3 +FROM ghcr.io/fullqueuedeveloper/sincereauth:0.2.3 diff --git a/Deploy/Heroku/README.md b/Deploy/Heroku/README.md index 6e318d9..d0b2e6e 100644 --- a/Deploy/Heroku/README.md +++ b/Deploy/Heroku/README.md @@ -7,7 +7,7 @@ Install heroku cli tool from Homebrew ## Setup. 1. Create a Heroku account -2. Create an app on Heroku, perhaps named "fqauth-server-{name}" +2. Create an app on Heroku, perhaps named "sincereauth-server-{name}" 3. Provision this app with a Postgres DB and a Redis DB 4. Set config variables in Heroku's web portal or thru the command line @@ -23,9 +23,9 @@ Install heroku cli tool from Homebrew - `RUN_QUEUES_IN_MAIN_PROCESS` - When limited in number of process, you may run the queues in-process by setting this variable to `YES`. If you can only run one extra process, prioritize the regular queues variable (this one). - `RUN_AUTO_MIGRATE` - When limited in number of process, you may run the database in-process by setting this variable to `YES`. This is only safe when you are only running 1 replica of the main app process. -5. Clone the FQAuth repo to your local computer -6. Choose container stack `heroku stack:set -a fqauth-server-{name} container` (app name is from step 2) -7. Setup heroku remote `heroku git:remote -a fqauth-server-{name}` +5. Clone the SincereAuth repo to your local computer +6. Choose container stack `heroku stack:set -a sincereauth-server-{name} container` (app name is from step 2) +7. Setup heroku remote `heroku git:remote -a sincereauth-server-{name}` 8. Push to heroku `git push heroku trunk:main` 9. After you login the first time, you may manually add the admin role to your user in the database, as that's not supported yet in the UI. diff --git a/Deploy/Kubernetes/0-fqauth-namespace.yml b/Deploy/Kubernetes/0-sincereauth-namespace.yml similarity index 54% rename from Deploy/Kubernetes/0-fqauth-namespace.yml rename to Deploy/Kubernetes/0-sincereauth-namespace.yml index 65dfa36..23c9808 100644 --- a/Deploy/Kubernetes/0-fqauth-namespace.yml +++ b/Deploy/Kubernetes/0-sincereauth-namespace.yml @@ -1,6 +1,6 @@ apiVersion: v1 kind: Namespace metadata: - name: fqauth + name: sincereauth labels: - name: fqauth + name: sincereauth diff --git a/Deploy/Kubernetes/1-fqauth-secrets.sample.yml b/Deploy/Kubernetes/1-sincereauth-secrets.sample.yml similarity index 91% rename from Deploy/Kubernetes/1-fqauth-secrets.sample.yml rename to Deploy/Kubernetes/1-sincereauth-secrets.sample.yml index ce5a486..b1d50c7 100644 --- a/Deploy/Kubernetes/1-fqauth-secrets.sample.yml +++ b/Deploy/Kubernetes/1-sincereauth-secrets.sample.yml @@ -1,13 +1,13 @@ apiVersion: v1 kind: Secret metadata: - name: fqauth.secrets - namespace: fqauth + name: sincereauth.secrets + namespace: sincereauth type: Opaque stringData: # from your hosting provider - DATABASE_URL: postgres://postgres/fqauth_prod - REDIS_URL: redis://fqauth_redis + DATABASE_URL: postgres://postgres/sincereauth_prod + REDIS_URL: redis://sincereauth_redis # spx generate-db-key DB_SYMMETRIC_KEY: 8MwwngvgA/fJhxBqY7CP3rWYPG1qDAJUZIHOvFQIZ5E= diff --git a/Deploy/Kubernetes/2-fqauth-redis.yml b/Deploy/Kubernetes/2-sincereauth-redis.yml similarity index 70% rename from Deploy/Kubernetes/2-fqauth-redis.yml rename to Deploy/Kubernetes/2-sincereauth-redis.yml index a687356..7ed3d3e 100644 --- a/Deploy/Kubernetes/2-fqauth-redis.yml +++ b/Deploy/Kubernetes/2-sincereauth-redis.yml @@ -1,8 +1,8 @@ apiVersion: v1 kind: Service metadata: - name: fqauth-redis - namespace: fqauth + name: sincereauth-redis + namespace: sincereauth spec: ports: - name: redis @@ -10,22 +10,22 @@ spec: targetPort: 6379 protocol: TCP selector: - app: fqauth-redis + app: sincereauth-redis --- apiVersion: v1 kind: ReplicationController metadata: - name: fqauth-redis - namespace: fqauth + name: sincereauth-redis + namespace: sincereauth spec: replicas: 1 template: metadata: labels: - app: fqauth-redis + app: sincereauth-redis spec: containers: - - name: fqauth-redis + - name: sincereauth-redis image: redis:alpine ports: - containerPort: 6379 diff --git a/Deploy/Kubernetes/3-fqauth-release.yml b/Deploy/Kubernetes/3-sincereauth-release.yml similarity index 68% rename from Deploy/Kubernetes/3-fqauth-release.yml rename to Deploy/Kubernetes/3-sincereauth-release.yml index 72975b0..a286d78 100644 --- a/Deploy/Kubernetes/3-fqauth-release.yml +++ b/Deploy/Kubernetes/3-sincereauth-release.yml @@ -1,55 +1,55 @@ apiVersion: batch/v1 kind: Job metadata: - name: fqauth-release-0-2-3 - namespace: fqauth + name: sincereauth-release-0-2-3 + namespace: sincereauth labels: - app: fqauth-release-0-2-3 + app: sincereauth-release-0-2-3 spec: template: spec: restartPolicy: Never containers: - - name: fqauth-release - image: ghcr.io/fullqueuedeveloper/fqauth-release:0.2.3 + - name: sincereauth-release + image: ghcr.io/fullqueuedeveloper/sincereauth-release:0.2.3 env: - name: DATABASE_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DATABASE_URL - name: REDIS_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: REDIS_URL - name: AUTH_PRIVATE_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: AUTH_PRIVATE_KEY - name: APPLE_SERVICES_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY - name: APPLE_SERVICES_KEY_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY_ID - name: APPLE_TEAM_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_TEAM_ID - name: APPLE_APP_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_APP_ID - name: DB_SYMMETRIC_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DB_SYMMETRIC_KEY diff --git a/Deploy/Kubernetes/5-fqauth-queues.yml b/Deploy/Kubernetes/4-sincereauth-scheduled-queues.yml similarity index 64% rename from Deploy/Kubernetes/5-fqauth-queues.yml rename to Deploy/Kubernetes/4-sincereauth-scheduled-queues.yml index 3c3576a..b6a5751 100644 --- a/Deploy/Kubernetes/5-fqauth-queues.yml +++ b/Deploy/Kubernetes/4-sincereauth-scheduled-queues.yml @@ -1,61 +1,61 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: fqauth-queues-deployment - namespace: fqauth + name: sincereauth-scheduled-queues-deployment + namespace: sincereauth labels: - app: fqauth-queues + app: sincereauth-scheduled-queues spec: replicas: 1 selector: matchLabels: - app: fqauth-queues + app: sincereauth-scheduled-queues template: metadata: labels: - app: fqauth-queues + app: sincereauth-scheduled-queues spec: containers: - - name: fqauth-queues - image: ghcr.io/fullqueuedeveloper/fqauth-queues:0.2.3 + - name: sincereauth-scheduled-queues + image: ghcr.io/fullqueuedeveloper/sincereauth-scheduled-queues:0.2.3 env: - name: DATABASE_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DATABASE_URL - name: REDIS_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: REDIS_URL - name: AUTH_PRIVATE_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: AUTH_PRIVATE_KEY - name: APPLE_SERVICES_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY - name: APPLE_SERVICES_KEY_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY_ID - name: APPLE_TEAM_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_TEAM_ID - name: APPLE_APP_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_APP_ID - name: DB_SYMMETRIC_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DB_SYMMETRIC_KEY diff --git a/Deploy/Kubernetes/4-fqauth-scheduled-queues.yml b/Deploy/Kubernetes/5-sincereauth-queues.yml similarity index 66% rename from Deploy/Kubernetes/4-fqauth-scheduled-queues.yml rename to Deploy/Kubernetes/5-sincereauth-queues.yml index 9c8fed5..6723115 100644 --- a/Deploy/Kubernetes/4-fqauth-scheduled-queues.yml +++ b/Deploy/Kubernetes/5-sincereauth-queues.yml @@ -1,61 +1,61 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: fqauth-scheduled-queues-deployment - namespace: fqauth + name: sincereauth-queues-deployment + namespace: sincereauth labels: - app: fqauth-scheduled-queues + app: sincereauth-queues spec: replicas: 1 selector: matchLabels: - app: fqauth-scheduled-queues + app: sincereauth-queues template: metadata: labels: - app: fqauth-scheduled-queues + app: sincereauth-queues spec: containers: - - name: fqauth-scheduled-queues - image: ghcr.io/fullqueuedeveloper/fqauth-scheduled-queues:0.2.3 + - name: sincereauth-queues + image: ghcr.io/fullqueuedeveloper/sincereauth-queues:0.2.3 env: - name: DATABASE_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DATABASE_URL - name: REDIS_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: REDIS_URL - name: AUTH_PRIVATE_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: AUTH_PRIVATE_KEY - name: APPLE_SERVICES_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY - name: APPLE_SERVICES_KEY_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY_ID - name: APPLE_TEAM_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_TEAM_ID - name: APPLE_APP_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_APP_ID - name: DB_SYMMETRIC_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DB_SYMMETRIC_KEY diff --git a/Deploy/Kubernetes/6-fqauth-app.yml b/Deploy/Kubernetes/6-sincereauth-app.yml similarity index 70% rename from Deploy/Kubernetes/6-fqauth-app.yml rename to Deploy/Kubernetes/6-sincereauth-app.yml index 0328d62..a7d6883 100644 --- a/Deploy/Kubernetes/6-fqauth-app.yml +++ b/Deploy/Kubernetes/6-sincereauth-app.yml @@ -1,23 +1,23 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: fqauth-app-deployment - namespace: fqauth + name: sincereauth-app-deployment + namespace: sincereauth labels: - app: fqauth-app + app: sincereauth-app spec: replicas: 1 selector: matchLabels: - app: fqauth-app + app: sincereauth-app template: metadata: labels: - app: fqauth-app + app: sincereauth-app spec: containers: - - name: fqauth-app - image: ghcr.io/fullqueuedeveloper/fqauth:0.2.3 + - name: sincereauth-app + image: ghcr.io/fullqueuedeveloper/sincereauth:0.2.3 livenessProbe: httpGet: path: /healthy @@ -28,40 +28,40 @@ spec: - name: DATABASE_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DATABASE_URL - name: REDIS_URL valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: REDIS_URL - name: AUTH_PRIVATE_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: AUTH_PRIVATE_KEY - name: APPLE_SERVICES_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY - name: APPLE_SERVICES_KEY_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_SERVICES_KEY_ID - name: APPLE_TEAM_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_TEAM_ID - name: APPLE_APP_ID valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: APPLE_APP_ID - name: DB_SYMMETRIC_KEY valueFrom: secretKeyRef: - name: fqauth.secrets + name: sincereauth.secrets key: DB_SYMMETRIC_KEY diff --git a/Deploy/Kubernetes/7-fqauth-service.yml b/Deploy/Kubernetes/7-sincereauth-service.yml similarity index 67% rename from Deploy/Kubernetes/7-fqauth-service.yml rename to Deploy/Kubernetes/7-sincereauth-service.yml index 816cc90..ddf2d23 100644 --- a/Deploy/Kubernetes/7-fqauth-service.yml +++ b/Deploy/Kubernetes/7-sincereauth-service.yml @@ -1,8 +1,8 @@ apiVersion: v1 kind: Service metadata: - name: fqauth-service - namespace: fqauth + name: sincereauth-service + namespace: sincereauth spec: type: LoadBalancer ports: @@ -11,4 +11,4 @@ spec: targetPort: 80 protocol: TCP selector: - app: fqauth-app + app: sincereauth-app diff --git a/Deploy/Kubernetes/README.md b/Deploy/Kubernetes/README.md index 766c2fe..d7e7105 100644 --- a/Deploy/Kubernetes/README.md +++ b/Deploy/Kubernetes/README.md @@ -1,6 +1,6 @@ # Digital Ocean Kubernetes -Deployment guide for FQAuth on Digital Ocean Kubernetes +Deployment guide for SincereAuth on Digital Ocean Kubernetes ## Pre reqs @@ -9,11 +9,11 @@ Deployment guide for FQAuth on Digital Ocean Kubernetes ## Install -1. Create a user in the database for FQAuth. Ensure this user has access to the `public` schema. If your user doesn't have access, login to your fqauth database as your root user and grant access. For example, +1. Create a user in the database for SincereAuth. Ensure this user has access to the `public` schema. If your user doesn't have access, login to your sincereauth database as your root user and grant access. For example, - GRANT ALL ON SCHEMA public TO fqauth; + GRANT ALL ON SCHEMA public TO sincereauth; -2. Gather the other environment variables as discussed in `Sources/FQAuthServer/EnvVars.swift`, and store them in the secrets file. Rename 1-fqauth-secrets.sample.yml to 1-fqauth-secrets.yml. +2. Gather the other environment variables as discussed in `Sources/SincereAuthServer/EnvVars.swift`, and store them in the secrets file. Rename 1-sincereauth-secrets.sample.yml to 1-sincereauth-secrets.yml. 1. APPLE_APP_ID 2. APPLE_SERVICES_KEY diff --git a/Deploy/README.md b/Deploy/README.md index 7c2e63a..75c2e22 100644 --- a/Deploy/README.md +++ b/Deploy/README.md @@ -1,5 +1,5 @@ -# FQAuth Deployment +# SincereAuth Deployment -FQAuth is deployed as 1 web service, 1 queues service, 1 scheduled queues service, 1 Redis instance, and 1 Postgres database. +SincereAuth is deployed as 1 web service, 1 queues service, 1 scheduled queues service, 1 Redis instance, and 1 Postgres database. diff --git a/Dockerfile b/Dockerfile index 33df9a5..344961a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,7 +6,7 @@ COPY ./Resources ./Resources COPY ./Tests ./Tests RUN swift build -c release -Xswiftc -g RUN mkdir /output -RUN cp $(swift build -c release -Xswiftc -g --show-bin-path)/FQAuthServer /output/FQAuthServer +RUN cp $(swift build -c release -Xswiftc -g --show-bin-path)/SincereAuthServer /output/SincereAuthServer RUN cp -R ./Resources /output/Resources FROM index.docker.io/library/swift:5.7-jammy-slim as production @@ -19,13 +19,13 @@ COPY --from=builder /usr/lib/swift/ /usr/lib/swift/ FROM production as web ENV PORT 80 EXPOSE $PORT -CMD /app/FQAuthServer serve --env production --hostname 0.0.0.0 -p $PORT +CMD /app/SincereAuthServer serve --env production --hostname 0.0.0.0 -p $PORT FROM production as queues -CMD /app/FQAuthServer queues --env production +CMD /app/SincereAuthServer queues --env production FROM production as scheduled-queues -CMD /app/FQAuthServer queues --scheduled --env production +CMD /app/SincereAuthServer queues --scheduled --env production FROM production as release -CMD /app/FQAuthServer migrate -y --env production +CMD /app/SincereAuthServer migrate -y --env production diff --git a/Documentation/svg/architecture.svg b/Documentation/svg/architecture.svg index 8fa8ede..81c71f9 100644 --- a/Documentation/svg/architecture.svg +++ b/Documentation/svg/architecture.svg @@ -202,7 +202,7 @@ id="tspan1112" x="126.96227" y="154.59277" - style="stroke-width:4.371">FQAuth + style="stroke-width:4.371">SincereAuth FQAuthSincereAuthFQAuthSincereAuthFQAuth SincereAuth FullQueueDeveloper.com/FQAuth + y="283.06186">FullQueueDeveloper.com/SincereAuth FQAuth SincereAuth FullQueueDeveloper.com/FQAuth + y="283.06186">FullQueueDeveloper.com/SincereAuth FQAuth SincereAuth FQAuth SincereAuth FQAuthSincereAuthFullQueueDeveloper.com/FQAuth + y="283.06186">FullQueueDeveloper.com/SincereAuth FQAuth SincereAuth FQAuth SincereAuth FullQueueDeveloper.com/FQAuth + y="283.06186">FullQueueDeveloper.com/SincereAuth FQAuth SincereAuth FQAuth SincereAuth FullQueueDeveloper.com/FQAuth + y="283.06186">FullQueueDeveloper.com/SincereAuth FQAuth SincereAuth FQAuth SincereAuth "Certificates, Identifiers & Profiles" > "Identifiers" 2. Create a new app on https://appstoreconnect.apple.com/apps, selecting the bundle ID from step 1. Add "Sign in with Apple" capability. diff --git a/SPX/Sources/local-postgres/LocalPostgres.config.swift b/SPX/Sources/local-postgres/LocalPostgres.config.swift index 5f9576c..4ab6ff5 100644 --- a/SPX/Sources/local-postgres/LocalPostgres.config.swift +++ b/SPX/Sources/local-postgres/LocalPostgres.config.swift @@ -1,7 +1,7 @@ import ShLocalPostgres extension LocalPostgres { - static var config: Self = .init(role: "fqauth", - password: "FQAuthPassword123", - databaseStem: "fqauth") + static var config: Self = .init(role: "sincereauth", + password: "SincereAuthPassword123", + databaseStem: "sincereauth") } diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/SIWAController.authorize.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/SIWAController.authorize.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/SIWAController.authorize.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/SIWAController.authorize.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/SIWAController.notify.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/SIWAController.notify.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/SIWAController.notify.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/SIWAController.notify.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/SIWAController.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/SIWAController.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/SIWAController.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/SIWAController.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/SIWAModel.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/SIWAModel.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/SIWAModel.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/SIWAModel.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/client/AppleAuthTokenResult.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/client/AppleAuthTokenResult.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/client/AppleAuthTokenResult.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/client/AppleAuthTokenResult.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/client/SIWAClient.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/client/SIWAClient.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/client/SIWAClient.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/client/SIWAClient.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/client/SIWAClientSecret.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/client/SIWAClientSecret.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/client/SIWAClientSecret.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/client/SIWAClientSecret.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/client/Services.siwaClient.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/client/Services.siwaClient.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/client/Services.siwaClient.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/client/Services.siwaClient.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jobs/ConsentRevokedJob.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jobs/ConsentRevokedJob.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jobs/ConsentRevokedJob.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jobs/ConsentRevokedJob.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jobs/EmailDisabledJob.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jobs/EmailDisabledJob.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jobs/EmailDisabledJob.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jobs/EmailDisabledJob.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jobs/EmailEnabledJob.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jobs/EmailEnabledJob.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jobs/EmailEnabledJob.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jobs/EmailEnabledJob.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jobs/EnqueueRefreshTokenJobsScheduledJob.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jobs/EnqueueRefreshTokenJobsScheduledJob.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jobs/EnqueueRefreshTokenJobsScheduledJob.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jobs/EnqueueRefreshTokenJobsScheduledJob.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jobs/RefreshTokenJob.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jobs/RefreshTokenJob.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jobs/RefreshTokenJob.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jobs/RefreshTokenJob.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jobs/SIWAAccountDeletedJob.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jobs/SIWAAccountDeletedJob.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jobs/SIWAAccountDeletedJob.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jobs/SIWAAccountDeletedJob.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/AppleAuthTokenBody.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleAuthTokenBody.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/AppleAuthTokenBody.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleAuthTokenBody.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/AppleErrorResponse.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleErrorResponse.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/AppleErrorResponse.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleErrorResponse.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/AppleJsonBool.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleJsonBool.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/AppleJsonBool.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleJsonBool.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/AppleJsonString.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleJsonString.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/AppleJsonString.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleJsonString.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/AppleSingleOrArray.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleSingleOrArray.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/AppleSingleOrArray.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleSingleOrArray.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/AppleTokenRefreshResponse.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleTokenRefreshResponse.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/AppleTokenRefreshResponse.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleTokenRefreshResponse.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/AppleTokenResponse.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleTokenResponse.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/AppleTokenResponse.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/AppleTokenResponse.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/json/SIWAServerNotification.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/json/SIWAServerNotification.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/json/SIWAServerNotification.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/json/SIWAServerNotification.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jwt/LiveSIWAProvider.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jwt/LiveSIWAProvider.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jwt/LiveSIWAProvider.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jwt/LiveSIWAProvider.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jwt/SIWAVerifier.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jwt/SIWAVerifier.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jwt/SIWAVerifier.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jwt/SIWAVerifier.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/jwt/Services.siwaVerifier.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/jwt/Services.siwaVerifier.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/jwt/Services.siwaVerifier.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/jwt/Services.siwaVerifier.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/repo/SIWADeactivateRepo.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/repo/SIWADeactivateRepo.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/repo/SIWADeactivateRepo.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/repo/SIWADeactivateRepo.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/repo/SIWAReadyForReverifyRepo.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/repo/SIWAReadyForReverifyRepo.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/repo/SIWAReadyForReverifyRepo.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/repo/SIWAReadyForReverifyRepo.swift diff --git a/Sources/FQAuthServer/Apple/SignInWithApple/repo/SIWASignUpRepo.swift b/Sources/SincereAuthServer/Apple/SignInWithApple/repo/SIWASignUpRepo.swift similarity index 100% rename from Sources/FQAuthServer/Apple/SignInWithApple/repo/SIWASignUpRepo.swift rename to Sources/SincereAuthServer/Apple/SignInWithApple/repo/SIWASignUpRepo.swift diff --git a/Sources/FQAuthServer/Auth/AuthConstant.swift b/Sources/SincereAuthServer/Auth/AuthConstant.swift similarity index 100% rename from Sources/FQAuthServer/Auth/AuthConstant.swift rename to Sources/SincereAuthServer/Auth/AuthConstant.swift diff --git a/Sources/FQAuthServer/Auth/AuthHelper.login.swift b/Sources/SincereAuthServer/Auth/AuthHelper.login.swift similarity index 86% rename from Sources/FQAuthServer/Auth/AuthHelper.login.swift rename to Sources/SincereAuthServer/Auth/AuthHelper.login.swift index 14ab0e7..74be6ac 100644 --- a/Sources/FQAuthServer/Auth/AuthHelper.login.swift +++ b/Sources/SincereAuthServer/Auth/AuthHelper.login.swift @@ -1,5 +1,5 @@ import Vapor -import FQAuthMiddleware +import SincereAuthMiddleware struct AuthHelper { let request: Request @@ -13,7 +13,7 @@ struct AuthHelper { token: refreshToken) .create(on: request.db) .flatMapThrowing { _ in - let accessJWT = FQAuthSessionToken(userId: userId, deviceName: deviceName, roles: roles) + let accessJWT = SincereAuthSessionToken(userId: userId, deviceName: deviceName, roles: roles) let accessToken = try request.jwt.sign(accessJWT, kid: .authPrivateKey) diff --git a/Sources/FQAuthServer/Auth/AuthResponse.swift b/Sources/SincereAuthServer/Auth/AuthResponse.swift similarity index 100% rename from Sources/FQAuthServer/Auth/AuthResponse.swift rename to Sources/SincereAuthServer/Auth/AuthResponse.swift diff --git a/Sources/FQAuthServer/Auth/FQAuthSessionToken.init.swift b/Sources/SincereAuthServer/Auth/FQAuthSessionToken.init.swift similarity index 84% rename from Sources/FQAuthServer/Auth/FQAuthSessionToken.init.swift rename to Sources/SincereAuthServer/Auth/FQAuthSessionToken.init.swift index 5e57140..f40863c 100644 --- a/Sources/FQAuthServer/Auth/FQAuthSessionToken.init.swift +++ b/Sources/SincereAuthServer/Auth/FQAuthSessionToken.init.swift @@ -1,8 +1,8 @@ import JWT import Vapor -import FQAuthMiddleware +import SincereAuthMiddleware -extension FQAuthSessionToken { +extension SincereAuthSessionToken { init(userId: UUID, deviceName: String, roles: [String], now: Date = Date()) { self.init(userID: userId, diff --git a/Sources/FQAuthServer/Auth/RefreshToken/RefreshTokenController.swift b/Sources/SincereAuthServer/Auth/RefreshToken/RefreshTokenController.swift similarity index 100% rename from Sources/FQAuthServer/Auth/RefreshToken/RefreshTokenController.swift rename to Sources/SincereAuthServer/Auth/RefreshToken/RefreshTokenController.swift diff --git a/Sources/FQAuthServer/Auth/RefreshToken/RefreshTokenModel.swift b/Sources/SincereAuthServer/Auth/RefreshToken/RefreshTokenModel.swift similarity index 100% rename from Sources/FQAuthServer/Auth/RefreshToken/RefreshTokenModel.swift rename to Sources/SincereAuthServer/Auth/RefreshToken/RefreshTokenModel.swift diff --git a/Sources/FQAuthServer/Auth/RefreshToken/RefreshTokenRequestBody.swift b/Sources/SincereAuthServer/Auth/RefreshToken/RefreshTokenRequestBody.swift similarity index 100% rename from Sources/FQAuthServer/Auth/RefreshToken/RefreshTokenRequestBody.swift rename to Sources/SincereAuthServer/Auth/RefreshToken/RefreshTokenRequestBody.swift diff --git a/Sources/FQAuthServer/Auth/User/UserController.swift b/Sources/SincereAuthServer/Auth/User/UserController.swift similarity index 84% rename from Sources/FQAuthServer/Auth/User/UserController.swift rename to Sources/SincereAuthServer/Auth/User/UserController.swift index 2776dd6..347b741 100644 --- a/Sources/FQAuthServer/Auth/User/UserController.swift +++ b/Sources/SincereAuthServer/Auth/User/UserController.swift @@ -1,5 +1,5 @@ import Vapor -import FQAuthMiddleware +import SincereAuthMiddleware final class UserController { @@ -8,7 +8,7 @@ final class UserController { throw Abort(.badRequest) } - let token = try req.auth.require(FQAuthSessionToken.self) + let token = try req.auth.require(SincereAuthSessionToken.self) guard token.userID == userID else { throw Abort(.forbidden) @@ -37,7 +37,7 @@ final class UserController { extension UserController: RouteCollection { func boot(routes: Vapor.RoutesBuilder) throws { - routes.group(FQAuthSessionToken.authenticator(), FQAuthSessionToken.guardMiddleware()) { + routes.group(SincereAuthSessionToken.authenticator(), SincereAuthSessionToken.guardMiddleware()) { $0.group("user", ":userID") { userRoutes in userRoutes.get("activeTokens", use: activeTokens(req:)) } diff --git a/Sources/FQAuthServer/Auth/User/UserModel.findBy.swift b/Sources/SincereAuthServer/Auth/User/UserModel.findBy.swift similarity index 100% rename from Sources/FQAuthServer/Auth/User/UserModel.findBy.swift rename to Sources/SincereAuthServer/Auth/User/UserModel.findBy.swift diff --git a/Sources/FQAuthServer/Auth/User/UserModel.swift b/Sources/SincereAuthServer/Auth/User/UserModel.swift similarity index 100% rename from Sources/FQAuthServer/Auth/User/UserModel.swift rename to Sources/SincereAuthServer/Auth/User/UserModel.swift diff --git a/Sources/FQAuthServer/Auth/db/CleanupExpiredRefreshTokenScheduledJob.swift b/Sources/SincereAuthServer/Auth/db/CleanupExpiredRefreshTokenScheduledJob.swift similarity index 100% rename from Sources/FQAuthServer/Auth/db/CleanupExpiredRefreshTokenScheduledJob.swift rename to Sources/SincereAuthServer/Auth/db/CleanupExpiredRefreshTokenScheduledJob.swift diff --git a/Sources/FQAuthServer/Auth/db/DBSeal.swift b/Sources/SincereAuthServer/Auth/db/DBSeal.swift similarity index 100% rename from Sources/FQAuthServer/Auth/db/DBSeal.swift rename to Sources/SincereAuthServer/Auth/db/DBSeal.swift diff --git a/Sources/FQAuthServer/Auth/jwt/JWK.authPublic.swift b/Sources/SincereAuthServer/Auth/jwt/JWK.authPublic.swift similarity index 100% rename from Sources/FQAuthServer/Auth/jwt/JWK.authPublic.swift rename to Sources/SincereAuthServer/Auth/jwt/JWK.authPublic.swift diff --git a/Sources/FQAuthServer/Auth/jwt/JWKS.public.swift b/Sources/SincereAuthServer/Auth/jwt/JWKS.public.swift similarity index 100% rename from Sources/FQAuthServer/Auth/jwt/JWKS.public.swift rename to Sources/SincereAuthServer/Auth/jwt/JWKS.public.swift diff --git a/Sources/FQAuthServer/Auth/jwt/JWKSController.swift b/Sources/SincereAuthServer/Auth/jwt/JWKSController.swift similarity index 100% rename from Sources/FQAuthServer/Auth/jwt/JWKSController.swift rename to Sources/SincereAuthServer/Auth/jwt/JWKSController.swift diff --git a/Sources/FQAuthServer/Auth/jwt/JWTVerifying.swift b/Sources/SincereAuthServer/Auth/jwt/JWTVerifying.swift similarity index 100% rename from Sources/FQAuthServer/Auth/jwt/JWTVerifying.swift rename to Sources/SincereAuthServer/Auth/jwt/JWTVerifying.swift diff --git a/Sources/FQAuthServer/Auth/jwt/ecdsa-keys.swift b/Sources/SincereAuthServer/Auth/jwt/ecdsa-keys.swift similarity index 100% rename from Sources/FQAuthServer/Auth/jwt/ecdsa-keys.swift rename to Sources/SincereAuthServer/Auth/jwt/ecdsa-keys.swift diff --git a/Sources/FQAuthServer/Auth/jwt/jwt-identifiers.swift b/Sources/SincereAuthServer/Auth/jwt/jwt-identifiers.swift similarity index 100% rename from Sources/FQAuthServer/Auth/jwt/jwt-identifiers.swift rename to Sources/SincereAuthServer/Auth/jwt/jwt-identifiers.swift diff --git a/Sources/FQAuthServer/Auth/jwt/jwt-signers.swift b/Sources/SincereAuthServer/Auth/jwt/jwt-signers.swift similarity index 100% rename from Sources/FQAuthServer/Auth/jwt/jwt-signers.swift rename to Sources/SincereAuthServer/Auth/jwt/jwt-signers.swift diff --git a/Sources/FQAuthServer/EnvVars.swift b/Sources/SincereAuthServer/EnvVars.swift similarity index 100% rename from Sources/FQAuthServer/EnvVars.swift rename to Sources/SincereAuthServer/EnvVars.swift diff --git a/Sources/FQAuthServer/Main.swift b/Sources/SincereAuthServer/Main.swift similarity index 100% rename from Sources/FQAuthServer/Main.swift rename to Sources/SincereAuthServer/Main.swift diff --git a/Sources/FQAuthServer/configure/configure.swift b/Sources/SincereAuthServer/configure/configure.swift similarity index 100% rename from Sources/FQAuthServer/configure/configure.swift rename to Sources/SincereAuthServer/configure/configure.swift diff --git a/Sources/FQAuthServer/configure/configureCommands.swift b/Sources/SincereAuthServer/configure/configureCommands.swift similarity index 100% rename from Sources/FQAuthServer/configure/configureCommands.swift rename to Sources/SincereAuthServer/configure/configureCommands.swift diff --git a/Sources/FQAuthServer/configure/configureMigrations.swift b/Sources/SincereAuthServer/configure/configureMigrations.swift similarity index 100% rename from Sources/FQAuthServer/configure/configureMigrations.swift rename to Sources/SincereAuthServer/configure/configureMigrations.swift diff --git a/Sources/FQAuthServer/configure/configurePostgres.swift b/Sources/SincereAuthServer/configure/configurePostgres.swift similarity index 100% rename from Sources/FQAuthServer/configure/configurePostgres.swift rename to Sources/SincereAuthServer/configure/configurePostgres.swift diff --git a/Sources/FQAuthServer/configure/configureQueues.swift b/Sources/SincereAuthServer/configure/configureQueues.swift similarity index 100% rename from Sources/FQAuthServer/configure/configureQueues.swift rename to Sources/SincereAuthServer/configure/configureQueues.swift diff --git a/Sources/FQAuthServer/configure/configureRedis.swift b/Sources/SincereAuthServer/configure/configureRedis.swift similarity index 100% rename from Sources/FQAuthServer/configure/configureRedis.swift rename to Sources/SincereAuthServer/configure/configureRedis.swift diff --git a/Sources/FQAuthServer/configure/configureRoutes.swift b/Sources/SincereAuthServer/configure/configureRoutes.swift similarity index 94% rename from Sources/FQAuthServer/configure/configureRoutes.swift rename to Sources/SincereAuthServer/configure/configureRoutes.swift index 7807556..5a74800 100644 --- a/Sources/FQAuthServer/configure/configureRoutes.swift +++ b/Sources/SincereAuthServer/configure/configureRoutes.swift @@ -1,6 +1,6 @@ import Vapor import JWT -import FQAuthMiddleware +import SincereAuthMiddleware extension Application { diff --git a/Sources/FQAuthServer/configure/configureServices.swift b/Sources/SincereAuthServer/configure/configureServices.swift similarity index 100% rename from Sources/FQAuthServer/configure/configureServices.swift rename to Sources/SincereAuthServer/configure/configureServices.swift diff --git a/Sources/FQAuthServer/configure/configureSigning.swift b/Sources/SincereAuthServer/configure/configureSigning.swift similarity index 100% rename from Sources/FQAuthServer/configure/configureSigning.swift rename to Sources/SincereAuthServer/configure/configureSigning.swift diff --git a/Sources/FQAuthServer/configure/migrations/AddRolesToUserMigration.swift b/Sources/SincereAuthServer/configure/migrations/AddRolesToUserMigration.swift similarity index 100% rename from Sources/FQAuthServer/configure/migrations/AddRolesToUserMigration.swift rename to Sources/SincereAuthServer/configure/migrations/AddRolesToUserMigration.swift diff --git a/Sources/FQAuthServer/configure/migrations/CreateFunctionMigration.swift b/Sources/SincereAuthServer/configure/migrations/CreateFunctionMigration.swift similarity index 100% rename from Sources/FQAuthServer/configure/migrations/CreateFunctionMigration.swift rename to Sources/SincereAuthServer/configure/migrations/CreateFunctionMigration.swift diff --git a/Sources/FQAuthServer/configure/migrations/CreateRefreshTokenMigration.swift b/Sources/SincereAuthServer/configure/migrations/CreateRefreshTokenMigration.swift similarity index 100% rename from Sources/FQAuthServer/configure/migrations/CreateRefreshTokenMigration.swift rename to Sources/SincereAuthServer/configure/migrations/CreateRefreshTokenMigration.swift diff --git a/Sources/FQAuthServer/configure/migrations/CreateSiwaMigration.swift b/Sources/SincereAuthServer/configure/migrations/CreateSiwaMigration.swift similarity index 100% rename from Sources/FQAuthServer/configure/migrations/CreateSiwaMigration.swift rename to Sources/SincereAuthServer/configure/migrations/CreateSiwaMigration.swift diff --git a/Sources/FQAuthServer/configure/migrations/CreateUserMigration.swift b/Sources/SincereAuthServer/configure/migrations/CreateUserMigration.swift similarity index 100% rename from Sources/FQAuthServer/configure/migrations/CreateUserMigration.swift rename to Sources/SincereAuthServer/configure/migrations/CreateUserMigration.swift diff --git a/Sources/FQAuthServer/lib/PostgresDatabase/PostgresDatabase.exec.swift b/Sources/SincereAuthServer/lib/PostgresDatabase/PostgresDatabase.exec.swift similarity index 100% rename from Sources/FQAuthServer/lib/PostgresDatabase/PostgresDatabase.exec.swift rename to Sources/SincereAuthServer/lib/PostgresDatabase/PostgresDatabase.exec.swift diff --git a/Sources/FQAuthServer/lib/PostgresDatabase/PostgresMigration.swift b/Sources/SincereAuthServer/lib/PostgresDatabase/PostgresMigration.swift similarity index 100% rename from Sources/FQAuthServer/lib/PostgresDatabase/PostgresMigration.swift rename to Sources/SincereAuthServer/lib/PostgresDatabase/PostgresMigration.swift diff --git a/Sources/FQAuthServer/lib/PostgresDatabase/PostgresScriptMigration.swift b/Sources/SincereAuthServer/lib/PostgresDatabase/PostgresScriptMigration.swift similarity index 100% rename from Sources/FQAuthServer/lib/PostgresDatabase/PostgresScriptMigration.swift rename to Sources/SincereAuthServer/lib/PostgresDatabase/PostgresScriptMigration.swift diff --git a/Sources/FQAuthServer/lib/Service/Application.Services.swift b/Sources/SincereAuthServer/lib/Service/Application.Services.swift similarity index 100% rename from Sources/FQAuthServer/lib/Service/Application.Services.swift rename to Sources/SincereAuthServer/lib/Service/Application.Services.swift diff --git a/Sources/FQAuthServer/lib/Service/Request.Services.swift b/Sources/SincereAuthServer/lib/Service/Request.Services.swift similarity index 100% rename from Sources/FQAuthServer/lib/Service/Request.Services.swift rename to Sources/SincereAuthServer/lib/Service/Request.Services.swift diff --git a/Sources/FQAuthServer/lib/Service/Service.swift b/Sources/SincereAuthServer/lib/Service/Service.swift similarity index 100% rename from Sources/FQAuthServer/lib/Service/Service.swift rename to Sources/SincereAuthServer/lib/Service/Service.swift diff --git a/Sources/FQAuthServer/web/Admin/-.listUsers.swift b/Sources/SincereAuthServer/web/Admin/-.listUsers.swift similarity index 100% rename from Sources/FQAuthServer/web/Admin/-.listUsers.swift rename to Sources/SincereAuthServer/web/Admin/-.listUsers.swift diff --git a/Sources/FQAuthServer/web/Admin/AdminWebController.swift b/Sources/SincereAuthServer/web/Admin/AdminWebController.swift similarity index 76% rename from Sources/FQAuthServer/web/Admin/AdminWebController.swift rename to Sources/SincereAuthServer/web/Admin/AdminWebController.swift index 86dca08..7944dbd 100644 --- a/Sources/FQAuthServer/web/Admin/AdminWebController.swift +++ b/Sources/SincereAuthServer/web/Admin/AdminWebController.swift @@ -1,11 +1,11 @@ import Vapor -import FQAuthMiddleware +import SincereAuthMiddleware final class AdminWebController: RouteCollection { func boot(routes: RoutesBuilder) throws { routes - .grouped(FQAuthMiddleware()) + .grouped(SincereAuthMiddleware()) .group("admin") { admin in admin.get("list-users", use: self.listUsers(req:)) } diff --git a/Sources/FQAuthServer/web/LoginController.swift b/Sources/SincereAuthServer/web/LoginController.swift similarity index 100% rename from Sources/FQAuthServer/web/LoginController.swift rename to Sources/SincereAuthServer/web/LoginController.swift diff --git a/Tests/FQAuthServerTests/.gitignore b/Tests/SincereAuthServerTests/.gitignore similarity index 100% rename from Tests/FQAuthServerTests/.gitignore rename to Tests/SincereAuthServerTests/.gitignore diff --git a/Tests/FQAuthServerTests/Apple/Fixtures.swift b/Tests/SincereAuthServerTests/Apple/Fixtures.swift similarity index 100% rename from Tests/FQAuthServerTests/Apple/Fixtures.swift rename to Tests/SincereAuthServerTests/Apple/Fixtures.swift diff --git a/Tests/FQAuthServerTests/Apple/SIWAClientTests.swift b/Tests/SincereAuthServerTests/Apple/SIWAClientTests.swift similarity index 99% rename from Tests/FQAuthServerTests/Apple/SIWAClientTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWAClientTests.swift index 7c8679b..3741ba2 100644 --- a/Tests/FQAuthServerTests/Apple/SIWAClientTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWAClientTests.swift @@ -1,6 +1,6 @@ import XCTest import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer final class SIWAClientTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/Apple/SIWADeactivateUserRepoTests.swift b/Tests/SincereAuthServerTests/Apple/SIWADeactivateUserRepoTests.swift similarity index 98% rename from Tests/FQAuthServerTests/Apple/SIWADeactivateUserRepoTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWADeactivateUserRepoTests.swift index 26d0436..3c3a9df 100644 --- a/Tests/FQAuthServerTests/Apple/SIWADeactivateUserRepoTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWADeactivateUserRepoTests.swift @@ -1,6 +1,6 @@ import Foundation import XCTest -@testable import FQAuthServer +@testable import SincereAuthServer import Vapor final class SIWADeactivateUserRepoTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/Apple/SIWAModelTests.swift b/Tests/SincereAuthServerTests/Apple/SIWAModelTests.swift similarity index 96% rename from Tests/FQAuthServerTests/Apple/SIWAModelTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWAModelTests.swift index 9ab6ca3..87952ab 100644 --- a/Tests/FQAuthServerTests/Apple/SIWAModelTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWAModelTests.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import XCTest import Vapor import PostgresKit diff --git a/Tests/FQAuthServerTests/Apple/SIWAReadyForReverifyRepoTests.swift b/Tests/SincereAuthServerTests/Apple/SIWAReadyForReverifyRepoTests.swift similarity index 99% rename from Tests/FQAuthServerTests/Apple/SIWAReadyForReverifyRepoTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWAReadyForReverifyRepoTests.swift index 7755a13..f351a46 100644 --- a/Tests/FQAuthServerTests/Apple/SIWAReadyForReverifyRepoTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWAReadyForReverifyRepoTests.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import XCTest import Vapor import PostgresKit diff --git a/Tests/FQAuthServerTests/Apple/SIWAServerNotificationDecodingTests.swift b/Tests/SincereAuthServerTests/Apple/SIWAServerNotificationDecodingTests.swift similarity index 95% rename from Tests/FQAuthServerTests/Apple/SIWAServerNotificationDecodingTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWAServerNotificationDecodingTests.swift index b93d6b8..e7f394c 100644 --- a/Tests/FQAuthServerTests/Apple/SIWAServerNotificationDecodingTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWAServerNotificationDecodingTests.swift @@ -1,12 +1,12 @@ import XCTest import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer final class SIWAServerNotificationDecodingTests: XCTestCase { - + func testDocumentationExample() throws { // The example in the documentation does not match JSON posted to my server from Apple. The example has been adjusted - + let json = #""" { "iss": "https://appleid.apple.com", @@ -16,29 +16,29 @@ final class SIWAServerNotificationDecodingTests: XCTestCase { "events": "{\"type\":\"consent-revoked\",\"sub\":\"820417.faa325acbc78e1be1668ba852d492d8a.0219\",\"event_time\":1670016125295}" } """# - + let notification = try JSONDecoder().decode(SIWAServerNotification.self, from: json.data(using: .utf8)!) XCTAssertNoThrow(try notification.aud.verifyIntendedAudience(includes: "com.mytest.app")) - + let consentRevoked = try XCTUnwrap(notification.events.wrapped.consentRevoked) XCTAssertEqual(consentRevoked.sub.value, "820417.faa325acbc78e1be1668ba852d492d8a.0219") } - + func testFixture() throws { let app: Application = Application(.testing) defer { app.shutdown() } - + try app.useAppleJWKS() - + let body = try JSONDecoder().decode(SIWAController.NotifyBody.self, from: AppleFixtures.siwaNotificationBody.data(using: .utf8)!) let notification = try app.jwt.signers.unverified(body.payload, as: SIWAServerNotification.self) - + XCTAssertEqual(notification.iss, "https://appleid.apple.com") XCTAssertNoThrow(try notification.aud.verifyIntendedAudience(includes: "com.fullqueuedeveloper.FQAuthSampleiOSApp")) - + let consentRevoked = try XCTUnwrap(notification.events.wrapped.consentRevoked) XCTAssertEqual(consentRevoked.sub.value, "002024.1951936c61fa47debb2b076e6896ccc1.1949") } diff --git a/Tests/FQAuthServerTests/Apple/SIWAServerNotificationEncodingTests.swift b/Tests/SincereAuthServerTests/Apple/SIWAServerNotificationEncodingTests.swift similarity index 97% rename from Tests/FQAuthServerTests/Apple/SIWAServerNotificationEncodingTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWAServerNotificationEncodingTests.swift index 59590d4..1ac743e 100644 --- a/Tests/FQAuthServerTests/Apple/SIWAServerNotificationEncodingTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWAServerNotificationEncodingTests.swift @@ -1,7 +1,7 @@ import XCTest import Vapor import JWTKit -@testable import FQAuthServer +@testable import SincereAuthServer final class SIWAServerNotificationEncodingTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/Apple/SIWAServerNotificationRequestTests.swift b/Tests/SincereAuthServerTests/Apple/SIWAServerNotificationRequestTests.swift similarity index 99% rename from Tests/FQAuthServerTests/Apple/SIWAServerNotificationRequestTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWAServerNotificationRequestTests.swift index f2d917b..bc02e52 100644 --- a/Tests/FQAuthServerTests/Apple/SIWAServerNotificationRequestTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWAServerNotificationRequestTests.swift @@ -1,4 +1,4 @@ -@testable import FQAuthServer +@testable import SincereAuthServer import XCTest import Foundation import Vapor diff --git a/Tests/FQAuthServerTests/Apple/SIWASignInRequestTests.swift b/Tests/SincereAuthServerTests/Apple/SIWASignInRequestTests.swift similarity index 98% rename from Tests/FQAuthServerTests/Apple/SIWASignInRequestTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWASignInRequestTests.swift index 9363558..0214f77 100644 --- a/Tests/FQAuthServerTests/Apple/SIWASignInRequestTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWASignInRequestTests.swift @@ -1,4 +1,4 @@ -@testable import FQAuthServer +@testable import SincereAuthServer import XCTest import Vapor import JWTKit diff --git a/Tests/FQAuthServerTests/Apple/SIWASignUpRepoTests.swift b/Tests/SincereAuthServerTests/Apple/SIWASignUpRepoTests.swift similarity index 98% rename from Tests/FQAuthServerTests/Apple/SIWASignUpRepoTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWASignUpRepoTests.swift index 5c763a9..635acbd 100644 --- a/Tests/FQAuthServerTests/Apple/SIWASignUpRepoTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWASignUpRepoTests.swift @@ -1,6 +1,6 @@ import XCTest import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer import FluentPostgresDriver final class SIWASignUpRepoTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/Apple/SIWASignUpRequestTests.swift b/Tests/SincereAuthServerTests/Apple/SIWASignUpRequestTests.swift similarity index 98% rename from Tests/FQAuthServerTests/Apple/SIWASignUpRequestTests.swift rename to Tests/SincereAuthServerTests/Apple/SIWASignUpRequestTests.swift index 37495db..81cc880 100644 --- a/Tests/FQAuthServerTests/Apple/SIWASignUpRequestTests.swift +++ b/Tests/SincereAuthServerTests/Apple/SIWASignUpRequestTests.swift @@ -1,4 +1,4 @@ -@testable import FQAuthServer +@testable import SincereAuthServer import XCTest import Vapor import JWTKit diff --git a/Tests/FQAuthServerTests/Apple/factories/AppleIdentityTokenFactory.swift b/Tests/SincereAuthServerTests/Apple/factories/AppleIdentityTokenFactory.swift similarity index 100% rename from Tests/FQAuthServerTests/Apple/factories/AppleIdentityTokenFactory.swift rename to Tests/SincereAuthServerTests/Apple/factories/AppleIdentityTokenFactory.swift diff --git a/Tests/FQAuthServerTests/Apple/factories/SIWAUser.swift b/Tests/SincereAuthServerTests/Apple/factories/SIWAUser.swift similarity index 93% rename from Tests/FQAuthServerTests/Apple/factories/SIWAUser.swift rename to Tests/SincereAuthServerTests/Apple/factories/SIWAUser.swift index e0f33af..dddc85d 100644 --- a/Tests/FQAuthServerTests/Apple/factories/SIWAUser.swift +++ b/Tests/SincereAuthServerTests/Apple/factories/SIWAUser.swift @@ -1,4 +1,4 @@ -@testable import FQAuthServer +@testable import SincereAuthServer extension SIWASignUpRepo { diff --git a/Tests/FQAuthServerTests/Apple/fakes/FakeJWTSigners.swift b/Tests/SincereAuthServerTests/Apple/fakes/FakeJWTSigners.swift similarity index 93% rename from Tests/FQAuthServerTests/Apple/fakes/FakeJWTSigners.swift rename to Tests/SincereAuthServerTests/Apple/fakes/FakeJWTSigners.swift index 68d8262..a329a43 100644 --- a/Tests/FQAuthServerTests/Apple/fakes/FakeJWTSigners.swift +++ b/Tests/SincereAuthServerTests/Apple/fakes/FakeJWTSigners.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import JWTKit struct FakeJWTSigners: JWTVerifying { diff --git a/Tests/FQAuthServerTests/Apple/fakes/FakeSIWAClient.swift b/Tests/SincereAuthServerTests/Apple/fakes/FakeSIWAClient.swift similarity index 84% rename from Tests/FQAuthServerTests/Apple/fakes/FakeSIWAClient.swift rename to Tests/SincereAuthServerTests/Apple/fakes/FakeSIWAClient.swift index 3f64de8..8502a48 100644 --- a/Tests/FQAuthServerTests/Apple/fakes/FakeSIWAClient.swift +++ b/Tests/SincereAuthServerTests/Apple/fakes/FakeSIWAClient.swift @@ -1,6 +1,6 @@ import Foundation import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer struct FakeSIWAClient: SIWAClient { @@ -18,7 +18,7 @@ struct FakeSIWAClient: SIWAClient { } var generateRefreshTokenStub: AppleTokenResponse? - func generateRefreshToken(code: String) -> NIOCore.EventLoopFuture { + func generateRefreshToken(code: String) -> NIOCore.EventLoopFuture { if let stub = generateRefreshTokenStub { return eventLoop.makeSucceededFuture(stub) } else { @@ -26,7 +26,7 @@ struct FakeSIWAClient: SIWAClient { } } - func `for`(_ request: Vapor.Request) -> FQAuthServer.SIWAClient { + func `for`(_ request: Vapor.Request) -> SincereAuthServer.SIWAClient { self } } diff --git a/Tests/FQAuthServerTests/Apple/fakes/FakeSIWAVerifier.swift b/Tests/SincereAuthServerTests/Apple/fakes/FakeSIWAVerifier.swift similarity index 89% rename from Tests/FQAuthServerTests/Apple/fakes/FakeSIWAVerifier.swift rename to Tests/SincereAuthServerTests/Apple/fakes/FakeSIWAVerifier.swift index 3ab2f41..f690104 100644 --- a/Tests/FQAuthServerTests/Apple/fakes/FakeSIWAVerifier.swift +++ b/Tests/SincereAuthServerTests/Apple/fakes/FakeSIWAVerifier.swift @@ -1,6 +1,6 @@ import Foundation import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer import JWT struct FakeSIWAVerifier: SIWAVerifier, SIWAVerifierProvider { @@ -17,7 +17,7 @@ struct FakeSIWAVerifier: SIWAVerifier, SIWAVerifierProvider { return eventLoop.makeSucceededFuture(stub) } - func `for`(_ request: Vapor.Request) -> FQAuthServer.SIWAVerifier { + func `for`(_ request: Vapor.Request) -> SincereAuthServer.SIWAVerifier { FakeSIWAVerifier(eventLoop: request.eventLoop, verifyStub: verifyStub) } } diff --git a/Tests/FQAuthServerTests/Apple/jobs/ConsentRevokedJobTest.swift b/Tests/SincereAuthServerTests/Apple/jobs/ConsentRevokedJobTest.swift similarity index 97% rename from Tests/FQAuthServerTests/Apple/jobs/ConsentRevokedJobTest.swift rename to Tests/SincereAuthServerTests/Apple/jobs/ConsentRevokedJobTest.swift index eb7f8e4..ce2ca2f 100644 --- a/Tests/FQAuthServerTests/Apple/jobs/ConsentRevokedJobTest.swift +++ b/Tests/SincereAuthServerTests/Apple/jobs/ConsentRevokedJobTest.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import PostgresKit import FluentPostgresDriver import XCTest diff --git a/Tests/FQAuthServerTests/Apple/jobs/EmailDisabledJobTest.swift b/Tests/SincereAuthServerTests/Apple/jobs/EmailDisabledJobTest.swift similarity index 97% rename from Tests/FQAuthServerTests/Apple/jobs/EmailDisabledJobTest.swift rename to Tests/SincereAuthServerTests/Apple/jobs/EmailDisabledJobTest.swift index 807ca90..c54e3b8 100644 --- a/Tests/FQAuthServerTests/Apple/jobs/EmailDisabledJobTest.swift +++ b/Tests/SincereAuthServerTests/Apple/jobs/EmailDisabledJobTest.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import PostgresKit import FluentPostgresDriver import XCTest diff --git a/Tests/FQAuthServerTests/Apple/jobs/EmailEnabledJobTest.swift b/Tests/SincereAuthServerTests/Apple/jobs/EmailEnabledJobTest.swift similarity index 96% rename from Tests/FQAuthServerTests/Apple/jobs/EmailEnabledJobTest.swift rename to Tests/SincereAuthServerTests/Apple/jobs/EmailEnabledJobTest.swift index cfb2549..315e40f 100644 --- a/Tests/FQAuthServerTests/Apple/jobs/EmailEnabledJobTest.swift +++ b/Tests/SincereAuthServerTests/Apple/jobs/EmailEnabledJobTest.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import PostgresKit import FluentPostgresDriver import XCTest diff --git a/Tests/FQAuthServerTests/Apple/jobs/SIWAAccountDeletedJobTest.swift b/Tests/SincereAuthServerTests/Apple/jobs/SIWAAccountDeletedJobTest.swift similarity index 97% rename from Tests/FQAuthServerTests/Apple/jobs/SIWAAccountDeletedJobTest.swift rename to Tests/SincereAuthServerTests/Apple/jobs/SIWAAccountDeletedJobTest.swift index 7899b0d..8b1dcf2 100644 --- a/Tests/FQAuthServerTests/Apple/jobs/SIWAAccountDeletedJobTest.swift +++ b/Tests/SincereAuthServerTests/Apple/jobs/SIWAAccountDeletedJobTest.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import PostgresKit import FluentPostgresDriver import XCTest diff --git a/Tests/FQAuthServerTests/Apple/jobs/SIWAReadyForReverifyScheduledJobTest.swift b/Tests/SincereAuthServerTests/Apple/jobs/SIWAReadyForReverifyScheduledJobTest.swift similarity index 98% rename from Tests/FQAuthServerTests/Apple/jobs/SIWAReadyForReverifyScheduledJobTest.swift rename to Tests/SincereAuthServerTests/Apple/jobs/SIWAReadyForReverifyScheduledJobTest.swift index b2422ea..fcd554f 100644 --- a/Tests/FQAuthServerTests/Apple/jobs/SIWAReadyForReverifyScheduledJobTest.swift +++ b/Tests/SincereAuthServerTests/Apple/jobs/SIWAReadyForReverifyScheduledJobTest.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import PostgresKit import FluentPostgresDriver import XCTest diff --git a/Tests/FQAuthServerTests/Apple/jobs/SIWARefreshTokenJobTest.swift b/Tests/SincereAuthServerTests/Apple/jobs/SIWARefreshTokenJobTest.swift similarity index 99% rename from Tests/FQAuthServerTests/Apple/jobs/SIWARefreshTokenJobTest.swift rename to Tests/SincereAuthServerTests/Apple/jobs/SIWARefreshTokenJobTest.swift index a10d873..c1e99df 100644 --- a/Tests/FQAuthServerTests/Apple/jobs/SIWARefreshTokenJobTest.swift +++ b/Tests/SincereAuthServerTests/Apple/jobs/SIWARefreshTokenJobTest.swift @@ -1,5 +1,5 @@ import Foundation -@testable import FQAuthServer +@testable import SincereAuthServer import XCTest import Vapor import JWTKit diff --git a/Tests/FQAuthServerTests/Apple/stubs/AppleTokenResponse.meaninglessStub.swift b/Tests/SincereAuthServerTests/Apple/stubs/AppleTokenResponse.meaninglessStub.swift similarity index 91% rename from Tests/FQAuthServerTests/Apple/stubs/AppleTokenResponse.meaninglessStub.swift rename to Tests/SincereAuthServerTests/Apple/stubs/AppleTokenResponse.meaninglessStub.swift index ae94147..c3c7a5a 100644 --- a/Tests/FQAuthServerTests/Apple/stubs/AppleTokenResponse.meaninglessStub.swift +++ b/Tests/SincereAuthServerTests/Apple/stubs/AppleTokenResponse.meaninglessStub.swift @@ -1,4 +1,4 @@ -@testable import FQAuthServer +@testable import SincereAuthServer extension AppleTokenResponse { diff --git a/Tests/FQAuthServerTests/CryptoTests.swift b/Tests/SincereAuthServerTests/CryptoTests.swift similarity index 89% rename from Tests/FQAuthServerTests/CryptoTests.swift rename to Tests/SincereAuthServerTests/CryptoTests.swift index 1d14cd3..2033156 100644 --- a/Tests/FQAuthServerTests/CryptoTests.swift +++ b/Tests/SincereAuthServerTests/CryptoTests.swift @@ -1,5 +1,5 @@ import XCTest -@testable import FQAuthServer +@testable import SincereAuthServer final class CryptoTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/RefreshToken/CleanupExpiredRefreshTokenScheduledJobTests.swift b/Tests/SincereAuthServerTests/RefreshToken/CleanupExpiredRefreshTokenScheduledJobTests.swift similarity index 98% rename from Tests/FQAuthServerTests/RefreshToken/CleanupExpiredRefreshTokenScheduledJobTests.swift rename to Tests/SincereAuthServerTests/RefreshToken/CleanupExpiredRefreshTokenScheduledJobTests.swift index 813e14a..2083041 100644 --- a/Tests/FQAuthServerTests/RefreshToken/CleanupExpiredRefreshTokenScheduledJobTests.swift +++ b/Tests/SincereAuthServerTests/RefreshToken/CleanupExpiredRefreshTokenScheduledJobTests.swift @@ -1,6 +1,6 @@ import Foundation import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer import XCTest import FluentPostgresDriver diff --git a/Tests/FQAuthServerTests/RefreshToken/RefreshTokenControllerTests.swift b/Tests/SincereAuthServerTests/RefreshToken/RefreshTokenControllerTests.swift similarity index 98% rename from Tests/FQAuthServerTests/RefreshToken/RefreshTokenControllerTests.swift rename to Tests/SincereAuthServerTests/RefreshToken/RefreshTokenControllerTests.swift index 4fb890c..0ef8afa 100644 --- a/Tests/FQAuthServerTests/RefreshToken/RefreshTokenControllerTests.swift +++ b/Tests/SincereAuthServerTests/RefreshToken/RefreshTokenControllerTests.swift @@ -1,7 +1,7 @@ import Foundation import XCTVapor import XCTest -@testable import FQAuthServer +@testable import SincereAuthServer final class RefreshTokenControllerTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/RefreshToken/RefreshTokenModelTests.swift b/Tests/SincereAuthServerTests/RefreshToken/RefreshTokenModelTests.swift similarity index 96% rename from Tests/FQAuthServerTests/RefreshToken/RefreshTokenModelTests.swift rename to Tests/SincereAuthServerTests/RefreshToken/RefreshTokenModelTests.swift index 789d11b..546cc40 100644 --- a/Tests/FQAuthServerTests/RefreshToken/RefreshTokenModelTests.swift +++ b/Tests/SincereAuthServerTests/RefreshToken/RefreshTokenModelTests.swift @@ -1,7 +1,7 @@ import Foundation import XCTVapor import XCTest -@testable import FQAuthServer +@testable import SincereAuthServer final class RefreshTokenModelTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/RoutesTests.swift b/Tests/SincereAuthServerTests/RoutesTests.swift similarity index 89% rename from Tests/FQAuthServerTests/RoutesTests.swift rename to Tests/SincereAuthServerTests/RoutesTests.swift index 1a2a03e..bab892b 100644 --- a/Tests/FQAuthServerTests/RoutesTests.swift +++ b/Tests/SincereAuthServerTests/RoutesTests.swift @@ -1,4 +1,4 @@ -@testable import FQAuthServer +@testable import SincereAuthServer import XCTVapor import XCTest diff --git a/Tests/FQAuthServerTests/Services/DependencyInjectionTests.swift b/Tests/SincereAuthServerTests/Services/DependencyInjectionTests.swift similarity index 89% rename from Tests/FQAuthServerTests/Services/DependencyInjectionTests.swift rename to Tests/SincereAuthServerTests/Services/DependencyInjectionTests.swift index e9449b0..8627b8a 100644 --- a/Tests/FQAuthServerTests/Services/DependencyInjectionTests.swift +++ b/Tests/SincereAuthServerTests/Services/DependencyInjectionTests.swift @@ -1,7 +1,7 @@ import Foundation import XCTest import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer final class DependencyInjectionTests: XCTestCase { diff --git a/Tests/FQAuthServerTests/asserts/XCTAssertNearlyEqual.swift b/Tests/SincereAuthServerTests/asserts/XCTAssertNearlyEqual.swift similarity index 100% rename from Tests/FQAuthServerTests/asserts/XCTAssertNearlyEqual.swift rename to Tests/SincereAuthServerTests/asserts/XCTAssertNearlyEqual.swift diff --git a/Tests/FQAuthServerTests/asserts/XCTAssertNearlyNow.swift b/Tests/SincereAuthServerTests/asserts/XCTAssertNearlyNow.swift similarity index 100% rename from Tests/FQAuthServerTests/asserts/XCTAssertNearlyNow.swift rename to Tests/SincereAuthServerTests/asserts/XCTAssertNearlyNow.swift diff --git a/Tests/FQAuthServerTests/helpers/Application.resetDatabase.swift b/Tests/SincereAuthServerTests/helpers/Application.resetDatabase.swift similarity index 94% rename from Tests/FQAuthServerTests/helpers/Application.resetDatabase.swift rename to Tests/SincereAuthServerTests/helpers/Application.resetDatabase.swift index e5d31a7..7d2c034 100644 --- a/Tests/FQAuthServerTests/helpers/Application.resetDatabase.swift +++ b/Tests/SincereAuthServerTests/helpers/Application.resetDatabase.swift @@ -1,5 +1,5 @@ import Vapor -@testable import FQAuthServer +@testable import SincereAuthServer import Fluent extension Application { diff --git a/Tests/FQAuthServerTests/helpers/Application.resetQueue.swift b/Tests/SincereAuthServerTests/helpers/Application.resetQueue.swift similarity index 100% rename from Tests/FQAuthServerTests/helpers/Application.resetQueue.swift rename to Tests/SincereAuthServerTests/helpers/Application.resetQueue.swift diff --git a/Tests/FQAuthServerTests/helpers/Queue.nextPayload.swift b/Tests/SincereAuthServerTests/helpers/Queue.nextPayload.swift similarity index 100% rename from Tests/FQAuthServerTests/helpers/Queue.nextPayload.swift rename to Tests/SincereAuthServerTests/helpers/Queue.nextPayload.swift diff --git a/heroku.yml b/heroku.yml index 8e4b545..b2bb6e1 100644 --- a/heroku.yml +++ b/heroku.yml @@ -9,13 +9,13 @@ run: RUN_SCHEDULED_QUEUES_IN_MAIN_PROCESS=YES RUN_QUEUES_IN_MAIN_PROCESS=NO command: - - "/app/FQAuthServer serve --env production --hostname 0.0.0.0 -p $PORT" + - "/app/SincereAuthServer serve --env production --hostname 0.0.0.0 -p $PORT" worker: image: web command: - - "/app/FQAuthServer queues --env production" + - "/app/SincereAuthServer queues --env production" release: image: web command: - - "/app/FQAuthServer migrate -y --env production" + - "/app/SincereAuthServer migrate -y --env production"