Skip to content

Commit

Permalink
JWT authentication & Clean up the board (#23)
Browse files Browse the repository at this point in the history
* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* Clean default board & JWT auth added

Signed-off-by: Hoang Pham <[email protected]>

* feat: sync cursors

Signed-off-by: Hoang Pham <[email protected]>

* feat: sync cursors

Signed-off-by: Hoang Pham <[email protected]>

* feat: Token for file

Signed-off-by: Hoang Pham <[email protected]>

* feat: read only handler

Signed-off-by: Hoang Pham <[email protected]>

* feat: read only handler

Signed-off-by: Hoang Pham <[email protected]>

* feat: read only handler

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

* Fix ci/cd errs

Signed-off-by: Hoang Pham <[email protected]>

---------

Signed-off-by: Hoang Pham <[email protected]>
  • Loading branch information
hweihwang authored Jul 1, 2024
1 parent 1db1696 commit 04dc6de
Show file tree
Hide file tree
Showing 22 changed files with 1,910 additions and 680 deletions.
9 changes: 9 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# SPDX-FileCopyrightText: 2024 Nextcloud GmbH and Nextcloud contributors
# SPDX-License-Identifier: AGPL-3.0-or-later

NEXTCLOUD_URL=http://nextcloud.local
PORT=3002
TLS=false
TLS_KEY=
TLS_CERT=
JWT_SECRET_KEY=your_secret_key
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@

.php-cs-fixer.cache
.phpunit.result.cache
.env
2 changes: 2 additions & 0 deletions appinfo/routes.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

return [
'routes' => [
/** @see JWTController::getJWT() */
['name' => 'JWT#getJWT', 'url' => '{fileId}/token', 'verb' => 'GET'],
/** @see WhiteboardController::update() */
['name' => 'Whiteboard#update', 'url' => '{fileId}', 'verb' => 'PUT'],
/** @see WhiteboardController::show() */
Expand Down
50 changes: 25 additions & 25 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
{
"name": "nextcloud/whiteboard",
"require-dev": {
"phpunit/phpunit": "^9.5",
"nextcloud/coding-standard": "^1.0",
"psalm/phar": "^5.2",
"sabre/dav": "^4.3",
"nextcloud/ocp": "dev-master"
},
"name": "nextcloud/whiteboard",
"config": {
"autoloader-suffix": "Whiteboard",
"optimize-autoloader": true,
"platform": {
"php": "8.0"
}
"php": "8.1"
},
"sort-packages": true
},
"license": "AGPL",
"require": {
"php": "^8.0"
},
"scripts": {
"lint": "find . -name \\*.php -not -path './vendor/*' -print0 | xargs -0 -n1 php -l",
"cs:check": "php-cs-fixer fix --dry-run --diff",
"cs:fix": "php-cs-fixer fix",
"psalm": "psalm.phar",
"test:unit": "phpunit -c tests/phpunit.xml"
},
"autoload-dev": {
"psr-4": {
"OCP\\": "vendor/nextcloud/ocp/OCP"
}
"license": "AGPL",
"require": {
"php": "^8.1",
"firebase/php-jwt": "^6.10"
},
"require-dev": {
"roave/security-advisories": "dev-latest",
"phpunit/phpunit": "^9.5",
"nextcloud/coding-standard": "^1.0",
"psalm/phar": "^5.2",
"sabre/dav": "^4.3",
"nextcloud/ocp": "dev-master"
},
"scripts": {
"lint": "find . -name \\*.php -not -path './vendor/*' -print0 | xargs -0 -n1 php -l",
"cs:check": "php-cs-fixer fix --dry-run --diff",
"cs:fix": "php-cs-fixer fix",
"psalm": "psalm.phar",
"test:unit": "phpunit -c tests/phpunit.xml"
}
}
Loading

0 comments on commit 04dc6de

Please sign in to comment.