diff --git a/.github/ISSUE_TEMPLATE/bug_report.yaml b/.github/ISSUE_TEMPLATE/bug_report.yaml
new file mode 100644
index 000000000..275d6a373
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/bug_report.yaml
@@ -0,0 +1,61 @@
+name: Bug Report
+description: File a bug report
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thanks for reporting an issue for Grails framework, please review the task list below before submitting the issue. Your issue report will be closed if the issue is incomplete and the below tasks not completed.
+
+ NOTE: If you are unsure about something and the issue is more of a question a better place to ask questions is on Stack Overflow (https://stackoverflow.com/tags/grails) or Slack (https://slack-signup.grails.org). DO NOT use the issue tracker to ask questions.
+
+ NOTE: if you have questions or issues, [enable debug logging](https://grails-plugins.github.io/grails-spring-security-rest/latest/docs/index.html#_debugging), and include the output in your request.
+ - type: textarea
+ attributes:
+ label: Expected Behavior
+ description: A concise description of what you expected to happen.
+ placeholder: Tell us what should happen
+ validations:
+ required: false
+ - type: textarea
+ attributes:
+ label: Actual Behaviour
+ description: A concise description of what you're experiencing.
+ placeholder: Tell us what happens instead
+ validations:
+ required: false
+ - type: textarea
+ attributes:
+ label: Steps To Reproduce
+ description: Steps to reproduce the behavior.
+ placeholder: |
+ 1. In this environment...
+ 2. With this config...
+ 3. Run '...'
+ 4. See error...
+ validations:
+ required: false
+ - type: textarea
+ attributes:
+ label: Environment Information
+ description: Environment information where the problem occurs.
+ placeholder: |
+ - Operating System:
+ - JDK Version:
+ validations:
+ required: false
+ - type: input
+ id: example
+ attributes:
+ label: Example Application
+ description: Example application link.
+ placeholder: |
+ Link to GitHub repository with an example that reproduces the issue
+ validations:
+ required: false
+ - type: input
+ id: version
+ attributes:
+ label: Version
+ description: Grails version
+ validations:
+ required: true
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml
new file mode 100644
index 000000000..1a40780f3
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/config.yml
@@ -0,0 +1,7 @@
+contact_links:
+ - name: Stack Overflow
+ url: https://stackoverflow.com/tags/grails
+ about: Ask questions on Stack Overflow
+ - name: Grails Slack
+ url: https://grails.slack.com/
+ about: Chat with us on Grails Community Slack.
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/new_feature.yaml b/.github/ISSUE_TEMPLATE/new_feature.yaml
new file mode 100644
index 000000000..6d0aa2617
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/new_feature.yaml
@@ -0,0 +1,13 @@
+name: Feature request
+description: Create a new feature request
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Please describe the feature you want for Grails® framework to implement, before that check if there is already an existing issue to add it.
+ - type: textarea
+ attributes:
+ label: Feature description
+ placeholder: Tell us more about the feature you would like for Grails® framework to have and what problem is it going to solve
+ validations:
+ required: true
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/other.yaml b/.github/ISSUE_TEMPLATE/other.yaml
new file mode 100644
index 000000000..a593ab901
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/other.yaml
@@ -0,0 +1,8 @@
+name: Other
+description: Something different
+body:
+ - type: textarea
+ attributes:
+ label: Issue description
+ validations:
+ required: true
\ No newline at end of file
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index 000000000..858cb2cca
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,24 @@
+version: 2
+updates:
+ - package-ecosystem: gradle
+ directory: "/"
+ schedule:
+ interval: daily
+ open-pull-requests-limit: 10
+ target-branch: 4.0.x
+ labels:
+ - "type: dependency upgrade"
+ ignore:
+ - dependency-name: "*"
+ update-types: ["version-update:semver-major", "version-update:semver-minor"]
+ - package-ecosystem: gradle
+ directory: "/"
+ schedule:
+ interval: daily
+ open-pull-requests-limit: 10
+ target-branch: 3.3.x
+ labels:
+ - "type: dependency upgrade"
+ ignore:
+ - dependency-name: "*"
+ update-types: ["version-update:semver-major", "version-update:semver-minor"]
\ No newline at end of file
diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml
new file mode 100644
index 000000000..76d53db50
--- /dev/null
+++ b/.github/release-drafter.yml
@@ -0,0 +1,126 @@
+name-template: $RESOLVED_VERSION
+tag-template: v$RESOLVED_VERSION
+pull-request:
+ title-templates:
+ fix: '🐛 $TITLE (#$NUMBER)'
+ feat: '🚀 $TITLE (#$NUMBER)'
+ default: '$TITLE (#$NUMBER)'
+autolabeler:
+ - label: 'bug'
+ branch:
+ - '/fix\/.+/'
+ title:
+ - '/fix/i'
+ - label: 'feature'
+ branch:
+ - '/feature\/.+/'
+ title:
+ - '/feat/i'
+ - label: 'documentation'
+ branch:
+ - '/docs\/.+/'
+ title:
+ - '/docs/i'
+ - label: 'maintenance'
+ branch:
+ - '/(chore|refactor|style|test|ci|perf|build|deps)\/.+/'
+ title:
+ - '/(chore|refactor|style|test|ci|perf|build|deps)/i'
+ - label: 'chore'
+ branch:
+ - '/chore\/.+/'
+ title:
+ - '/chore/i'
+ - label: 'refactor'
+ branch:
+ - '/refactor\/.+/'
+ title:
+ - '/refactor/i'
+ - label: 'style'
+ branch:
+ - '/style\/.+/'
+ title:
+ - '/style/i'
+ - label: 'test'
+ branch:
+ - '/test\/.+/'
+ title:
+ - '/test/i'
+ - label: 'ci'
+ branch:
+ - '/ci\/.+/'
+ title:
+ - '/ci/i'
+ - label: 'perf'
+ branch:
+ - '/perf\/.+/'
+ title:
+ - '/perf/i'
+ - label: 'build'
+ branch:
+ - '/build\/.+/'
+ title:
+ - '/build/i'
+ - label: 'deps'
+ branch:
+ - '/deps\/.+/'
+ title:
+ - '/deps/i'
+ - label: 'revert'
+ branch:
+ - '/revert\/.+/'
+ title:
+ - '/revert/i'
+categories:
+ - title: '🚀 Features'
+ labels:
+ - 'feat'
+ - "type: enhancement"
+ - "type: new feature"
+ - "type: major"
+ - title: '🐛 Bug Fixes'
+ labels:
+ - 'fix'
+ - "type: improvement"
+ - "type: bug"
+ - "type: minor"
+ - title: '📚 Documentation'
+ labels:
+ - 'docs'
+ - title: '🔧 Maintenance'
+ labels:
+ - 'chore'
+ - 'refactor'
+ - 'style'
+ - 'test'
+ - 'ci'
+ - 'perf'
+ - 'build'
+ - 'deps'
+ - "type: dependency upgrade"
+ - "dependencies"
+ - "type: ci"
+ - "type: build"
+ - title: '⏪ Reverts'
+ labels:
+ - 'revert'
+change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
+version-resolver:
+ major:
+ labels:
+ - 'type: major'
+ minor:
+ labels:
+ - 'type: minor'
+ patch:
+ labels:
+ - 'type: patch'
+ default: patch
+template: |
+ ## What's Changed
+
+ $CHANGES
+
+ ## Contributors
+
+ $CONTRIBUTORS
\ No newline at end of file
diff --git a/.github/renovate.json b/.github/renovate.json
new file mode 100644
index 000000000..8d829c091
--- /dev/null
+++ b/.github/renovate.json
@@ -0,0 +1,69 @@
+{
+ "extends": [
+ "config:base"
+ ],
+ "labels": ["type: dependency upgrade"],
+ "packageRules": [
+ {
+ "matchPackagePatterns": ["*"],
+ "allowedVersions": "!/SNAPSHOT$/"
+ },
+ {
+ "matchPackagePatterns": [
+ "^org\\.codehaus\\.groovy"
+ ],
+ "groupName": "groovy monorepo"
+ },
+ {
+ "matchPackagePatterns": [
+ "^org\\.seleniumhq"
+ ],
+ "groupName": "selenium monorepo"
+ },
+ {
+ "matchPackagePatterns": [
+ "^org\\.spockframework"
+ ],
+ "groupName": "spock framework monorepo"
+ },
+ {
+ "matchPackageNames": [
+ "org.grails:grails-bom",
+ "org.grails:grails-bootstrap",
+ "org.grails:grails-codecs",
+ "org.grails:grails-console",
+ "org.grails:grails-core",
+ "org.grails:grails-databinding",
+ "org.grails:grails-dependencies",
+ "org.grails:grails-docs",
+ "org.grails:grails-encoder",
+ "org.grails:grails-gradle-model",
+ "org.grails:grails-logging",
+ "org.grails:grails-plugin-codecs",
+ "org.grails:grails-plugin-controllers",
+ "org.grails:grails-plugin-databinding",
+ "org.grails:grails-plugin-datasource",
+ "org.grails:grails-plugin-domain-class",
+ "org.grails:grails-plugin-i18n",
+ "org.grails:grails-plugin-interceptors",
+ "org.grails:grails-plugin-mimetypes",
+ "org.grails:grails-plugin-rest",
+ "org.grails:grails-plugin-services",
+ "org.grails:grails-plugin-url-mappings",
+ "org.grails:grails-plugin-url-validation",
+ "org.grails:grails-shell",
+ "org.grails:grails-spring",
+ "org.grails:grails-test",
+ "org.grails:grails-validation",
+ "org.grails:grails-web",
+ "org.grails:grails-web-boot",
+ "org.grails:grails-web-common",
+ "org.grails:grails-web-databinding",
+ "org.grails:grails-web-fileupload",
+ "org.grails:grails-web-mvc",
+ "org.grails:grails-web-url-mappings"
+ ],
+ "groupName": "grails monorepo"
+ }
+ ]
+}
\ No newline at end of file
diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml
index 31b245b69..7bfabc72d 100644
--- a/.github/workflows/gradle.yml
+++ b/.github/workflows/gradle.yml
@@ -2,32 +2,48 @@ name: Java CI
on:
push:
branches:
- - '[3-9].[0-9].x'
+ - '[5-9].[0-9].x'
pull_request:
branches:
- - '[3-9].[0-9].x'
+ - '[5-9].[0-9].x'
workflow_dispatch:
jobs:
- test:
+ core-tests:
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
- env:
- WORKSPACE: ${{ github.workspace }}
steps:
- - uses: actions/checkout@v3
- - name: Set up JDK
- uses: actions/setup-java@v3
- with:
- distribution: 'adopt'
- java-version: 8
+ - name: Checkout
+ uses: actions/checkout@v4
+ - name: Wrapper Integrity
+ uses: gradle/actions/wrapper-validation@v3
+ - name: Setup Java
+ uses: actions/setup-java@v4
+ with: { java-version: 11, distribution: temurin }
- name: Run Tests
- if: github.event_name == 'pull_request'
- id: tests
- uses: gradle/gradle-build-action@v2
+ uses: gradle/actions/setup-gradle@v3
+ env:
+ GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
with:
arguments: |
- :spring-security-rest:check
+ check
+ -Dgeb.env=chromeHeadless
+ build:
+ if: github.event_name == 'push'
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v4
+ - name: Wrapper Integrity
+ uses: gradle/wrapper-validation-action@v2
+ - name: Setup Java
+ uses: actions/setup-java@v4
+ with: { java-version: 11, distribution: temurin }
+ - name: Run Build
+ id: build
+ uses: gradle/actions/setup-gradle@v3
env:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
- GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }}
- GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }}
\ No newline at end of file
+ with:
+ arguments: |
+ check
+ -Dgeb.env=chromeHeadless
\ No newline at end of file
diff --git a/.github/workflows/release-notes.yml b/.github/workflows/release-notes.yml
new file mode 100644
index 000000000..b95fe2a8d
--- /dev/null
+++ b/.github/workflows/release-notes.yml
@@ -0,0 +1,51 @@
+name: Changelog
+on:
+ issues:
+ types: [closed,reopened]
+ push:
+ branches:
+ - '[5-9].[0-9].x'
+ pull_request:
+ types: [opened, reopened, synchronize]
+ pull_request_target:
+ types: [opened, reopened, synchronize]
+ workflow_dispatch:
+jobs:
+ release_notes:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ - name: Check if it has release drafter config file
+ id: check_release_drafter
+ run: |
+ has_release_drafter=$([ -f .github/release-drafter.yml ] && echo "true" || echo "false")
+ echo "has_release_drafter=${has_release_drafter}" >> $GITHUB_OUTPUT
+ - name: Extract branch name
+ id: extract_branch
+ run: echo "value=${GITHUB_REF:11}" >> $GITHUB_OUTPUT
+ # If it has release drafter:
+ - uses: release-drafter/release-drafter@v6
+ if: steps.check_release_drafter.outputs.has_release_drafter == 'true'
+ env:
+ GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
+ with:
+ commitish: ${{ steps.extract_branch.outputs.value }}
+ # Otherwise:
+ - name: Export Gradle Properties
+ if: steps.check_release_drafter.outputs.has_release_drafter == 'false'
+ uses: micronaut-projects/github-actions/export-gradle-properties@master
+ - uses: micronaut-projects/github-actions/release-notes@master
+ if: steps.check_release_drafter.outputs.has_release_drafter == 'false'
+ id: release_notes
+ with:
+ token: ${{ secrets.GH_TOKEN }}
+ - uses: ncipollo/release-action@v1
+ if: steps.check_release_drafter.outputs.has_release_drafter == 'false' && steps.release_notes.outputs.generated_changelog == 'true'
+ with:
+ allowUpdates: true
+ commit: ${{ steps.release_notes.outputs.current_branch }}
+ draft: true
+ name: ${{ env.title }} ${{ steps.release_notes.outputs.next_version }}
+ tag: v${{ steps.release_notes.outputs.next_version }}
+ bodyFile: CHANGELOG.md
+ token: ${{ secrets.GH_TOKEN }}
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 04cb4e52b..fb86fbbc7 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -2,33 +2,66 @@ name: Release
on:
release:
types: [published]
- workflow_dispatch:
+env:
+ GIT_USER_NAME: 'grails-build'
+ GIT_USER_EMAIL: 'grails-build@users.noreply.github.com'
jobs:
release:
runs-on: ubuntu-latest
- env:
- WORKSPACE: ${{ github.workspace }}
steps:
- - uses: actions/checkout@v3
- - name: Set up JDK
- uses: actions/setup-java@v3
- with:
- distribution: 'adopt'
- java-version: 8
- - name: Publish
+ - name: Checkout
+ uses: actions/checkout@v4
+ - name: Wrapper Integrity
+ uses: gradle/actions/wrapper-validation@v3
+ - name: Setup Java
+ uses: actions/setup-java@v4
+ with: { java-version: 11, distribution: temurin }
+ - name: Get the current release version
+ id: release_version
+ run: echo "release_version=${GITHUB_REF:11}" >> $GITHUB_OUTPUT
+ - name: Tag the release version
+ uses: micronaut-projects/github-actions/pre-release@master
+ - name: Generate secring file
+ env:
+ SECRING_FILE: ${{ secrets.SECRING_FILE }}
+ run: echo $SECRING_FILE | base64 -d > ${{ github.workspace }}/secring.gpg
+ - name: Publish to Sonatype
+ id: publish_to_sonatype
+ uses: gradle/actions/setup-gradle@v3
env:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }}
GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }}
- ARTIFACTORY_USERNAME: ${{ secrets.ARTIFACTORY_USERNAME }}
- ARTIFACTORY_PASSWORD: ${{ secrets.ARTIFACTORY_PASSWORD }}
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
SONATYPE_STAGING_PROFILE_ID: ${{ secrets.SONATYPE_STAGING_PROFILE_ID }}
+ SONATYPE_NEXUS_URL: ${{ secrets.SONATYPE_NEXUS_URL }}
SIGNING_KEY: ${{ secrets.SIGNING_KEY }}
SIGNING_PASSPHRASE: ${{ secrets.SIGNING_PASSPHRASE }}
SECRING_FILE: ${{ secrets.SECRING_FILE }}
- run: |
- echo $SECRING_FILE | base64 -d > secring.gpg
- echo "Publishing Artifacts"
- (set -x; ./gradlew -Psigning.secretKeyRingFile="${WORKSPACE}/secring.gpg" publish publishToSonatype closeAndReleaseSonatypeStagingRepository --no-daemon)
+ with:
+ arguments: |
+ -Psigning.secretKeyRingFile=${{ github.workspace }}/secring.gpg
+ publishToSonatype
+ closeAndReleaseSonatypeStagingRepository
+ - name: Generate Documentation
+ if: success()
+ uses: gradle/actions/setup-gradle@v3
+ env:
+ GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
+ with:
+ arguments: docs
+ - name: Publish Documentation to Github Pages
+ if: success()
+ uses: micronaut-projects/github-pages-deploy-action@grails
+ env:
+ BRANCH: gh-pages
+ COMMIT_EMAIL: ${{ env.GIT_USER_EMAIL }}
+ COMMIT_NAME: ${{ env.GIT_USER_NAME }}
+ FOLDER: build/docs
+ GH_TOKEN: ${{ secrets.GH_TOKEN }}
+ SKIP_SNAPSHOT: ${{ contains(steps.release_version.outputs.release_version, 'M') }}
+ VERSION: ${{ steps.release_version.outputs.release_version }}
+ - name: Run post-release
+ if: steps.publish_to_sonatype.outcome == 'success'
+ uses: micronaut-projects/github-actions/post-release@master
\ No newline at end of file
diff --git a/.sdkmanrc b/.sdkmanrc
new file mode 100644
index 000000000..59bd568a9
--- /dev/null
+++ b/.sdkmanrc
@@ -0,0 +1,6 @@
+# Enable auto-env through the sdkman_auto_env config - https://sdkman.io/usage#env
+java=11.0.24-tem
+grails=6.1.1
+gradle=7.6.3
+groovy=3.0.15
+
diff --git a/LICENSE b/LICENSE
index c5e4c8d0f..261eeb9e9 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,14 +1,201 @@
-Copyright 2013-${year} ${name} <${email}>
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
- http://www.apache.org/licenses/LICENSE-2.0
+ 1. Definitions.
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
\ No newline at end of file
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/README.md b/README.md
index 2c075f1dc..18697c947 100644
--- a/README.md
+++ b/README.md
@@ -1,84 +1,20 @@
Spring Security REST for Grails
===========================
-[![Build Status](https://travis-ci.org/grails-plugins/grails-spring-security-rest.svg?branch=develop)](https://travis-ci.org/github/grails-plugins/grails-spring-security-rest)
-[![Latest version](https://api.bintray.com/packages/grails/plugins/spring-security-rest/images/download.svg) ](https://bintray.com/grails/plugins/spring-security-rest/_latestVersion)
-[![Known Vulnerabilities](https://snyk.io/test/github/alvarosanchez/grails-spring-security-rest/develop/badge.svg)](https://snyk.io/test/github/alvarosanchez/grails-spring-security-rest)
+[![Java CI](https://github.com/grails/grails-spring-security-rest/actions/workflows/gradle.yml/badge.svg?event=push)](https://github.com/grails/grails-spring-security-rest/actions/workflows/gradle.yml)
Grails plugin to implement a stateless, token-based, RESTful authentication
-using Spring Security. Sponsored and supported by [Object Computing Inc.](http://www.ociweb.com)
+using Spring Security.
Documentation:
* [User guide](https://grails-plugins.github.io/grails-spring-security-rest/latest/docs/).
* [Javadoc](https://grails-plugins.github.io/grails-spring-security-rest/latest/docs/gapi/).
-Companies using this plugin
----------------------------
-
-* [CloudCard Online Photo Submission](http://www.onlinephotosubmission.com)
-* [HealthReveal](http://www.healthreveal.com)
-* [Murallo](http://murallo.com)
-* [Odobo](http://www.odobo.com)
-* [Sharptop Software](http://www.sharptop.io)
-* [Zaccak Solutions](http://www.zaccak.com)
-* [Lyshnia Limited](https://lyshnia.com)
-* [Wiz Panda](https://www.wizpanda.com)
-* [Zana Technologies GmbH](https://zana.com)
-
-_Are you using this plugin and want to be listed here? [Include your company yourself](https://github.com/alvarosanchez/grails-spring-security-rest/edit/develop/README.md)_.
-
-Support
+Branch Structure
-------
-* General questions should go to the [`#spring-security-rest` channel in Slack](https://grails.slack.com/messages/spring-security-rest).
-* You can also find answers at [StackOverflow](http://stackoverflow.com/questions/tagged/grails+spring-security-rest). Label your questions with both the `grails` and `spring-security-rest` tags.
-* If you've got issues, report them [here in GitHub](https://grails-plugins.github.io/grails-spring-security-rest/issues).
-* If you need commercial support, you can ask [OCI](http://www.ociweb.com) at [info AT ociweb DOT com](mailto:infoATociwebDOTcom).
-
-**NOTE**: if you have questions or issues, [enable debug logging](https://grails-plugins.github.io/grails-spring-security-rest/latest/docs/index.html#_debugging),
-and include the output in your request.
-
-
-Contributors
-------------
-
-* [Aaron Eischeid](https://github.com/aeischeid).
-* [A.J. Brown](https://github.com/ajbrown).
-* [Andrew Wharton](https://github.com/andrew-wharton).
-* [André Schmid](https://github.com/andrehschmid).
-* [Alonso Torres](https://github.com/Alotor).
-* [Bartek Gawel](https://github.com/bgawel).
-* [Bob Finch](https://github.com/rbfinch).
-* [Bobby Warner](https://github.com/bobbywarner).
-* [Burt Beckwith](https://github.com/burtbeckwith).
-* [Conall Laverty](https://github.com/conalllaverty).
-* [Dennie de Lange](https://github.com/tkvw).
-* [Dhiraj Mahapatro](https://github.com/dmahapatro).
-* [Donal Murtagh](https://github.com/domurtag).
-* [Greg Pagendam-Turner](https://github.com/liftyourgame).
-* [James Kleeh](https://github.com/Schlogen).
-* [Jonas Ladenfors](https://github.com/jladenfors).
-* [Jorge Aguilera](https://github.com/jagedn).
-* [Ludovic Ronsin](https://github.com/zeludo).
-* [Lukasz Wozniak](https://github.com/stlhrt).
-* [Marcos Carceles](https://github.com/marcos-carceles).
-* [Michał Lula](https://github.com/michallula).
-* [Michal Szulc](https://github.com/majkelo).
-* [Nick Larson](https://github.com/nllarson).
-* [Philipp Eschenbach](https://github.com/peh).
-* [Philippe Gibert](https://github.com/giboow).
-* [Polawat Phetra](https://github.com/pphetra).
-* [Rafael Vargas](https://github.com/rvargas).
-* [Sean Brady](https://github.com/sbrady).
-* [Sergey Shatunov](https://github.com/Prototik).
-* [Sergio del Amo](https://github.com/sdelamo).
-* [Shashank Agrawal](https://github.com/sagrawal31).
-* [Svante Rohlin](https://github.com/srohlin).
-* [Tomás Crespo](https://github.com/tcrespog).
-* [Tony Erskine](https://github.com/tonyerskine).
-* [Victor Saar](https://github.com/vsaar).
-
-License
--------
+- `6.0.x` compatible with Grails 7
+- `5.0.x` compatible with Grails 6
+- `3.0.x` compatible with Grails 4 & 5
+- `2.0.x` compatible with Grails 3
-This software is licensed under the terms of the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0.html)
diff --git a/apply-gitflow.sh b/apply-gitflow.sh
deleted file mode 100755
index 314fcffc1..000000000
--- a/apply-gitflow.sh
+++ /dev/null
@@ -1,10 +0,0 @@
-#!/bin/sh
-
-git config gitflow.branch.master 'master'
-git config gitflow.branch.develop 'develop'
-git config gitflow.prefix.feature 'feature/'
-git config gitflow.prefix.release 'release/'
-git config gitflow.prefix.hotfix 'hotfix/'
-git config gitflow.prefix.support 'support/'
-git config gitflow.prefix.versiontag ''
-git config gitflow.feature.finish.rebase true
\ No newline at end of file
diff --git a/build.gradle b/build.gradle
index ab72efea9..5d5905001 100644
--- a/build.gradle
+++ b/build.gradle
@@ -5,13 +5,15 @@ buildscript {
}
dependencies {
classpath "org.grails:grails-gradle-plugin:$grailsGradlePluginVersion"
+ classpath "io.github.gradle-nexus:publish-plugin:$gradlePublishPlugin"
classpath 'com.adarshr:gradle-test-logger-plugin:4.0.0'
}
}
plugins {
id 'idea'
- id 'io.github.gradle-nexus.publish-plugin' version '1.3.0'
+ id 'io.github.gradle-nexus.publish-plugin' version "$gradlePublishPlugin"
+ id "com.github.ben-manes.versions" version "0.39.0"
}
allprojects {
@@ -19,50 +21,24 @@ allprojects {
}
def pluginProjects = ['spring-security-rest', 'spring-security-rest-memcached', 'spring-security-rest-redis', 'spring-security-rest-grailscache', 'spring-security-rest-gorm']
-def profileProjects = ['spring-security-rest-testapp-profile']
-def publishedProjects = pluginProjects + profileProjects
+def publishedProjects = pluginProjects
-ext {
- grailsVersion = project.grailsVersion
- isSnapshot = projectVersion.endsWith('SNAPSHOT')
- isReleaseVersion = !isSnapshot
-}
-
-ext."signing.keyId" = project.hasProperty("signing.keyId") ? project.getProperty('signing.keyId') : System.getenv('SIGNING_KEY')
-ext."signing.password" = project.hasProperty("signing.password") ? project.getProperty('signing.password') : System.getenv('SIGNING_PASSPHRASE')
-ext."signing.secretKeyRingFile" = project.hasProperty("signing.secretKeyRingFile") ? project.getProperty('signing.secretKeyRingFile') : "${System.properties['user.home']}${File.separator}.gnupg${File.separator}secring.gpg"
-
-nexusPublishing {
- repositories {
- sonatype {
- def ossUser = System.getenv("SONATYPE_USERNAME") ?: project.hasProperty("sonatypeOssUsername") ? project.sonatypeOssUsername : ''
- def ossPass = System.getenv("SONATYPE_PASSWORD") ?: project.hasProperty("sonatypeOssPassword") ? project.sonatypeOssPassword : ''
- def ossStagingProfileId = System.getenv("SONATYPE_STAGING_PROFILE_ID") ?: project.hasProperty("sonatypeOssStagingProfileId") ? project.sonatypeOssStagingProfileId : ''
- nexusUrl = uri("https://s01.oss.sonatype.org/service/local/")
- snapshotRepositoryUrl = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
- username = ossUser
- password = ossPass
- stagingProfileId = ossStagingProfileId
- useStaging = isReleaseVersion
- }
- }
- transitionCheckOptions {
- maxRetries.set(60)
- delayBetween.set(java.time.Duration.ofMillis(4000))
- }
-}
+version project.projectVersion
subprojects { Project project ->
- group "org.grails.plugins"
+ group projectGroup
version projectVersion
+ ext {
+ grailsVersion = project.grailsVersion
+ isSnapshot = version.endsWith('SNAPSHOT')
+ }
+
repositories {
mavenCentral()
maven { url "https://repo.grails.org/grails/core" }
}
- if (project.name != "spring-security-rest-docs" &&
- project.name != "spring-security-rest-testapp-profile" &&
- !project.name.startsWith("build") ) {
+ if (project.name != "spring-security-rest-docs" && !project.name.startsWith("build") ) {
apply plugin: "org.grails.grails-plugin"
}
@@ -72,7 +48,7 @@ subprojects { Project project ->
if (project.name in pluginProjects) {
- sourceCompatibility = targetCompatibility = 1.8
+ sourceCompatibility = targetCompatibility = JavaVersion.toVersion(11)
apply plugin: "java-library"
@@ -105,89 +81,31 @@ subprojects { Project project ->
}
}
- if (project.name in profileProjects) {
- apply plugin: "org.grails.grails-profile"
+ if (project.name in publishedProjects) {
+ apply from: rootProject.file("gradle/publishing.gradle")
}
+}
- if (project.name in publishedProjects && project.name != "spring-security-rest-docs" &&
- project.name != "spring-security-rest-testapp-profile") {
- apply plugin: 'maven-publish'
- apply plugin: 'signing'
- publishing {
-
- repositories {
- maven {
- credentials {
- def u = System.getenv("ARTIFACTORY_USERNAME") ?: project.hasProperty("artifactoryPublishUsername") ? project.artifactoryPublishUsername : ''
- def p = System.getenv("ARTIFACTORY_PASSWORD") ?: project.hasProperty("artifactoryPublishPassword") ? project.artifactoryPublishPassword : ''
- username = u
- password = p
- }
- if (isSnapshot) {
- url "https://repo.grails.org/grails/plugins3-snapshots-local"
- } else {
- url "https://repo.grails.org/grails/plugins3-releases-local"
- }
- }
- }
-
- publications {
- mavenRelease(MavenPublication) {
-
- groupId = project.group
- artifactId = project.name
- version = project.version
-
- from components.java
-
- artifact sourcesJar
- artifact javadocJar
-
- pom {
- name = 'Spring Security REST plugin'
- description = 'Grails plugin to implement token-based, RESTful authentication using Spring Security'
- url = 'https://github.com/grails/grails-spring-security-rest'
- licenses {
- license {
- name = 'The Apache License, Version 2.0'
- url = 'https://www.apache.org/licenses/LICENSE-2.0.txt'
- }
- }
- developers {
- developer {
- id = 'alvarosanchez'
- name = 'Alvaro Sanchez-Mariscal'
- email = ''
- }
- developer {
- id = 'jameskleeh'
- name = 'James Kleeh'
- email = ''
- }
- }
- scm {
- connection = 'scm:git:https://github.com/grails/grails-spring-security-rest.git'
- developerConnection = 'scm:git:https://github.com/grails/grails-spring-security-rest.git'
- url = 'https://github.com/grails/grails-spring-security-rest/tree/3.0.x'
- }
- }
- }
+apply from: rootProject.file("gradle/docs.gradle")
+
+if (project.hasProperty('release')) {
+ nexusPublishing {
+ repositories {
+ sonatype {
+ def ossUser = System.getenv("SONATYPE_USERNAME") ?: project.hasProperty("sonatypeOssUsername") ? project.sonatypeOssUsername : ''
+ def ossPass = System.getenv("SONATYPE_PASSWORD") ?: project.hasProperty("sonatypeOssPassword") ? project.sonatypeOssPassword : ''
+ def ossStagingProfileId = System.getenv("SONATYPE_STAGING_PROFILE_ID") ?: project.hasProperty("sonatypeOssStagingProfileId") ? project.sonatypeOssStagingProfileId : ''
+ nexusUrl = uri("https://s01.oss.sonatype.org/service/local/")
+ snapshotRepositoryUrl = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
+ username = ossUser
+ password = ossPass
+ stagingProfileId = ossStagingProfileId
}
}
-
- signing {
- sign publishing.publications.mavenRelease
- }
}
}
-task aggregateGroovyDoc(type: Groovydoc) {
- def groovyDocProjects = subprojects.findAll { it.name in pluginProjects }
- group = JavaBasePlugin.DOCUMENTATION_GROUP
-
- dependsOn groovyDocProjects.groovydoc
- source groovyDocProjects.groovydoc.source
- destinationDir file("${buildDir}/docs/groovydoc")
- classpath = files(groovyDocProjects.groovydoc.classpath)
- groovyClasspath = files(groovyDocProjects.groovydoc.groovyClasspath)
+//do not generate extra load on Nexus with new staging repository if signing fails
+tasks.withType(io.github.gradlenexus.publishplugin.InitializeNexusStagingRepository).configureEach {
+ shouldRunAfter(tasks.withType(Sign))
}
\ No newline at end of file
diff --git a/doc.sh b/doc.sh
deleted file mode 100755
index a3f875d03..000000000
--- a/doc.sh
+++ /dev/null
@@ -1,52 +0,0 @@
-#!/bin/bash
-set -e
-set -x
-
-if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then
-
- ./gradlew asciidoctor aggregateGroovyDoc
-
- version=`cat build.gradle | grep "version \"" | sed -n 's/^[ \t]*version\ "//pg' | sed -n 's/"//pg'`
- echo "Preparing release of version $version"
-
- echo "Configuring git with name ${GIT_NAME} and email ${GIT_EMAIL}"
- git config --global user.name "$GIT_NAME"
- git config --global user.email "$GIT_EMAIL"
- git config --global credential.helper "store --file=~/.git-credentials"
- echo "https://$GH_TOKEN:@github.com" > ~/.git-credentials
-
- git clone --quiet --branch=gh-pages https://${GH_TOKEN}@github.com/${TRAVIS_REPO_SLUG}.git gh-pages > /dev/null
-
- cd gh-pages
-
- ./gradlew generateIndex
-
- # If there is a tag present then this becomes the latest
- if [[ -n $TRAVIS_TAG ]]; then
- rm -rf latest/
- mkdir -p latest/docs/gapi
- cp -r ../spring-security-rest-docs/build/asciidoc/html5/. ./latest/docs
- cp -r ../build/docs/groovydoc/. latest/docs/gapi
- git add latest/*
-
- rm -rf "$version"
- mkdir -p "$version/docs/gapi"
- cp -r ../spring-security-rest-docs/build/asciidoc/html5/. "$version/docs"
- cp -r ../build/docs/groovydoc/. "$version/docs/gapi"
- git add "$version/*"
- fi
-
- if [[ $TRAVIS_BRANCH == 'develop' && $TRAVIS_REPO_SLUG == 'alvarosanchez/grails-spring-security-rest' ]]; then
- rm -rf next/
- mkdir -p next/docs/gapi
- cp -r ../spring-security-rest-docs/build/asciidoc/html5/. ./next/docs
- cp -r ../build/docs/groovydoc/. next/docs/gapi
- git add next/*
- fi
-
- git commit -a -m "Updating docs for Travis build: https://travis-ci.org/$TRAVIS_REPO_SLUG/builds/$TRAVIS_BUILD_ID"
- git push origin HEAD
- cd ..
- rm -rf gh-pages
-
-fi
diff --git a/gradle.properties b/gradle.properties
index 666d74c4f..85e813ed0 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -1,4 +1,14 @@
+projectGroup=org.grails.plugins
projectVersion=5.0.0-SNAPSHOT
-grailsVersion=5.3.2
-grailsGradlePluginVersion=5.3.0
-springSecurityCoreVersion=5.3.0
+grailsVersion=6.1.1
+grailsGradlePluginVersion=6.1.1
+gradlePublishPlugin=1.3.0
+springSecurityCoreVersion=6.1.1
+pac4jVersion=5.7.2
+jackson.version=2.15.0
+
+# Publish Information
+projectUrl=https://github.com/grails/grails-spring-security-rest
+scmConnection=scm:git:https://github.com/grails/grails-spring-security-rest.git
+scmDeveloperConnection=scm:git:https://github.com/grails/grails-spring-security-rest.git
+scmUrl=https://github.com/grails/grails-spring-security-rest/tree/5.0.x
\ No newline at end of file
diff --git a/gradle/docs.gradle b/gradle/docs.gradle
new file mode 100644
index 000000000..55979f14f
--- /dev/null
+++ b/gradle/docs.gradle
@@ -0,0 +1,43 @@
+tasks.register('cleanDocs', Delete) {
+ delete file("${rootProject.buildDir}/docs")
+}
+
+tasks.register('aggregateGroovyApiDoc', Groovydoc) {
+ def groovyDocProjects = subprojects.findAll { it.name in ['spring-security-rest', 'spring-security-rest-memcached', 'spring-security-rest-redis', 'spring-security-rest-grailscache', 'spring-security-rest-gorm'] }
+ dependsOn = [tasks.named('cleanDocs')] + groovyDocProjects.collect { it.tasks.named('groovydoc') }
+
+ description = 'Generates Groovy API Documentation for all plugin projects under rootDir/gapi'
+
+ group = JavaBasePlugin.DOCUMENTATION_GROUP
+ access = GroovydocAccess.PROTECTED
+ includeAuthor = false
+ includeMainForScripts = true
+ processScripts = true
+ source = groovyDocProjects.groovydoc.source
+ destinationDir = file("${rootProject.buildDir}/docs/gapi")
+ classpath = files(groovyDocProjects.groovydoc.classpath)
+ groovyClasspath = files(groovyDocProjects.groovydoc.groovyClasspath)
+}
+
+tasks.register('docs') {
+ group = JavaBasePlugin.DOCUMENTATION_GROUP
+ dependsOn = ['aggregateGroovyApiDoc', 'spring-security-rest-docs:asciidoctor']
+ finalizedBy 'copyAsciiDoctorDocs', 'ghPagesRootIndexPage'
+}
+
+tasks.register('copyAsciiDoctorDocs', Copy) {
+ group = JavaBasePlugin.DOCUMENTATION_GROUP
+ dependsOn = ['docs']
+ from "${rootProject.allprojects.find { it.name == 'spring-security-rest-docs'}.projectDir}/build"
+ includes = ['docs/**']
+ into rootProject.buildDir
+ includeEmptyDirs = false
+}
+
+tasks.register('ghPagesRootIndexPage', Copy) {
+ group = 'documentation'
+ dependsOn = ['docs']
+ from file("${rootProject.allprojects.find { it.name == 'spring-security-rest-docs'}.projectDir}/src/docs/index.tmpl")
+ into layout.buildDirectory
+ rename 'index.tmpl', 'index.html'
+}
\ No newline at end of file
diff --git a/gradle/publishing.gradle b/gradle/publishing.gradle
new file mode 100644
index 000000000..47db21109
--- /dev/null
+++ b/gradle/publishing.gradle
@@ -0,0 +1,72 @@
+apply plugin: 'maven-publish'
+apply plugin: 'signing'
+
+ext {
+ isReleaseVersion = !version.toString().endsWith("SNAPSHOT")
+}
+
+publishing {
+ publications {
+ maven(MavenPublication) {
+ artifactId = project.name
+ groupId = project.group
+ version = project.version
+
+ from components.java
+
+ artifact sourcesJar
+ artifact javadocJar
+
+ pom {
+ name = 'Spring Security REST plugin'
+ description = 'Grails plugin to implement token-based, RESTful authentication using Spring Security'
+ url = project.projectUrl
+ licenses {
+ license {
+ name = 'The Apache License, Version 2.0'
+ url = 'https://www.apache.org/licenses/LICENSE-2.0.txt'
+ }
+ }
+ developers {
+ developer {
+ id = 'alvarosanchez'
+ name = 'Alvaro Sanchez-Mariscal'
+ email = ''
+ }
+ developer {
+ id = 'jameskleeh'
+ name = 'James Kleeh'
+ email = ''
+ }
+ developer {
+ id = 'jdaugherty'
+ name = "James Daugherty"
+ email = ''
+ }
+ }
+ scm {
+ connection = project.scmConnection
+ developerConnection = project.scmDeveloperConnection
+ url = project.scmUrl
+ }
+ }
+ }
+ }
+}
+
+afterEvaluate {
+ signing {
+ ext["signing.keyId"] = System.getenv('SIGNING_KEY_ID')
+ ext["signing.password"] = System.getenv('SIGNING_PASSPHRASE')
+ ext["signing.secretKeyRingFile"] = System.getenv('SECRING_FILE')
+
+ required {
+ isReleaseVersion && gradle.taskGraph.hasTask("publish")
+ }
+ sign publishing.publications.maven
+ }
+}
+
+tasks.withType(Sign) {
+ onlyIf { isReleaseVersion }
+}
diff --git a/settings.gradle b/settings.gradle
index 2798be5ca..aa3dda25e 100644
--- a/settings.gradle
+++ b/settings.gradle
@@ -1,10 +1,36 @@
-include 'spring-security-rest', 'spring-security-rest-memcached', 'spring-security-rest-redis', 'spring-security-rest-grailscache', 'spring-security-rest-gorm', 'spring-security-rest-testapp-profile', 'spring-security-rest-docs'
+plugins {
+ id 'com.gradle.enterprise' version '3.16.2'
+ id 'com.gradle.common-custom-user-data-gradle-plugin' version '1.13'
+}
+
+gradleEnterprise {
+ server = 'https://ge.grails.org'
+ buildScan {
+ publishAlwaysIf(System.getenv('CI') == 'true')
+ publishIfAuthenticated()
+ uploadInBackground = System.getenv('CI') == null
+ capture {
+ taskInputFiles = true
+ }
+ }
+}
-File build = new File('build')
-if (build.exists()) {
- build.eachDir {
- include it.name
- project(":${it.name}").projectDir = it
+buildCache {
+ local { enabled = System.getenv('CI') != 'true' }
+ remote(gradleEnterprise.buildCache) {
+ def isAuthenticated = System.getenv('GRADLE_ENTERPRISE_ACCESS_KEY')
+ push = System.getenv('CI') == 'true' && isAuthenticated
+ enabled = true
}
}
+rootProject.name = 'grails-spring-security-rest'
+
+include 'spring-security-rest'
+include 'spring-security-rest-memcached'
+include 'spring-security-rest-redis'
+include 'spring-security-rest-grailscache'
+include 'spring-security-rest-gorm'
+// include 'spring-security-rest-testapp-profile' // See https://github.com/grails/grails-spring-security-rest/pull/521#issuecomment-2380242985 for why this is commented out
+include 'spring-security-rest-docs'
+
diff --git a/spring-security-rest-docs/build.gradle b/spring-security-rest-docs/build.gradle
index 6fc0f431c..cfdd611be 100644
--- a/spring-security-rest-docs/build.gradle
+++ b/spring-security-rest-docs/build.gradle
@@ -1,17 +1,27 @@
+import org.asciidoctor.gradle.jvm.AsciidoctorTask
+
plugins {
- id 'org.asciidoctor.convert' version '2.4.0'
+ id 'org.asciidoctor.jvm.convert' version "4.0.3"
}
-asciidoctor {
+def asciidoctorAttributes = [
+ 'experimental' : 'true',
+ 'compat-mode' : 'true',
+ 'toc' : 'left',
+ 'icons' : 'font',
+ 'version' : project.version,
+ 'sourcedir' : "${rootProject.allprojects.find { it.name == 'spring-security-rest' }.projectDir}/src/main/groovy",
+ 'baseGroovyApiUrl': "https://grails-plugins.github.io/grails-spring-security-rest/${project.version}/docs/gapi/"
+]
+
+tasks.named('asciidoctor', AsciidoctorTask) {
resources {
from('src/docs/images')
into "./images"
}
- attributes 'experimental' : 'true',
- 'compat-mode' : 'true',
- 'toc' : 'left',
- 'icons' : 'font',
- 'version' : project.version,
- 'sourcedir' : "${rootProject.allprojects.find { it.name == 'spring-security-rest'}.projectDir}/src/main/groovy"
+ sourceDir project.file('src/docs')
+ sources { include 'index.adoc' }
+ outputDir = project.buildDir.toPath().resolve('docs').toFile()
+ attributes asciidoctorAttributes
}
\ No newline at end of file
diff --git a/spring-security-rest-docs/src/docs/asciidoc/authentication.adoc b/spring-security-rest-docs/src/docs/authentication.adoc
similarity index 87%
rename from spring-security-rest-docs/src/docs/asciidoc/authentication.adoc
rename to spring-security-rest-docs/src/docs/authentication.adoc
index 0ff43f442..d31d98679 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/authentication.adoc
+++ b/spring-security-rest-docs/src/docs/authentication.adoc
@@ -1,4 +1,4 @@
-The http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/RestAuthenticationFilter.html[authentication filter]
+The include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/RestAuthenticationFilter.html[authentication filter]
uses the default `authenticationManager` bean, which in turn uses all the registered authentication
providers. See the https://grails-plugins.github.io/grails-spring-security-core/v3/index.html#authenticationProviders[Spring Security Core guide]
for more information about how to define your own providers. Note that you can easily plug any Spring Security sub-plugin
@@ -90,7 +90,7 @@ grails.plugin.springsecurity.rest.login.passwordPropertyName = 'pwd'
----
If your JSON request format is different, you can plug your own implementation by defining a class which extends
-`http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/credentials/AbstractJsonPayloadCredentialsExtractor.html[AbstractJsonPayloadCredentialsExtractor]`.
+`include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/credentials/AbstractJsonPayloadCredentialsExtractor.html[AbstractJsonPayloadCredentialsExtractor]`.
The default implementation looks like this:
[source,groovy]
@@ -126,7 +126,7 @@ Note that the name of the parameters can also be customised:
====
Logout is not possible when using JWT tokens (the default strategy), as no state is kept in the server. If
you still want to have logout, you can provide your own implementation by creating a subclass of
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageService.html[JwtTokenStorageService]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageService.html[JwtTokenStorageService]
and overriding the methods `storeToken` and `removeToken`.
Then, register your implementation in `resources.groovy` as `tokenStorageService`.
@@ -136,7 +136,7 @@ let the tokens expire (they will expire anyway, unlike with other storages like
on every access).
====
-The http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/RestLogoutFilter.html[logout filter]
+The include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/RestLogoutFilter.html[logout filter]
exposes an endpoint for deleting tokens. It will read the token from an HTTP header. If found, will delete it from the
storage, sending a 200 response. Otherwise, it will send a 404 response.
diff --git a/spring-security-rest-docs/src/docs/asciidoc/configuration.adoc b/spring-security-rest-docs/src/docs/configuration.adoc
similarity index 95%
rename from spring-security-rest-docs/src/docs/asciidoc/configuration.adoc
rename to spring-security-rest-docs/src/docs/configuration.adoc
index 2932f5a01..68018c2c9 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/configuration.adoc
+++ b/spring-security-rest-docs/src/docs/configuration.adoc
@@ -44,7 +44,7 @@ Note that configuration properties such as `grails.plugin.springsecurity.rest.to
used. Every submodule of the above list will automatically configure the token store appropriately
If you want your own token storage system, you need to implement
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/storage/TokenStorageService.html[TokenStorageService]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/storage/TokenStorageService.html[TokenStorageService]
and register it in `resources.groovy` as `tokenStorageService`.
=== Plugin configuration
diff --git a/spring-security-rest-docs/src/docs/asciidoc/cors.adoc b/spring-security-rest-docs/src/docs/cors.adoc
similarity index 100%
rename from spring-security-rest-docs/src/docs/asciidoc/cors.adoc
rename to spring-security-rest-docs/src/docs/cors.adoc
diff --git a/spring-security-rest-docs/src/docs/asciidoc/debugging.adoc b/spring-security-rest-docs/src/docs/debugging.adoc
similarity index 100%
rename from spring-security-rest-docs/src/docs/asciidoc/debugging.adoc
rename to spring-security-rest-docs/src/docs/debugging.adoc
diff --git a/spring-security-rest-docs/src/docs/asciidoc/events.adoc b/spring-security-rest-docs/src/docs/events.adoc
similarity index 100%
rename from spring-security-rest-docs/src/docs/asciidoc/events.adoc
rename to spring-security-rest-docs/src/docs/events.adoc
diff --git a/spring-security-rest-docs/src/docs/asciidoc/faq.adoc b/spring-security-rest-docs/src/docs/faq.adoc
similarity index 87%
rename from spring-security-rest-docs/src/docs/asciidoc/faq.adoc
rename to spring-security-rest-docs/src/docs/faq.adoc
index 66cd21051..3e6e50cb0 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/faq.adoc
+++ b/spring-security-rest-docs/src/docs/faq.adoc
@@ -1,4 +1,4 @@
-===== Why this token-based implementation? Can't I use HTTP basic authentication?
+=== Why this token-based implementation? Can't I use HTTP basic authentication?
In theory you can. The only restriction to be truly stateless is to not use HTTP sessions at all. So if you go with
basic authentication, you need to transfer the credentials back and forth every time.
@@ -26,7 +26,7 @@ A couple of link with further explanations on the token-based flow:
* http://www.jamesward.com/2013/05/13/securing-single-page-apps-and-rest-services[]
* http://blog.brunoscopelliti.com/authentication-to-a-restful-web-service-in-an-angularjs-web-app[]
-===== Why can't the API be secured with OAuth?
+=== Why can't the API be secured with OAuth?
http://tools.ietf.org/html/rfc6749[RFC 6749 - OAuth 2.0] specification does cover this scenario in what they call
"public clients":
@@ -42,7 +42,7 @@ The OAuth 2.0 specification supports public clients with the implicit grant. Thi
you delegate the authentication to another OAuth provider. If it's you who are authenticating the users
(via DB, LDAP, etc), the token-based flow of this plugin is _OAuth-ish_.
-===== Why you didn't use any of the existing OAuth plugins? Why pac4j?
+=== Why you didn't use any of the existing OAuth plugins? Why pac4j?
I'm aware of plugins like http://grails.org/plugin/oauth[OAuth] and
http://grails.org/plugin/spring-security-oauth[Spring Security OAuth], but all of them rely on Spring Security Core's
@@ -55,7 +55,6 @@ I chose pac4j because:
I'm also aware of a pac4j-spring-security module. See my previous response on HTTP sessions.
-===== Dude, this is awesome. How can I compensate you?
+=== Project History
-I doubt you can :). You may try giving me free beers the next time you see me in a conference. Or you can just express
-your gratitude via https://twitter.com/alvaro_sanchez[Twitter].
\ No newline at end of file
+Originally this plugin was written by Alvaro Sanchez-Mariscal (https://twitter.com/alvaro_sanchez[Twitter]). It is currently maintained by the Grails Stewards.
diff --git a/spring-security-rest-docs/src/docs/asciidoc/index.adoc b/spring-security-rest-docs/src/docs/index.adoc
similarity index 77%
rename from spring-security-rest-docs/src/docs/asciidoc/index.adoc
rename to spring-security-rest-docs/src/docs/index.adoc
index 860f2c951..067afc6f0 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/index.adoc
+++ b/spring-security-rest-docs/src/docs/index.adoc
@@ -1,3 +1,5 @@
+:includedir: src/docs/
+
= Spring Security REST for Grails
:author: Álvaro Sánchez-Mariscal Arnaiz
:email: alvaro.sanchezmariscal@gmail.com
@@ -8,19 +10,23 @@ Version: {version}
== Introduction to the Spring Security REST plugin
-include::introduction.adoc[]
+include::{includedir}introduction.adoc[]
+
+== What's new in 5.0?
+
+include::{includedir}whatsNew50.adoc[]
== What's new in 2.0?
-include::whatsNew20.adoc[]
+include::{includedir}whatsNew20.adoc[]
== What's new in 1.5?
-include::whatsNew15.adoc[]
+include::{includedir}whatsNew15.adoc[]
== What's new in 1.4?
-include::whatsNew14.adoc[]
+include::{includedir}whatsNew14.adoc[]
== Articles and sample projects
@@ -43,54 +49,54 @@ include::whatsNew14.adoc[]
[[configuration]]
== Configuration
-include::configuration.adoc[]
+include::{includedir}configuration.adoc[]
[[events]]
== Events
-include::events.adoc[]
+include::{includedir}events.adoc[]
[[authentication]]
== Authentication Endpoint
-include::authentication.adoc[]
+include::{includedir}authentication.adoc[]
[[tokenGeneration]]
== Token Generation
-include::tokenGeneration.adoc[]
+include::{includedir}tokenGeneration.adoc[]
[[tokenStorage]]
== Token Storage
-include::tokenStorage.adoc[]
+include::{includedir}tokenStorage.adoc[]
[[tokenRendering]]
== Token Rendering
-include::tokenRendering.adoc[]
+include::{includedir}tokenRendering.adoc[]
[[tokenValidation]]
== Token Validation Filter
-include::tokenValidation.adoc[]
+include::{includedir}tokenValidation.adoc[]
[[cors]]
== CORS support
-include::cors.adoc[]
+include::{includedir}cors.adoc[]
[[oauth]]
== Delegating authentication to OAuth providers
-include::oauth.adoc[]
+include::{includedir}oauth.adoc[]
[[debugging]]
== Debugging
-include::debugging.adoc[]
+include::{includedir}debugging.adoc[]
[[faq]]
== Frequently Asked Questions
-include::faq.adoc[]
\ No newline at end of file
+include::{includedir}faq.adoc[]
\ No newline at end of file
diff --git a/spring-security-rest-docs/src/docs/index.tmpl b/spring-security-rest-docs/src/docs/index.tmpl
new file mode 100644
index 000000000..d07041533
--- /dev/null
+++ b/spring-security-rest-docs/src/docs/index.tmpl
@@ -0,0 +1,127 @@
+
+
+
+
+
+
+Grails Spring Security Rest Plugin
+
+
+
+
+
+
+
+
+
+
+
+
Grails Spring Security Rest Plugin
+
+
+
+
Spring Security Rest Plugin - Documentation
+
+
+
Grails 6.1.1
+
+
+
Grails 4.x.x and 5.x.x
+
+
+
Grails 3.x.x
+
+
+
+
+
+
+
Download Source
+
+ You can download this project in either
+ zip or
+ tar formats.
+
+
You can also clone the project with Git by running:
+
$ git clone git://github.com/grails/grails-spring-security-rest
+
+
+
+
+
+
+
diff --git a/spring-security-rest-docs/src/docs/asciidoc/introduction.adoc b/spring-security-rest-docs/src/docs/introduction.adoc
similarity index 96%
rename from spring-security-rest-docs/src/docs/asciidoc/introduction.adoc
rename to spring-security-rest-docs/src/docs/introduction.adoc
index a1b32497f..a8441febc 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/introduction.adoc
+++ b/spring-security-rest-docs/src/docs/introduction.adoc
@@ -28,7 +28,7 @@ and Grails Cache support for token storage.
=== Release History
-You can view all releases at https://github.com/alvarosanchez/grails-spring-security-rest/releases[].
+You can view all releases at https://github.com/grails/grails-spring-security-rest/releases[].
* 29 August 2016
** 1.5.4
diff --git a/spring-security-rest-docs/src/docs/asciidoc/oauth.adoc b/spring-security-rest-docs/src/docs/oauth.adoc
similarity index 96%
rename from spring-security-rest-docs/src/docs/asciidoc/oauth.adoc
rename to spring-security-rest-docs/src/docs/oauth.adoc
index 96b23c7e3..80e34f215 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/oauth.adoc
+++ b/spring-security-rest-docs/src/docs/oauth.adoc
@@ -77,9 +77,9 @@ You can also define the URL as a `callback` parameter in the original link, eg:
In this case, the token will be *concatenated* to the end of the URL.
Upon successful OAuth authorisation (after step 6.1 in the above diagram), an
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/oauth/OauthUser.html[OauthUser]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/oauth/OauthUser.html[OauthUser]
will be stored in the security context. This is done by a bean named `oauthUserDetailsService`. The
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsService.html[default implementation]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsService.html[default implementation]
delegates to the configured `userDetailsService` bean, passing the profile ID as the username:
[source,groovy]
@@ -115,7 +115,7 @@ parameter will be empty, and both `error` and `message` params will be appended:
Below are some examples on how to configure it for Google, Facebook and Twitter.
-==== Google
+=== Google
Define the following block in your `application.groovy`:
diff --git a/spring-security-rest-docs/src/docs/asciidoc/tokenGeneration.adoc b/spring-security-rest-docs/src/docs/tokenGeneration.adoc
similarity index 78%
rename from spring-security-rest-docs/src/docs/asciidoc/tokenGeneration.adoc
rename to spring-security-rest-docs/src/docs/tokenGeneration.adoc
index 7fdcf7438..34bd1dc33 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/tokenGeneration.adoc
+++ b/spring-security-rest-docs/src/docs/tokenGeneration.adoc
@@ -6,11 +6,11 @@ more information about how this plugin uses JWT's, check the <> se
==== Claims
It is possible, to include additional claims in the JWT generated. To do so, you can plug one or more implementations of the interface
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/generation/jwt/CustomClaimProvider.html[`CustomClaimProvider`],
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/generation/jwt/CustomClaimProvider.html[`CustomClaimProvider`],
and register them in Spring.
The plugin comes prepackaged with a
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/generation/jwt/IssuerClaimProvider.html[`IssuerClaimProvider`],
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/generation/jwt/IssuerClaimProvider.html[`IssuerClaimProvider`],
that sets the `iss` field of the JWT claim set, and which value is configurable using the following configuration property:
`grails.plugin.springsecurity.rest.token.generation.jwt.issuer`.
@@ -80,8 +80,8 @@ When using encrypted JWT's, those are the possible configuration options:
If you are not using JWT, but any stateful strategy like Memcached or GORM, the following strategies are available:
-* http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/generation/SecureRandomTokenGenerator.html[Using java.security.SecureRandom].
-* http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/generation/UUIDTokenGenerator.html[Using java.util.UUID].
+* include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/generation/SecureRandomTokenGenerator.html[Using java.security.SecureRandom].
+* include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/generation/UUIDTokenGenerator.html[Using java.util.UUID].
The strategy used is configurable:
@@ -101,5 +101,5 @@ Both of them generate tokens of 32 alphanumeric characters.
That should be enough for most of the human beings. But if you still want to provide your own implementation,
simply write a class implementing
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/generation/TokenGenerator.html[TokenGenerator]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/generation/TokenGenerator.html[TokenGenerator]
and wire it up in `resources.groovy` as `tokenGenerator`.
diff --git a/spring-security-rest-docs/src/docs/asciidoc/tokenRendering.adoc b/spring-security-rest-docs/src/docs/tokenRendering.adoc
similarity index 94%
rename from spring-security-rest-docs/src/docs/asciidoc/tokenRendering.adoc
rename to spring-security-rest-docs/src/docs/tokenRendering.adoc
index 1848ece76..39e61ecc5 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/tokenRendering.adoc
+++ b/spring-security-rest-docs/src/docs/tokenRendering.adoc
@@ -83,7 +83,7 @@ the chapter about token validation first.
====
If you want your own implementation, simply create a class implementing
-http://alvarosanchez.github.io/grails-spring-security-rest/docs/gapi/grails/plugin/springsecurity/rest/token/rendering/AccessTokenJsonRenderer.html[AccessTokenJsonRenderer]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/rendering/AccessTokenJsonRenderer.html[AccessTokenJsonRenderer]
and wire it up in `resources.groovy` with name `accessTokenJsonRenderer`.
[NOTE]
diff --git a/spring-security-rest-docs/src/docs/asciidoc/tokenStorage.adoc b/spring-security-rest-docs/src/docs/tokenStorage.adoc
similarity index 98%
rename from spring-security-rest-docs/src/docs/asciidoc/tokenStorage.adoc
rename to spring-security-rest-docs/src/docs/tokenStorage.adoc
index a4a57d211..0fe7da30f 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/tokenStorage.adoc
+++ b/spring-security-rest-docs/src/docs/tokenStorage.adoc
@@ -1,6 +1,6 @@
The tokens are stored on the server using a `tokenStorageService` bean. The plugin comes with out-of-the-box support
for JWT, Memcached, GORM and http://grails.org/plugin/cache[Grails Cache], but you can use your own strategy implementing the
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/storage/TokenStorageService.html[TokenStorageService]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/storage/TokenStorageService.html[TokenStorageService]
interface.
[NOTE]
@@ -399,5 +399,5 @@ It depends on the specific support of the actual providers. Grails has several p
[WARNING]
====
There is a bug in `:cache-ehcache:1.0.0` plugin that will cause issues. It's recommended that you use the latest version.
-See https://github.com/alvarosanchez/grails-spring-security-rest/issues/89[#89] for more information.
+See https://github.com/grails/grails-spring-security-rest/issues/89[#89] for more information.
====
diff --git a/spring-security-rest-docs/src/docs/asciidoc/tokenValidation.adoc b/spring-security-rest-docs/src/docs/tokenValidation.adoc
similarity index 97%
rename from spring-security-rest-docs/src/docs/asciidoc/tokenValidation.adoc
rename to spring-security-rest-docs/src/docs/tokenValidation.adoc
index e8a12cdd5..fc2a09117 100644
--- a/spring-security-rest-docs/src/docs/asciidoc/tokenValidation.adoc
+++ b/spring-security-rest-docs/src/docs/tokenValidation.adoc
@@ -49,7 +49,7 @@ grails.plugin.springsecurity.rest.token.validation.headerName = 'X-Auth-Token'
----
If you still want to have full access and read the token from a different part of the request, you can implement a
-http://alvarosanchez.github.io/grails-spring-security-rest/latest/docs/gapi/grails/plugin/springsecurity/rest/token/reader/TokenReader.html[TokenReader]
+include::{baseGroovyApiUrl}grails/plugin/springsecurity/rest/token/reader/TokenReader.html[TokenReader]
and register it in your `resources.groovy` as `tokenReader`.
[NOTE]
diff --git a/spring-security-rest-docs/src/docs/asciidoc/whatsNew14.adoc b/spring-security-rest-docs/src/docs/whatsNew14.adoc
similarity index 100%
rename from spring-security-rest-docs/src/docs/asciidoc/whatsNew14.adoc
rename to spring-security-rest-docs/src/docs/whatsNew14.adoc
diff --git a/spring-security-rest-docs/src/docs/asciidoc/whatsNew15.adoc b/spring-security-rest-docs/src/docs/whatsNew15.adoc
similarity index 100%
rename from spring-security-rest-docs/src/docs/asciidoc/whatsNew15.adoc
rename to spring-security-rest-docs/src/docs/whatsNew15.adoc
diff --git a/spring-security-rest-docs/src/docs/asciidoc/whatsNew20.adoc b/spring-security-rest-docs/src/docs/whatsNew20.adoc
similarity index 100%
rename from spring-security-rest-docs/src/docs/asciidoc/whatsNew20.adoc
rename to spring-security-rest-docs/src/docs/whatsNew20.adoc
diff --git a/spring-security-rest-docs/src/docs/whatsNew50.adoc b/spring-security-rest-docs/src/docs/whatsNew50.adoc
new file mode 100644
index 000000000..f3a4355ad
--- /dev/null
+++ b/spring-security-rest-docs/src/docs/whatsNew50.adoc
@@ -0,0 +1,25 @@
+=== Grails 6 support
+
+This major release is working with Grails 6. It's based on the newer versions of Spring Security Core plugin,
+which in turn uses newer Spring Security versions, so make sure you read carefully what the new versions have changed:
+
+|===
+| Grails Version | `spring-security-rest` version | Spring Security Core docs
+
+| 6.x
+| `6.0.0.RC1`
+| https://grails-plugins.github.io/grails-spring-security-core/6.0.x/index.html#whatsNew[]
+
+|===
+
+=== Provide AccessToken object to storeToken and removeToken Methods
+
+See issue https://github.com/grails/grails-spring-security-rest/issues/437[#437]
+
+=== Minimum Java Version
+
+The minimum java version is now 11.
+
+=== Dependency updates
+
+Dependencies are updated as of Grails 6.1.1 release date.
diff --git a/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGormGrailsPlugin.groovy b/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGormGrailsPlugin.groovy
index e6d2b7ce9..221737602 100644
--- a/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGormGrailsPlugin.groovy
+++ b/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGormGrailsPlugin.groovy
@@ -9,7 +9,7 @@ import grails.plugins.Plugin
class SpringSecurityRestGormGrailsPlugin extends Plugin {
// the version or versions of Grails the plugin is designed for
- String grailsVersion = "3.1.0 > *"
+ String grailsVersion = "6.1.1 > *"
List loadAfter = ['springSecurityRest']
List pluginExcludes = [
"grails-app/views/**"
@@ -17,20 +17,20 @@ class SpringSecurityRestGormGrailsPlugin extends Plugin {
String title = "Spring Security REST Plugin - GORM support"
String author = "Alvaro Sanchez-Mariscal"
- String authorEmail = "alvaro.sanchezmariscal@gmail.com"
+ String authorEmail = ""
String description = 'Implements authentication for REST APIs based on Spring Security. It uses a token-based workflow'
def profiles = ['web']
// URL to the plugin's documentation
- String documentation = "http://alvarosanchez.github.io/grails-spring-security-rest/"
+ String documentation = "https://grails-plugins.github.io/grails-spring-security-rest/"
// Extra (optional) plugin metadata
String license = "APACHE"
- def organization = [ name: "Object Computing, Inc.", url: "http://www.ociweb.com" ]
+ def organization = [name: 'Grails', url: 'https://www.grails.org/']
- def issueManagement = [ system: "GitHub", url: "https://github.com/alvarosanchez/grails-spring-security-rest/issues" ]
- def scm = [ url: "https://github.com/alvarosanchez/grails-spring-security-rest" ]
+ def issueManagement = [ system: "GitHub", url: "https://github.com/grails/grails-spring-security-rest/issues" ]
+ def scm = [ url: "https://github.com/grails/grails-spring-security-rest" ]
Closure doWithSpring() { {->
def conf = SpringSecurityUtils.securityConfig
diff --git a/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GormTokenStorageService.groovy b/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GormTokenStorageService.groovy
index 0f60798d7..ac75fc51c 100644
--- a/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GormTokenStorageService.groovy
+++ b/spring-security-rest-gorm/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GormTokenStorageService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage
diff --git a/spring-security-rest-gorm/src/main/resources/DefaultRestGormSecurityConfig.groovy b/spring-security-rest-gorm/src/main/resources/DefaultRestGormSecurityConfig.groovy
index c555ebbd3..978194980 100644
--- a/spring-security-rest-gorm/src/main/resources/DefaultRestGormSecurityConfig.groovy
+++ b/spring-security-rest-gorm/src/main/resources/DefaultRestGormSecurityConfig.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
import javax.servlet.http.HttpServletResponse
diff --git a/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsCacheGrailsPlugin.groovy b/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsCacheGrailsPlugin.groovy
index 0214b767f..a258fd9d1 100644
--- a/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsCacheGrailsPlugin.groovy
+++ b/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsCacheGrailsPlugin.groovy
@@ -9,7 +9,7 @@ import grails.plugins.Plugin
class SpringSecurityRestGrailsCacheGrailsPlugin extends Plugin {
// the version or versions of Grails the plugin is designed for
- String grailsVersion = "3.1.0 > *"
+ String grailsVersion = "6.1.1 > *"
List loadAfter = ['springSecurityRest']
List pluginExcludes = [
"grails-app/views/**"
@@ -17,20 +17,20 @@ class SpringSecurityRestGrailsCacheGrailsPlugin extends Plugin {
String title = "Spring Security REST Plugin - Grails cache support"
String author = "Alvaro Sanchez-Mariscal"
- String authorEmail = "alvaro.sanchezmariscal@gmail.com"
+ String authorEmail = ""
String description = 'Implements authentication for REST APIs based on Spring Security. It uses a token-based workflow'
def profiles = ['web']
// URL to the plugin's documentation
- String documentation = "http://alvarosanchez.github.io/grails-spring-security-rest/"
+ String documentation = "https://grails-plugins.github.io/grails-spring-security-rest/"
// Extra (optional) plugin metadata
String license = "APACHE"
- def organization = [ name: "Object Computing, Inc.", url: "http://www.ociweb.com" ]
+ def organization = [name: 'Grails', url: 'https://www.grails.org/']
- def issueManagement = [ system: "GitHub", url: "https://github.com/alvarosanchez/grails-spring-security-rest/issues" ]
- def scm = [ url: "https://github.com/alvarosanchez/grails-spring-security-rest" ]
+ def issueManagement = [ system: "GitHub", url: "https://github.com/grails/grails-spring-security-rest/issues" ]
+ def scm = [ url: "https://github.com/grails/grails-spring-security-rest" ]
Closure doWithSpring() { {->
def conf = SpringSecurityUtils.securityConfig
diff --git a/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageService.groovy b/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageService.groovy
index 688ae21cd..2047f87fc 100644
--- a/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageService.groovy
+++ b/spring-security-rest-grailscache/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage
diff --git a/spring-security-rest-grailscache/src/main/resources/DefaultRestGrailsCacheSecurityConfig.groovy b/spring-security-rest-grailscache/src/main/resources/DefaultRestGrailsCacheSecurityConfig.groovy
index b52ba0876..39a8f6b01 100644
--- a/spring-security-rest-grailscache/src/main/resources/DefaultRestGrailsCacheSecurityConfig.groovy
+++ b/spring-security-rest-grailscache/src/main/resources/DefaultRestGrailsCacheSecurityConfig.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
import javax.servlet.http.HttpServletResponse
diff --git a/spring-security-rest-grailscache/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageServiceSpec.groovy b/spring-security-rest-grailscache/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageServiceSpec.groovy
index 8462ec3f9..7beb52069 100644
--- a/spring-security-rest-grailscache/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageServiceSpec.groovy
+++ b/spring-security-rest-grailscache/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/GrailsCacheTokenStorageServiceSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage
diff --git a/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestMemcachedGrailsPlugin.groovy b/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestMemcachedGrailsPlugin.groovy
index 19856a648..630cc7857 100644
--- a/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestMemcachedGrailsPlugin.groovy
+++ b/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestMemcachedGrailsPlugin.groovy
@@ -12,7 +12,7 @@ import net.spy.memcached.spring.MemcachedClientFactoryBean
class SpringSecurityRestMemcachedGrailsPlugin extends Plugin {
// the version or versions of Grails the plugin is designed for
- String grailsVersion = "3.1.0 > *"
+ String grailsVersion = "6.1.1 > *"
List loadAfter = ['springSecurityRest']
List pluginExcludes = [
"grails-app/views/**"
@@ -20,20 +20,20 @@ class SpringSecurityRestMemcachedGrailsPlugin extends Plugin {
String title = "Spring Security REST Plugin - Memcached support"
String author = "Alvaro Sanchez-Mariscal"
- String authorEmail = "alvaro.sanchezmariscal@gmail.com"
+ String authorEmail = ""
String description = 'Implements authentication for REST APIs based on Spring Security. It uses a token-based workflow'
def profiles = ['web']
// URL to the plugin's documentation
- String documentation = "http://alvarosanchez.github.io/grails-spring-security-rest/"
+ String documentation = "https://grails-plugins.github.io/grails-spring-security-rest/"
// Extra (optional) plugin metadata
String license = "APACHE"
- def organization = [ name: "Object Computing, Inc.", url: "http://www.ociweb.com" ]
+ def organization = [name: 'Grails', url: 'https://www.grails.org/']
- def issueManagement = [ system: "GitHub", url: "https://github.com/alvarosanchez/grails-spring-security-rest/issues" ]
- def scm = [ url: "https://github.com/alvarosanchez/grails-spring-security-rest" ]
+ def issueManagement = [ system: "GitHub", url: "https://github.com/grails/grails-spring-security-rest/issues" ]
+ def scm = [ url: "https://github.com/grails/grails-spring-security-rest" ]
Closure doWithSpring() { {->
def conf = SpringSecurityUtils.securityConfig
diff --git a/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/CustomSerializingTranscoder.groovy b/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/CustomSerializingTranscoder.groovy
index 64793207d..f452d5c17 100644
--- a/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/CustomSerializingTranscoder.groovy
+++ b/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/CustomSerializingTranscoder.groovy
@@ -1,18 +1,16 @@
-/**
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage.memcached
diff --git a/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/MemcachedTokenStorageService.groovy b/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/MemcachedTokenStorageService.groovy
index 9c609672f..927887a21 100644
--- a/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/MemcachedTokenStorageService.groovy
+++ b/spring-security-rest-memcached/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/memcached/MemcachedTokenStorageService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage.memcached
diff --git a/spring-security-rest-memcached/src/main/resources/DefaultRestMemcachedSecurityConfig.groovy b/spring-security-rest-memcached/src/main/resources/DefaultRestMemcachedSecurityConfig.groovy
index ace006d7c..39fa3c090 100644
--- a/spring-security-rest-memcached/src/main/resources/DefaultRestMemcachedSecurityConfig.groovy
+++ b/spring-security-rest-memcached/src/main/resources/DefaultRestMemcachedSecurityConfig.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
import javax.servlet.http.HttpServletResponse
diff --git a/spring-security-rest-redis/build.gradle b/spring-security-rest-redis/build.gradle
index 3bfc4e681..da771add9 100644
--- a/spring-security-rest-redis/build.gradle
+++ b/spring-security-rest-redis/build.gradle
@@ -1,6 +1,6 @@
dependencies {
api project(":spring-security-rest")
- api "org.grails.plugins:redis:2.0.5"
+ api "org.grails.plugins:grails-redis:4.0.1"
api "redis.clients:jedis"
profile "org.grails.profiles:plugin:${grailsVersion}"
diff --git a/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestRedisGrailsPlugin.groovy b/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestRedisGrailsPlugin.groovy
index 613280bff..ddee15a19 100644
--- a/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestRedisGrailsPlugin.groovy
+++ b/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestRedisGrailsPlugin.groovy
@@ -9,7 +9,7 @@ import grails.plugins.*
class SpringSecurityRestRedisGrailsPlugin extends Plugin {
// the version or versions of Grails the plugin is designed for
- String grailsVersion = "3.1.0 > *"
+ String grailsVersion = "6.1.1 > *"
List loadAfter = ['springSecurityRest']
List pluginExcludes = [
"grails-app/views/**"
@@ -17,20 +17,20 @@ class SpringSecurityRestRedisGrailsPlugin extends Plugin {
String title = "Spring Security REST Plugin - Redis support"
String author = "Alvaro Sanchez-Mariscal"
- String authorEmail = "alvaro.sanchezmariscal@gmail.com"
+ String authorEmail = ""
String description = 'Implements authentication for REST APIs based on Spring Security. It uses a token-based workflow'
def profiles = ['web']
// URL to the plugin's documentation
- String documentation = "http://alvarosanchez.github.io/grails-spring-security-rest/"
+ String documentation = "https://grails-plugins.github.io/grails-spring-security-rest/"
// Extra (optional) plugin metadata
String license = "APACHE"
- def organization = [ name: "Object Computing, Inc.", url: "http://www.ociweb.com" ]
+ def organization = [name: 'Grails', url: 'https://www.grails.org/']
- def issueManagement = [ system: "GitHub", url: "https://github.com/alvarosanchez/grails-spring-security-rest/issues" ]
- def scm = [ url: "https://github.com/alvarosanchez/grails-spring-security-rest" ]
+ def issueManagement = [ system: "GitHub", url: "https://github.com/grails/grails-spring-security-rest/issues" ]
+ def scm = [ url: "https://github.com/grails/grails-spring-security-rest" ]
Closure doWithSpring() { {->
diff --git a/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/RedisTokenStorageService.groovy b/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/RedisTokenStorageService.groovy
index 19b02bac4..4dda28cf8 100644
--- a/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/RedisTokenStorageService.groovy
+++ b/spring-security-rest-redis/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/RedisTokenStorageService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage
diff --git a/spring-security-rest-redis/src/main/resources/DefaultRestRedisSecurityConfig.groovy b/spring-security-rest-redis/src/main/resources/DefaultRestRedisSecurityConfig.groovy
index 5036d666f..7f3203a29 100644
--- a/spring-security-rest-redis/src/main/resources/DefaultRestRedisSecurityConfig.groovy
+++ b/spring-security-rest-redis/src/main/resources/DefaultRestRedisSecurityConfig.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
import javax.servlet.http.HttpServletResponse
diff --git a/spring-security-rest-testapp-profile/build.gradle b/spring-security-rest-testapp-profile/build.gradle
index 9a041adb0..67786c91c 100644
--- a/spring-security-rest-testapp-profile/build.gradle
+++ b/spring-security-rest-testapp-profile/build.gradle
@@ -1,8 +1,3 @@
-plugins {
- id 'maven-publish'
- id 'signing'
-}
-
task generateProfileConfig () {
copy {
from 'profile.yml.tmpl'
@@ -21,4 +16,4 @@ task generateProfileConfig () {
}
}
-compileProfile.dependsOn generateProfileConfig
+compileProfile.dependsOn generateProfileConfig
\ No newline at end of file
diff --git a/spring-security-rest-testapp-profile/features/gorm1/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy b/spring-security-rest-testapp-profile/features/gorm1/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy
index 3bcfdb5ec..92f1f9735 100644
--- a/spring-security-rest-testapp-profile/features/gorm1/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy
+++ b/spring-security-rest-testapp-profile/features/gorm1/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
diff --git a/spring-security-rest-testapp-profile/features/gorm2/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy b/spring-security-rest-testapp-profile/features/gorm2/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy
index 3bcfdb5ec..92f1f9735 100644
--- a/spring-security-rest-testapp-profile/features/gorm2/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy
+++ b/spring-security-rest-testapp-profile/features/gorm2/skeleton/src/integration-test/groovy/rest/RestLogoutFilterSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
diff --git a/spring-security-rest-testapp-profile/features/jwt1/skeleton/src/integration-test/groovy/rest/JwtRestTokenValidationFilterSpec.groovy b/spring-security-rest-testapp-profile/features/jwt1/skeleton/src/integration-test/groovy/rest/JwtRestTokenValidationFilterSpec.groovy
index 847e2730a..0d1ec20a3 100644
--- a/spring-security-rest-testapp-profile/features/jwt1/skeleton/src/integration-test/groovy/rest/JwtRestTokenValidationFilterSpec.groovy
+++ b/spring-security-rest-testapp-profile/features/jwt1/skeleton/src/integration-test/groovy/rest/JwtRestTokenValidationFilterSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
diff --git a/spring-security-rest-testapp-profile/features/memcached1/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy b/spring-security-rest-testapp-profile/features/memcached1/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy
index 2aa7f2d90..a1077dc2f 100644
--- a/spring-security-rest-testapp-profile/features/memcached1/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy
+++ b/spring-security-rest-testapp-profile/features/memcached1/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package memcached
@@ -59,7 +57,7 @@ class MemcachedSpec extends AbstractRestSpec {
'Date' | new Date()
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/86")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/86")
void "Objects stored expire after the expiration time"() {
given:
memcachedTokenStorageService.expiration = 1
@@ -75,7 +73,7 @@ class MemcachedSpec extends AbstractRestSpec {
thrown(TokenNotFoundException)
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/86")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/86")
void "Objects are refreshed when accessed"() {
given:
memcachedTokenStorageService.expiration = 2
diff --git a/spring-security-rest-testapp-profile/features/memcached2/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy b/spring-security-rest-testapp-profile/features/memcached2/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy
index 2aa7f2d90..a1077dc2f 100644
--- a/spring-security-rest-testapp-profile/features/memcached2/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy
+++ b/spring-security-rest-testapp-profile/features/memcached2/skeleton/src/integration-test/groovy/memcached/MemcachedSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package memcached
@@ -59,7 +57,7 @@ class MemcachedSpec extends AbstractRestSpec {
'Date' | new Date()
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/86")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/86")
void "Objects stored expire after the expiration time"() {
given:
memcachedTokenStorageService.expiration = 1
@@ -75,7 +73,7 @@ class MemcachedSpec extends AbstractRestSpec {
thrown(TokenNotFoundException)
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/86")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/86")
void "Objects are refreshed when accessed"() {
given:
memcachedTokenStorageService.expiration = 2
diff --git a/spring-security-rest-testapp-profile/features/redis1/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy b/spring-security-rest-testapp-profile/features/redis1/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy
index 251d95727..e37f5ce47 100644
--- a/spring-security-rest-testapp-profile/features/redis1/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy
+++ b/spring-security-rest-testapp-profile/features/redis1/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package redis
diff --git a/spring-security-rest-testapp-profile/features/redis2/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy b/spring-security-rest-testapp-profile/features/redis2/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy
index 251d95727..e37f5ce47 100644
--- a/spring-security-rest-testapp-profile/features/redis2/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy
+++ b/spring-security-rest-testapp-profile/features/redis2/skeleton/src/integration-test/groovy/redis/RedisSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package redis
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/GebConfig.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/GebConfig.groovy
index da9a861b2..9b6ab865b 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/GebConfig.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/GebConfig.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
import org.openqa.selenium.Dimension
import org.openqa.selenium.phantomjs.PhantomJSDriver
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/AbstractRestSpec.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/AbstractRestSpec.groovy
index 2305d57c6..4457ec4f8 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/AbstractRestSpec.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/AbstractRestSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/BearerTokenSpec.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/BearerTokenSpec.groovy
index 9420f32d7..1112c1087 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/BearerTokenSpec.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/BearerTokenSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
@@ -22,7 +20,7 @@ import spock.lang.IgnoreIf
import spock.lang.Issue
@IgnoreIf({ !System.getProperty('useBearerToken', 'false').toBoolean() })
-@Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/73")
+@Issue("https://github.com/grails/grails-spring-security-rest/issues/73")
class BearerTokenSpec extends AbstractRestSpec {
void "access token response is compliant with the specification"() {
@@ -115,7 +113,7 @@ class BearerTokenSpec extends AbstractRestSpec {
response.headers.getFirst('WWW-Authenticate') == 'Bearer'
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/98")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/98")
void "accessing Anonymous without a token, responds ok"() {
when:
def response = restBuilder.get("${baseUrl}/anonymous") {
@@ -126,7 +124,7 @@ class BearerTokenSpec extends AbstractRestSpec {
response.status == 200
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/98")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/98")
void "accessing Secured without a token, responds Unauthorized"() {
when:
RestResponse response = restBuilder.post("${baseUrl}/secured") {
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/CorsSpec.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/CorsSpec.groovy
index f1c6235bc..67d514fb8 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/CorsSpec.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/CorsSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
@@ -25,7 +23,7 @@ import spock.lang.Ignore
/**
* Specification to test CORS support
*
- * @see https://github.com/alvarosanchez/grails-spring-security-rest/issues/4
+ * @see https://github.com/grails/grails-spring-security-rest/issues/4
*/
//FIXME
@Ignore
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/FrontendCallbackPage.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/FrontendCallbackPage.groovy
index 004a0fac8..2275d9107 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/FrontendCallbackPage.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/FrontendCallbackPage.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/JwtSpec.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/JwtSpec.groovy
index 5261e1d84..8cec2defc 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/JwtSpec.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/JwtSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
@@ -173,7 +171,7 @@ class JwtSpec extends AbstractRestSpec {
jwt.JWTClaimsSet.issuer == 'Spring Security REST Grails Plugin'
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/pull/344")
+ @Issue("https://github.com/grails/grails-spring-security-rest/pull/344")
void "if the user no longer exists, token can't be refreshed"() {
given:
userDetailsManager.createUser(new User('foo', '{noop}password', []))
@@ -194,7 +192,7 @@ class JwtSpec extends AbstractRestSpec {
userDetailsManager.deleteUser('foo')
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/pull/344")
+ @Issue("https://github.com/grails/grails-spring-security-rest/pull/344")
@Unroll
void "if the user is #status, token can't be refreshed"(User updatedUser, String status) {
given:
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestAuthenticationFilterSpec.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestAuthenticationFilterSpec.groovy
index 53b65d84b..fe1ea5ea9 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestAuthenticationFilterSpec.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestAuthenticationFilterSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
@@ -86,7 +84,7 @@ class RestAuthenticationFilterSpec extends AbstractRestSpec {
response.headers.get('Content-Type')?.first() == 'application/json;charset=UTF-8'
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/275")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/275")
void "WWW-Authenticate response header is sent on failed logins"() {
when:
def response = sendWrongCredentials()
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestTokenValidationFilterSpec.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestTokenValidationFilterSpec.groovy
index 72e563483..cdc77518a 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestTokenValidationFilterSpec.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/RestTokenValidationFilterSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
@@ -94,7 +92,7 @@ class RestTokenValidationFilterSpec extends AbstractRestSpec {
response.status == 403
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/67")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/67")
void "JSESSIONID cookie is not created when using the stateless chain"() {
when:
RestResponse authResponse = sendCorrectCredentials() as RestResponse
@@ -113,7 +111,7 @@ class RestTokenValidationFilterSpec extends AbstractRestSpec {
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/74")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/74")
void "anonymous access works when enabled"() {
when:
def response = restBuilder.get("${baseUrl}/anonymous")
@@ -124,7 +122,7 @@ class RestTokenValidationFilterSpec extends AbstractRestSpec {
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/74")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/74")
void "in an anonymous chain, if a token is sent, is validated"() {
when:
def response = restBuilder.post("${baseUrl}/anonymous") {
diff --git a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/ValidateEndpointSpec.groovy b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/ValidateEndpointSpec.groovy
index f8f89c782..c65f61313 100644
--- a/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/ValidateEndpointSpec.groovy
+++ b/spring-security-rest-testapp-profile/skeleton/src/integration-test/groovy/rest/ValidateEndpointSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package rest
diff --git a/spring-security-rest/build.gradle b/spring-security-rest/build.gradle
index 5822becfd..f80c1b183 100644
--- a/spring-security-rest/build.gradle
+++ b/spring-security-rest/build.gradle
@@ -1,35 +1,30 @@
-ext {
- pac4jVersion = '4.5.7'
-}
-
dependencies {
api "org.springframework.boot:spring-boot-starter-actuator"
api "org.springframework.boot:spring-boot-starter-tomcat"
api "org.grails:grails-dependencies"
api "org.grails:grails-web-boot"
- api "com.google.guava:guava:23.0"
+ api "com.google.guava:guava:33.0.0-jre"
api "org.pac4j:pac4j-core:${pac4jVersion}"
+ api "org.pac4j:pac4j-javaee:${pac4jVersion}"
api "org.pac4j:pac4j-oauth:${pac4jVersion}"
api "org.pac4j:pac4j-cas:${pac4jVersion}"
- api 'org.jasig.cas.client:cas-client-core:3.6.1'
+ api 'org.jasig.cas.client:cas-client-core:3.6.4'
- //https://snyk.io/vuln/SNYK-JAVA-ORGBOUNCYCASTLE-472372
- api 'org.bouncycastle:bcprov-jdk15on:1.65'
+ api 'org.bouncycastle:bcprov-jdk18on:1.77'
- api "com.nimbusds:nimbus-jose-jwt:8.17"
- api 'commons-codec:commons-codec:1.15'
+ api "com.nimbusds:nimbus-jose-jwt:9.37.3"
+ api 'commons-codec:commons-codec:1.16.0'
api "org.grails.plugins:spring-security-core:${springSecurityCoreVersion}"
- api "commons-fileupload:commons-fileupload:1.4"
+ api "commons-fileupload:commons-fileupload:1.5"
- //https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-7489
- api "com.fasterxml.jackson.core:jackson-databind:2.11.0"
+ api "com.fasterxml.jackson.core:jackson-databind:${project.property('jackson.version')}"
testImplementation "org.gperfutils:gbench:0.4.3-groovy-2.4"
- testImplementation 'net.bytebuddy:byte-buddy:1.10.10'
+ testImplementation 'net.bytebuddy:byte-buddy:1.14.11'
profile "org.grails.profiles:web-plugin:${grailsVersion}"
}
diff --git a/spring-security-rest/grails-app/conf/logback.groovy b/spring-security-rest/grails-app/conf/logback.groovy
index 9be38509a..e3dea70e8 100644
--- a/spring-security-rest/grails-app/conf/logback.groovy
+++ b/spring-security-rest/grails-app/conf/logback.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
import grails.util.BuildSettings
import grails.util.Environment
diff --git a/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthController.groovy b/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthController.groovy
index 78e2f36c4..efd9a45eb 100644
--- a/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthController.groovy
+++ b/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthController.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
@@ -26,9 +24,10 @@ import groovy.util.logging.Slf4j
import org.apache.commons.codec.binary.Base64
import grails.core.GrailsApplication
import org.pac4j.core.client.IndirectClient
-import org.pac4j.core.context.JEEContext
+import org.pac4j.jee.context.JEEContext
import org.pac4j.core.context.WebContext
import org.pac4j.core.exception.http.RedirectionAction
+import org.pac4j.jee.context.session.JEESessionStore
import org.springframework.http.HttpStatus
import org.springframework.security.core.userdetails.User
@@ -70,7 +69,7 @@ class RestOauthController {
}
}
- RedirectionAction redirectAction = client.getRedirectionAction(context).get()
+ RedirectionAction redirectAction = client.getRedirectionAction(context, JEESessionStore.INSTANCE).get()
log.debug "Redirecting to ${redirectAction.location}"
redirect url: redirectAction.location
}
@@ -136,6 +135,7 @@ class RestOauthController {
AccessToken accessToken = tokenGenerator.generateAccessToken(principal, false)
accessToken.refreshToken = refreshToken
+ tokenStorageService.storeToken(accessToken)
authenticationEventPublisher.publishTokenCreation(accessToken)
response.addHeader 'Cache-Control', 'no-store'
diff --git a/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthUrlMappings.groovy b/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthUrlMappings.groovy
index 988c1ab06..e21fb6825 100644
--- a/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthUrlMappings.groovy
+++ b/spring-security-rest/grails-app/controllers/grails/plugin/springsecurity/rest/RestOauthUrlMappings.groovy
@@ -1,19 +1,17 @@
package grails.plugin.springsecurity.rest
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
class RestOauthUrlMappings {
diff --git a/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/JwtService.groovy b/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/JwtService.groovy
index 56cf16ecf..2a21d14ba 100644
--- a/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/JwtService.groovy
+++ b/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/JwtService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/RestOauthService.groovy b/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/RestOauthService.groovy
index 96e8a419d..ad46adb2c 100644
--- a/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/RestOauthService.groovy
+++ b/spring-security-rest/grails-app/services/grails/plugin/springsecurity/rest/RestOauthService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
@@ -98,7 +96,7 @@ class RestOauthService {
log.debug "Generated REST authentication token: ${accessToken}"
log.debug "Storing token on the token storage"
- tokenStorageService.storeToken(accessToken.accessToken, userDetails)
+ tokenStorageService.storeToken(accessToken)
authenticationEventPublisher.publishTokenCreation(accessToken)
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandler.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandler.groovy
index cf8616e08..9dfc03940 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandler.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandler.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFilter.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFilter.groovy
index 1b4e5036f..8fc619984 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFilter.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFilter.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
@@ -108,7 +106,7 @@ class RestAuthenticationFilter extends GenericFilterBean {
AccessToken accessToken = tokenGenerator.generateAccessToken(authenticationResult.principal as UserDetails)
log.debug "Generated token: ${accessToken}"
- tokenStorageService.storeToken(accessToken.accessToken, authenticationResult.principal as UserDetails)
+ tokenStorageService.storeToken(accessToken)
authenticationEventPublisher.publishTokenCreation(accessToken)
authenticationSuccessHandler.onAuthenticationSuccess(httpServletRequest, httpServletResponse, accessToken)
SecurityContextHolder.context.setAuthentication(accessToken)
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProvider.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProvider.groovy
index 3b7798ef7..c06c8d8a2 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProvider.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProvider.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationSuccessHandler.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationSuccessHandler.groovy
index 579d23545..bb8336b22 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationSuccessHandler.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestAuthenticationSuccessHandler.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestLogoutFilter.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestLogoutFilter.groovy
index 24d218228..f2bf3b39f 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestLogoutFilter.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestLogoutFilter.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
@@ -71,11 +69,11 @@ class RestLogoutFilter extends GenericFilterBean {
log.debug "Trying to remove the token"
tokenStorageService.removeToken accessToken.accessToken
} catch (TokenNotFoundException ignored) {
- servletResponse.setStatus HttpServletResponse.SC_NOT_FOUND, "Token not found"
+ servletResponse.sendError HttpServletResponse.SC_NOT_FOUND, "Token not found"
}
} else {
log.debug "Token is missing. Sending a ${HttpServletResponse.SC_BAD_REQUEST} Bad Request response"
- servletResponse.setStatus HttpServletResponse.SC_BAD_REQUEST, "Token header is missing"
+ servletResponse.sendError HttpServletResponse.SC_BAD_REQUEST, "Token header is missing"
}
} else {
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListener.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListener.groovy
index b2b4b215e..6198374c6 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListener.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListener.groovy
@@ -1,18 +1,16 @@
-/**
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenCreationEvent.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenCreationEvent.groovy
index be8e67ba7..a3b21e5ee 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenCreationEvent.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenCreationEvent.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilter.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilter.groovy
index 93e62e9d3..4cab4ea37 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilter.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilter.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestFilterRequestMatcher.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestFilterRequestMatcher.groovy
index 2ab705960..a1648d972 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestFilterRequestMatcher.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestFilterRequestMatcher.groovy
@@ -1,3 +1,17 @@
+/* Copyright 2024 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package grails.plugin.springsecurity.rest
import groovy.transform.CompileStatic
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsPlugin.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsPlugin.groovy
index 92be3832c..2ff968835 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsPlugin.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/SpringSecurityRestGrailsPlugin.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
@@ -66,7 +64,7 @@ import org.springframework.security.web.savedrequest.NullRequestCache
class SpringSecurityRestGrailsPlugin extends Plugin {
// the version or versions of Grails the plugin is designed for
- String grailsVersion = "4.0.0 > *"
+ String grailsVersion = "6.1.1 > *"
List loadAfter = ['springSecurityCore']
List pluginExcludes = [
"grails-app/views/**"
@@ -74,20 +72,20 @@ class SpringSecurityRestGrailsPlugin extends Plugin {
String title = "Spring Security REST Plugin"
String author = "Alvaro Sanchez-Mariscal"
- String authorEmail = "alvaro.sanchezmariscal@gmail.com"
+ String authorEmail = ""
String description = 'Implements authentication for REST APIs based on Spring Security. It uses a token-based workflow'
def profiles = ['web']
// URL to the plugin's documentation
- String documentation = "http://alvarosanchez.github.io/grails-spring-security-rest/"
+ String documentation = "https://grails-plugins.github.io/grails-spring-security-rest/"
// Extra (optional) plugin metadata
String license = "APACHE"
- def organization = [ name: "Object Computing, Inc.", url: "http://www.ociweb.com" ]
+ def organization = [name: 'Grails', url: 'https://www.grails.org/']
- def issueManagement = [ system: "GitHub", url: "https://github.com/alvarosanchez/grails-spring-security-rest/issues" ]
- def scm = [ url: "https://github.com/alvarosanchez/grails-spring-security-rest" ]
+ def issueManagement = [ system: "GitHub", url: "https://github.com/grails/grails-spring-security-rest/issues" ]
+ def scm = [ url: "https://github.com/grails/grails-spring-security-rest" ]
GrailsApplication grailsApplication
Closure doWithSpring() { {->
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisher.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisher.groovy
index f7c017bec..3d0f18b91 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisher.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisher.groovy
@@ -1,18 +1,16 @@
-/**
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.authentication
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/NullRestAuthenticationEventPublisher.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/NullRestAuthenticationEventPublisher.groovy
index 43312adc6..05f6605a4 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/NullRestAuthenticationEventPublisher.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/NullRestAuthenticationEventPublisher.groovy
@@ -1,18 +1,16 @@
-/**
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.authentication
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/RestAuthenticationEventPublisher.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/RestAuthenticationEventPublisher.groovy
index 410eeab6e..2d85275b5 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/RestAuthenticationEventPublisher.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/authentication/RestAuthenticationEventPublisher.groovy
@@ -1,18 +1,16 @@
-/**
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.authentication
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/AbstractJsonPayloadCredentialsExtractor.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/AbstractJsonPayloadCredentialsExtractor.groovy
index 8ead0c21c..5b42aed5b 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/AbstractJsonPayloadCredentialsExtractor.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/AbstractJsonPayloadCredentialsExtractor.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.credentials
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractor.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractor.groovy
index 217051a9e..a8c106b3c 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractor.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractor.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.credentials
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/DefaultJsonPayloadCredentialsExtractor.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/DefaultJsonPayloadCredentialsExtractor.groovy
index 0db8b6881..cd3a4a030 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/DefaultJsonPayloadCredentialsExtractor.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/DefaultJsonPayloadCredentialsExtractor.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.credentials
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/RequestParamsCredentialsExtractor.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/RequestParamsCredentialsExtractor.groovy
index 47c311986..8ce74dfb1 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/RequestParamsCredentialsExtractor.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/credentials/RequestParamsCredentialsExtractor.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.credentials
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/CallbackErrorHandler.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/CallbackErrorHandler.groovy
index 2d92fd932..485acdecf 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/CallbackErrorHandler.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/CallbackErrorHandler.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.error
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/DefaultCallbackErrorHandler.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/DefaultCallbackErrorHandler.groovy
index 9445a63e5..54f7de175 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/DefaultCallbackErrorHandler.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/error/DefaultCallbackErrorHandler.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.error
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsService.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsService.groovy
index a2f0de0f8..4238fc473 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsService.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.oauth
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUser.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUser.groovy
index a5238776e..ec5d54384 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUser.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUser.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.oauth
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUserDetailsService.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUserDetailsService.groovy
index 0ba87409c..eff1e89c8 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUserDetailsService.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/oauth/OauthUserDetailsService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.oauth
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/AccessToken.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/AccessToken.groovy
index 2e2d1e5ae..705614fbf 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/AccessToken.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/AccessToken.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandler.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandler.groovy
index f5e1950b8..cd0d11604 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandler.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandler.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.bearer
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationEntryPoint.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationEntryPoint.groovy
index 7393f6d80..4f393f386 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationEntryPoint.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationEntryPoint.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.bearer
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationFailureHandler.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationFailureHandler.groovy
index 9f44160e2..050de63fb 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationFailureHandler.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAuthenticationFailureHandler.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.bearer
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenReader.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenReader.groovy
index 8c8867e86..8206fe375 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenReader.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenReader.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.bearer
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/SecureRandomTokenGenerator.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/SecureRandomTokenGenerator.groovy
index 82636752a..e37cf7e8e 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/SecureRandomTokenGenerator.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/SecureRandomTokenGenerator.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/TokenGenerator.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/TokenGenerator.groovy
index 86aadcd18..8cd5444ae 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/TokenGenerator.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/TokenGenerator.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/UUIDTokenGenerator.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/UUIDTokenGenerator.groovy
index 7d720b2d1..76c460e21 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/UUIDTokenGenerator.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/UUIDTokenGenerator.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/AbstractJwtTokenGenerator.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/AbstractJwtTokenGenerator.groovy
index 606051f6b..e952bd19e 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/AbstractJwtTokenGenerator.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/AbstractJwtTokenGenerator.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation.jwt
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/CustomClaimProvider.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/CustomClaimProvider.groovy
index c01c23a54..8e98be60d 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/CustomClaimProvider.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/CustomClaimProvider.groovy
@@ -1,3 +1,17 @@
+/* Copyright 2024 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package grails.plugin.springsecurity.rest.token.generation.jwt
import com.nimbusds.jwt.JWTClaimsSet
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/DefaultRSAKeyProvider.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/DefaultRSAKeyProvider.groovy
index 93d6e6f30..e087e0470 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/DefaultRSAKeyProvider.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/DefaultRSAKeyProvider.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation.jwt
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/EncryptedJwtTokenGenerator.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/EncryptedJwtTokenGenerator.groovy
index a58953ffb..71c01edb4 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/EncryptedJwtTokenGenerator.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/EncryptedJwtTokenGenerator.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation.jwt
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/FileRSAKeyProvider.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/FileRSAKeyProvider.groovy
index d7f2bb863..1c787dd89 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/FileRSAKeyProvider.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/FileRSAKeyProvider.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation.jwt
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/IssuerClaimProvider.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/IssuerClaimProvider.groovy
index 62688388f..772dc4b1c 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/IssuerClaimProvider.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/IssuerClaimProvider.groovy
@@ -1,3 +1,17 @@
+/* Copyright 2024 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package grails.plugin.springsecurity.rest.token.generation.jwt
import com.nimbusds.jwt.JWTClaimsSet
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/RSAKeyProvider.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/RSAKeyProvider.groovy
index b60966cfa..3b12334f1 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/RSAKeyProvider.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/RSAKeyProvider.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation.jwt
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/SignedJwtTokenGenerator.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/SignedJwtTokenGenerator.groovy
index 5c8abc9d7..5cdd23962 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/SignedJwtTokenGenerator.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/generation/jwt/SignedJwtTokenGenerator.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation.jwt
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/HttpHeaderTokenReader.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/HttpHeaderTokenReader.groovy
index 4313210b3..3b5cc0fd2 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/HttpHeaderTokenReader.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/HttpHeaderTokenReader.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.reader
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/TokenReader.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/TokenReader.groovy
index 5110565fa..565ee37ea 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/TokenReader.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/reader/TokenReader.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.reader
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/AccessTokenJsonRenderer.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/AccessTokenJsonRenderer.groovy
index 0585340dc..5994a2793 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/AccessTokenJsonRenderer.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/AccessTokenJsonRenderer.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.rendering
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultAccessTokenJsonRenderer.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultAccessTokenJsonRenderer.groovy
index 768096a75..13c107352 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultAccessTokenJsonRenderer.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultAccessTokenJsonRenderer.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.rendering
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenNotFoundException.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenNotFoundException.groovy
index 668317284..6e5f420db 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenNotFoundException.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenNotFoundException.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenStorageService.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenStorageService.groovy
index 722c3c4ff..f63cc6202 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenStorageService.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/TokenStorageService.groovy
@@ -1,35 +1,33 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage
+import grails.plugin.springsecurity.rest.token.AccessToken
import org.springframework.security.core.userdetails.UserDetails
import org.springframework.security.core.Authentication
/**
- * Implementations of this interface are responsible to load user information from a token storage system, and to store
+ * Implementations of this trait are responsible to load user information from a token storage system, and to store
* token information into it.
*/
-interface TokenStorageService {
-
+trait TokenStorageService {
/**
* Returns a principal object given the passed token value
* @throws TokenNotFoundException if no token is found in the storage
*/
- UserDetails loadUserByToken(String tokenValue) throws TokenNotFoundException
+ abstract UserDetails loadUserByToken(String tokenValue) throws TokenNotFoundException
/**
* Stores a token. It receives the principal to store any additional information together with the token,
@@ -37,11 +35,18 @@ interface TokenStorageService {
*
* @see Authentication#getPrincipal()
*/
- void storeToken(String tokenValue, UserDetails principal)
+ void storeToken(String tokenValue, UserDetails principal) {}
+
+ /**
+ * Stores the access token. Allows for handling of refresh token and other JWT claims as needed.
+ */
+ void storeToken(AccessToken accessToken) {
+ storeToken(accessToken.accessToken, accessToken.principal)
+ }
/**
* Removes a token from the storage.
* @throws TokenNotFoundException if the given token is not found in the storage
*/
- void removeToken(String tokenValue) throws TokenNotFoundException
+ abstract void removeToken(String tokenValue) throws TokenNotFoundException
}
diff --git a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageService.groovy b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageService.groovy
index 710332599..8079633ca 100644
--- a/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageService.groovy
+++ b/spring-security-rest/src/main/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageService.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage.jwt
diff --git a/spring-security-rest/src/main/resources/DefaultRestSecurityConfig.groovy b/spring-security-rest/src/main/resources/DefaultRestSecurityConfig.groovy
index 690f976ae..5b2a760bf 100644
--- a/spring-security-rest/src/main/resources/DefaultRestSecurityConfig.groovy
+++ b/spring-security-rest/src/main/resources/DefaultRestSecurityConfig.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2015 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
import javax.servlet.http.HttpServletResponse
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/BearerTokenAuthenticationFailureHandlerSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/BearerTokenAuthenticationFailureHandlerSpec.groovy
index 627f98caf..f96b473ce 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/BearerTokenAuthenticationFailureHandlerSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/BearerTokenAuthenticationFailureHandlerSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/JwtServiceSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/JwtServiceSpec.groovy
index 828cc9a0e..d69633234 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/JwtServiceSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/JwtServiceSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandlerSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandlerSpec.groovy
index bc2c54af3..245cc36a3 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandlerSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationFailureHandlerSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProviderSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProviderSpec.groovy
index 05defc434..e1ef59d12 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProviderSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestAuthenticationProviderSpec.groovy
@@ -30,7 +30,7 @@ class RestAuthenticationProviderSpec extends Specification implements TokenGener
this.restAuthenticationProvider.tokenStorageService = new JwtTokenStorageService(jwtService: jwtService, userDetailsService: userDetailsService)
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/276")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/276")
void "if the JWT's expiration time is null, it's validated successfully"() {
given:
AccessToken accessToken = tokenGenerator.generateAccessToken(new User('testUser', 'testPassword', []), 0)
@@ -42,7 +42,7 @@ class RestAuthenticationProviderSpec extends Specification implements TokenGener
result.authenticated
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/391")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/391")
void "refresh tokens should not be usable for authentication"() {
given:
AccessToken accessToken = tokenGenerator.generateAccessToken(new User('testUser', 'testPassword', []), 0)
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthControllerSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthControllerSpec.groovy
index f04bfcee6..c901516b5 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthControllerSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthControllerSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
@@ -32,7 +30,7 @@ import spock.lang.Specification
import static org.springframework.http.HttpStatus.FORBIDDEN
import static org.springframework.http.HttpStatus.INTERNAL_SERVER_ERROR
-@Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/237")
+@Issue("https://github.com/grails/grails-spring-security-rest/issues/237")
class RestOauthControllerSpec extends Specification implements ControllerUnitTest {
/**
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthServiceSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthServiceSpec.groovy
index 9758380ac..1b4fb38e6 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthServiceSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestOauthServiceSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListenerSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListenerSpec.groovy
index c39b30671..2b159fe28 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListenerSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestSecurityEventListenerSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenReaderSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenReaderSpec.groovy
index b29c0cd51..143e95fdd 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenReaderSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenReaderSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilterUnitSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilterUnitSpec.groovy
index bc3078671..e10d320a6 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilterUnitSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/RestTokenValidationFilterUnitSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisherSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisherSpec.groovy
index 04ec35c5c..9eff1c967 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisherSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/authentication/DefaultRestAuthenticationEventPublisherSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.authentication
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractorTestSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractorTestSpec.groovy
index 86c080e27..29d6b835b 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractorTestSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/credentials/CredentialsExtractorTestSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.credentials
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsServiceSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsServiceSpec.groovy
index a29b18b6a..0f8af218d 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsServiceSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/oauth/DefaultOauthUserDetailsServiceSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.oauth
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/rfc6750/BearerTokenReaderSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/rfc6750/BearerTokenReaderSpec.groovy
index 76c679042..46610630a 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/rfc6750/BearerTokenReaderSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/rfc6750/BearerTokenReaderSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.rfc6750
@@ -139,7 +137,7 @@ class BearerTokenReaderSpec extends Specification {
!tokenReader.findToken(request)
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/235")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/235")
def "it doesn't crash if token is missing"() {
given:
request.addHeader('Authorization', 'Bearer')
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/TokenGeneratorSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/TokenGeneratorSpec.groovy
index c501d7b26..452dea2b6 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/TokenGeneratorSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/TokenGeneratorSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandlerSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandlerSpec.groovy
index 3f68d186f..6e9c7ffe6 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandlerSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/bearer/BearerTokenAccessDeniedHandlerSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.bearer
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/generation/JwtTokenGeneratorSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/generation/JwtTokenGeneratorSpec.groovy
index e0ac4372d..91577838b 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/generation/JwtTokenGeneratorSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/generation/JwtTokenGeneratorSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.generation
@@ -145,7 +143,7 @@ class JwtTokenGeneratorSpec extends Specification implements TokenGeneratorSuppo
jwtTokenGenerator << [setupSignedJwtTokenGenerator(), setupEncryptedJwtTokenGenerator()]
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/295")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/295")
void "custom claims can be added"() {
given:
SignedJwtTokenGenerator tokenGenerator = setupSignedJwtTokenGenerator()
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultRestAuthenticationTokenJsonRendererSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultRestAuthenticationTokenJsonRendererSpec.groovy
index 69d3b1458..dd1022079 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultRestAuthenticationTokenJsonRendererSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/rendering/DefaultRestAuthenticationTokenJsonRendererSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.rendering
@@ -102,7 +100,7 @@ class DefaultRestAuthenticationTokenJsonRendererSpec extends Specification imple
}
- @Issue('https://github.com/alvarosanchez/grails-spring-security-rest/issues/33')
+ @Issue('https://github.com/grails/grails-spring-security-rest/issues/33')
void "it renders OAuth information if the principal is an OAuthUser"() {
given:
def username = 'john.doe'
diff --git a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageServiceSpec.groovy b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageServiceSpec.groovy
index d80f6a1d2..866c65423 100644
--- a/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageServiceSpec.groovy
+++ b/spring-security-rest/src/test/groovy/grails/plugin/springsecurity/rest/token/storage/jwt/JwtTokenStorageServiceSpec.groovy
@@ -1,18 +1,16 @@
-/*
- * Copyright 2013-2016 Alvaro Sanchez-Mariscal
+/* Copyright 2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
- *
*/
package grails.plugin.springsecurity.rest.token.storage.jwt
@@ -59,7 +57,7 @@ class JwtTokenStorageServiceSpec extends Specification implements ServiceUnitTes
thrown(TokenNotFoundException)
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/391")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/391")
def "refresh token with optional expiration can be successfully loaded"() {
given: "an access token that expires"
AccessToken accessToken = tokenGenerator.generateAccessToken(new User('testUser', 'testPassword', []), true, 3600, 3600)
@@ -75,7 +73,7 @@ class JwtTokenStorageServiceSpec extends Specification implements ServiceUnitTes
1 * service.userDetailsService.loadUserByUsername('testUser') >> { new User('testUser', 'testPassword', []) }
}
- @Issue("https://github.com/alvarosanchez/grails-spring-security-rest/issues/391")
+ @Issue("https://github.com/grails/grails-spring-security-rest/issues/391")
def "refresh token with optional expiration fails when expired"() {
given:
AccessToken accessToken = tokenGenerator.generateAccessToken(new User('testUser', 'testPassword', []), true, 3600, 1)