Repository navigation
Feature/login caching speedup - #296
Closed
RWL-Dittrich wants to merge 77 commits into
Closed
RWL-Dittrich wants to merge 77 commits into
RWL-Dittrich wants to merge 77 commits into
Conversation
Update to dotnet 10, fix namespaces and code consistency
* First entra implementation * Styling fixes and other dashboard improvements * small frontend improvements and remove email from user fields * Entra App Roles instead of groups * Enhance Entra authentication: throw exceptions for disabled users and UI login restrictions; update group permissions handling in UI * Implement authentication checks across multiple pages: require sign-in for package browsing, details, statistics, and upload instructions * fix test * Update label styles for role synchronization and enable Razor runtime compilation * update claude.md with codebase updates * Enhance upload page authentication messages and remove Razor runtime compilation * Clarify default role claim description in EntraOptions * Update role claim type in Entra authentication options * Log warning on Entra authentication remote failure and simplify error response * Validate token expiry date to ensure it is set in the future * remove unused injected _authOptions in Logout.cshtml.cs * fix: align SymbolController auth fallback with PackagePublishController Agent-Logs-Url: https://github.com/Niverplast/BaGetter/sessions/f1102320-a576-4469-9fdc-d0111f4de964 Co-authored-by: RWL-Dittrich <43466794+RWL-Dittrich@users.noreply.github.com> * Fetch all groups from the DB at once * Remove old implementation plan * feat: add IsAdmin claim to user authentication and update admin check logic * feat: move IsAdmin column to Users table and migrate existing permissions * feat: enhance Entra authentication setup with environment-based cookie policy * feat: add cancellation token support for permission checks in FeedPermissionHandler * feat: centralize cookie name in authentication constants * Apply suggestion: remove include folder packages\ Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Robin Dittrich <43466794+RWL-Dittrich@users.noreply.github.com> * feat: use case-insensitive comparison for AppRoleValue hash set * feat: configure cookie authentication for test server and adjust token expiration handling * Squash migrations Fixed nuget push -k Cleaned up some code Fixed comments * feat: update authentication mode handling to use 'Config' instead of 'None' * feat: update authentication mode in integration tests to use 'Config' * feat: add filtered unique indexes for EntraObjectId and AppRoleValue in User and Group entities. Then recreate migrations * Fix comments * Update CLAUDE.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Robin Dittrich <43466794+RWL-Dittrich@users.noreply.github.com> --------- Signed-off-by: Robin Dittrich <43466794+RWL-Dittrich@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Add https://github.com/forrestchang/andrej-karpathy-skills to CLAUDE.md and add multi-feed-plan.md * fully set up the multi-feed-plan.md for implementation * Finished Claude implementation * bugfixes and improvements * Enhance AGENTS.md with detailed repo layout and project structure for BaGetter * Refactor feed edit panel for improved styling and accessibility * Refactor class names and variable names for consistency and clarity * Add multifeed support for static files by updating static asset paths and introducing FeedStaticFilePathMiddleware * Fix formatting issues in Package.cshtml for consistent tab structure * Fix comment * Add versioning to site.js script for cache busting * Add feedId parameter to statistics service methods and update Statistics page to use model data * Refactor PackageIndexingService to use IFeedService instead of IFeedContext for feed retrieval * Refactor PackageDeletionService to use IFeedService instead of IFeedContext for feed retrieval * Refactor PackageService to use IFeedService for feed retrieval * Add multifeed support for group permissions management * Add FeedAccessGuard for managing feed access permissions in Razor UI * Fix errors * remove multi feed plan * Fix comments * Extract feed request/response types into Models folder
# Conflicts: # src/BaGetter.Core/Indexing/IPackageIndexingService.cs # src/BaGetter.Core/Indexing/PackageIndexingService.cs # src/BaGetter.Core/PackageService.cs # src/BaGetter.Core/Upstream/IUpstreamClient.cs # src/BaGetter.Web/Controllers/PackagePublishController.cs # tests/BaGetter.Core.Tests/Services/PackageServiceTests.cs # tests/BaGetter.Tests/Support/BaGetApplication.cs
The NuGetClient(NuGetClientFactory) constructor (used by UpstreamClientFactory on the V3 path) didn't propagate ServiceIndexUrl, so V3UpstreamClient.GetServiceIndexUrl() returned null and mirrored packages were stored with a null CachedFrom. Expose ServiceIndexUrl on NuGetClientFactory and copy it into NuGetClient in that overload.
Merge/upstream main
SQLite AddForeignKey rebuilds table from designer model — dropped CachedFrom column because snapshot omitted it. Fixed all four providers for consistency.
Fix missing CachedFrom in migration designer snapshots
…y if defaultcredential is specified
Fix delete behavior for CreatedByUser foreign key relationships
add /ping healthcheck
Update liveness probe endpoint to /livez and clarify comment on middleware order
…per user - Apply Post-Redirect-Get in OnPostCreateAsync: redirect to self after create instead of returning Page(), so refresh no longer resubmits the POST and creates duplicate tokens - Carry NewTokenPlaintext and ErrorMessage via [TempData] so they survive the redirect and display exactly once - Reject duplicate token names per user in TokenService.CreateTokenAsync with a pre-check, plus a unique-constraint catch as a race guard - Add unique index on (UserId, Name) for PersonalAccessToken, replacing the non-unique UserId index, with migrations and snapshots for Sqlite, SqlServer, PostgreSql and MySql - Add tests for duplicate-name rejection and same-name-different-user
Fix token page F5 resubmit (PLAT-757) and enforce unique token names per user
…ode icon color - Guard Project URL, Source code and License links with !string.IsNullOrEmpty instead of != null, since the *UrlString properties return string.Empty (never null) when the metadata is absent, so the links rendered as dead links - Render the GitHub logo via a CSS mask filled with currentColor so the Source code icon matches the other icons in both light and dark mode instead of staying black - Add a PackageModel test asserting the URL properties are empty strings when the metadata is absent
…ructions; enhance layout with conditional feed access links
…ce FeedPermissionInput model and update related methods
- BaGetter.Protocol: keep TargetFramework netstandard2.0 so netFx apps can consume it - BaGetterWebApplication sample: restore member-style extension calls (AddSqliteDatabase/AddFileStorage) - BaGetClientIntegrationTests: restore member-style GetResourceUrl extension calls Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Only show package info links when present (PLAT-760) and fix Source code icon color - Guard Project URL, Source code and License links with !string.IsNullOrEmpty instead of != null, since the *UrlString properties return string.Empty (never null) when the metadata is absent, so the links rendered as dead links - Render the GitHub logo via a CSS mask filled with currentColor so the Source code icon matches the other icons in both light and dark mode instead of staying black - Add a PackageModel test asserting the URL properties are empty strings when the metadata is absent * Add CanPushToCurrentFeedAsync method and UI gating for upload tab * Sort feeds with default feed first and add unit test for GetAllFeedsAsync method * Implement Connect page with service index URL and authentication instructions; enhance layout with conditional feed access links * Refactor group permissions management to support bulk saving; introduce FeedPermissionInput model and update related methods * Address PR review comments - BaGetter.Protocol: keep TargetFramework netstandard2.0 so netFx apps can consume it - BaGetterWebApplication sample: restore member-style extension calls (AddSqliteDatabase/AddFileStorage) - BaGetClientIntegrationTests: restore member-style GetResourceUrl extension calls
- Add CanDelete to FeedPermission (+ EF mapping and migrations for Sqlite, SqlServer, PostgreSql and MySql) - Extend PermissionService with CanDeleteAsync and a canDelete grant flag; add FeedPermissionRequirement.Delete and handler case - Add FeedAccessGuard.CanDeleteFromCurrentFeedAsync (fails closed in Config mode and for anonymous users) - Authorize the package delete endpoint on CanDelete instead of Push - Expose explicit unlist, relist and hard-delete on IPackageDeletionService, independent of PackageDeletionBehavior - Package page: Unlist/Delete/Relist actions gated on CanDelete with confirm dialogs; show unlisted versions struck through to managers - Admin Groups page: add a Delete permission checkbox alongside Pull/Push - Add tests for the new permission, access guard, deletion-service relist and manager version visibility Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…handling; add unit tests for feed deletion scenarios
dev to main
Improve tag dropdown styling by adjusting padding and adding border radius
Main to dev
Add support for including unlisted packages in search results and UI
Implement data protection key storage with XML repository
Refactor data protection key storage methods for improved clarity and error handling
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Signed-off-by: Robin Dittrich <43466794+RWL-Dittrich@users.noreply.github.com>
Feature/email notifications
Add support for raw email claim in token validation process
Update application URLs and adjust claim mapping in token validation
fix email message
- Add SortOrder column to Feed with migrations for all four DB providers, autofilling from the previous visible order (default feed first, then by name)
- Order feeds by SortOrder with Name as tiebreak; append new feeds at the end; add ReorderFeedsAsync
- Add drag-to-reorder admin UI (sortablejs) posting to a Reorder handler
- Redirect root route to the first accessible feed by order; keep every feed reachable at /feeds/{slug}
- Expose SortOrder on FeedResponse; add service, page, and migration-upgrade tests
Add admin-controlled feed sort order
- Report the real total match count from DatabaseSearchService instead of the current page size, honoring the documented SearchResponse.TotalHits contract - Expose TotalPages on the feed page model - Replace the Previous/Next pager with a numbered Bootstrap pagination control that keeps the active search and filter state in every page link - Style the pagination for dark mode to match the existing buttons - Cover the total hit count with a test that pages with Take = 1
Feature/page numbering
…or password change scenarios
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.