Skip to content

Commit

Permalink
Merge pull request #306 from matematikk-mooc/KURSP-911-laravel10
Browse files Browse the repository at this point in the history
Kursp 911 laravel10
  • Loading branch information
theahthodesen authored Feb 6, 2024
2 parents f7cbb67 + 8b9879c commit e3d3fc7
Show file tree
Hide file tree
Showing 9 changed files with 1,173 additions and 881 deletions.
2 changes: 1 addition & 1 deletion app/Http/Kernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class Kernel extends HttpKernel
*
* @var array
*/
protected $routeMiddleware = [
protected $middlewareAliases = [
'auth' => \App\Http\Middleware\Authenticate::class,
'auth.api' => ApiToken::class,
'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
Expand Down
10 changes: 6 additions & 4 deletions app/Http/Middleware/TrustProxies.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class TrustProxies extends Middleware
* The trusted proxies for this application.
*
* Security: The use of wildcard here can be permitted as long as we make sure
* all requests to the web application originates from Azure Front Door. This is
* all requests to the web application originates from Azure Front Door. This is
* currently done by using Azure Private Link for communication between AFD and web app.
*
* @var array
Expand All @@ -20,14 +20,16 @@ class TrustProxies extends Middleware

/**
* The headers that should be used to detect proxies.
*
*
* We're currently using Azure Front Door as proxy. The selection of headers done here is
* based on their documentation:
* based on their documentation:
* https://learn.microsoft.com/en-us/azure/frontdoor/front-door-http-headers-protocol
*
* @var int
*/
protected $headers = Request::HEADER_X_FORWARDED_FOR |
Request::HEADER_X_FORWARDED_HOST |
Request::HEADER_X_FORWARDED_PROTO;
Request::HEADER_X_FORWARDED_PORT |
Request::HEADER_X_FORWARDED_PROTO |
Request::HEADER_X_FORWARDED_AWS_ELB;
}
2 changes: 0 additions & 2 deletions app/Providers/AuthServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@ class AuthServiceProvider extends ServiceProvider
*/
public function boot()
{
$this->registerPolicies();

//
}
}
16 changes: 7 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,24 +13,22 @@
}
],
"require": {
"php": "^8.0",
"php": "^8.1",
"ext-json": "*",
"bugsnag/bugsnag-laravel": "^2.0",
"doctrine/dbal": "2.*",
"doctrine/dbal": "^3.0",
"dompdf/dompdf": "^2.0",
"easyrdf/easyrdf": "^1.1",
"encore/laravel-admin": "^1.7",
"fideloper/proxy": "^4.0",
"guzzlehttp/guzzle": "^7.0.1",
"highsolutions/laravel-environments": "*",
"imsglobal/lti-1p3-tool": "dev-master",
"laravel/framework": "^9.0",
"laravel/framework": "^10.0",
"laravel/tinker": "^2.0",
"league/oauth2-client": "^2.4",
"mantas-done/subtitles": "^0.3.10",
"nesbot/carbon": "*",
"spatie/laravel-data": "^3.11",
"spatie/laravel-ignition": "^1.0",
"spatie/laravel-ignition": "^2.0",
"symfony/polyfill-iconv": "^1.26",
"vimeo/laravel": "^5.6"
},
Expand All @@ -41,8 +39,8 @@
"filp/whoops": "^2.0",
"knuckleswtf/scribe": "^4.0",
"mockery/mockery": "^1.0",
"nunomaduro/collision": "^6.1",
"phpunit/phpunit": "^9.0"
"nunomaduro/collision": "^7.0",
"phpunit/phpunit": "^10.0"
},
"config": {
"optimize-autoloader": true,
Expand Down Expand Up @@ -70,7 +68,7 @@
"Tests\\": "tests/"
}
},
"minimum-stability": "dev",
"minimum-stability": "stable",
"prefer-stable": true,
"scripts": {
"post-autoload-dump": [
Expand Down
16 changes: 8 additions & 8 deletions composer.json.dev
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,23 @@
}
],
"require": {
"php": "^8.0",
"php": "^8.1",
"ext-json": "*",
"bugsnag/bugsnag-laravel": "^2.0",
"doctrine/dbal": "2.*",
"doctrine/dbal": "^3.0",
"dompdf/dompdf": "^2.0",
"easyrdf/easyrdf": "^1.1",
"encore/laravel-admin": "^1.7",
"spatie/laravel-ignition": "^1.0",
"fideloper/proxy": "^4.0",
"guzzlehttp/guzzle": "^7.0.1",
"highsolutions/laravel-environments": "*",
"imsglobal/lti-1p3-tool": "dev-master",
"laravel/framework": "^9.0",
"laravel/framework": "^10.0",
"laravel/tinker": "^2.0",
"league/oauth2-client": "^2.4",
"mantas-done/subtitles": "^0.3.10",
"nesbot/carbon": "*",
"spatie/laravel-data": "^3.11",
"spatie/laravel-ignition": "^2.0",
"symfony/polyfill-iconv": "^1.26",
"vimeo/laravel": "^5.6"
},
"require-dev": {
Expand All @@ -39,8 +39,8 @@
"filp/whoops": "^2.0",
"knuckleswtf/scribe": "^4.0",
"mockery/mockery": "^1.0",
"nunomaduro/collision": "^6.1",
"phpunit/phpunit": "^9.0"
"nunomaduro/collision": "^7.0",
"phpunit/phpunit": "^10.0"
},
"config": {
"optimize-autoloader": true,
Expand Down
16 changes: 8 additions & 8 deletions composer.json.prod
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,23 @@
}
],
"require": {
"php": "^8.0",
"php": "^8.1",
"ext-json": "*",
"bugsnag/bugsnag-laravel": "^2.0",
"doctrine/dbal": "2.*",
"doctrine/dbal": "^3.0",
"dompdf/dompdf": "^2.0",
"easyrdf/easyrdf": "^1.1",
"encore/laravel-admin": "^1.7",
"spatie/laravel-ignition": "^1.0",
"fideloper/proxy": "^4.0",
"guzzlehttp/guzzle": "^7.0.1",
"highsolutions/laravel-environments": "*",
"imsglobal/lti-1p3-tool": "dev-master",
"laravel/framework": "^9.0",
"laravel/framework": "^10.0",
"laravel/tinker": "^2.0",
"league/oauth2-client": "^2.4",
"mantas-done/subtitles": "^0.3.10",
"nesbot/carbon": "*",
"spatie/laravel-data": "^3.11",
"spatie/laravel-ignition": "^2.0",
"symfony/polyfill-iconv": "^1.26",
"vimeo/laravel": "^5.6"
},
"require-dev": {
Expand All @@ -39,8 +39,8 @@
"filp/whoops": "^2.0",
"knuckleswtf/scribe": "^4.0",
"mockery/mockery": "^1.0",
"nunomaduro/collision": "^6.1",
"phpunit/phpunit": "^9.0"
"nunomaduro/collision": "^7.0",
"phpunit/phpunit": "^10.0"
},
"config": {
"optimize-autoloader": true,
Expand Down
Loading

0 comments on commit e3d3fc7

Please sign in to comment.