Compare commits
12 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2aa9412565 | |||
| 35ab5c7df0 | |||
| 8a7cd87644 | |||
| 1cdf6f8263 | |||
| b8ad930690 | |||
| ec14a117b7 | |||
| b7cc12a466 | |||
| f4080a7aa9 | |||
| 5abfbdd1d2 | |||
| 31bbb2d035 | |||
| 33dca84ec7 | |||
| 460485d843 |
@@ -76,6 +76,7 @@ ENCRYPT=false
|
||||
COOKIE_NAME=snipeit_session
|
||||
COOKIE_DOMAIN=null
|
||||
SECURE_COOKIES=false
|
||||
API_TOKEN_EXPIRATION_YEARS=40
|
||||
|
||||
# --------------------------------------------
|
||||
# OPTIONAL: SECURITY HEADER SETTINGS
|
||||
|
||||
@@ -87,8 +87,9 @@ class AuthServiceProvider extends ServiceProvider
|
||||
|
||||
$this->registerPolicies();
|
||||
Passport::routes();
|
||||
Passport::tokensExpireIn(Carbon::now()->addYears(20));
|
||||
Passport::refreshTokensExpireIn(Carbon::now()->addYears(20));
|
||||
Passport::tokensExpireIn(Carbon::now()->addYears(config('passport.expiration_years')));
|
||||
Passport::refreshTokensExpireIn(Carbon::now()->addYears(config('passport.expiration_years')));
|
||||
Passport::personalAccessTokensExpireIn(Carbon::now()->addYears(config('passport.expiration_years')));
|
||||
Passport::withCookieSerialization();
|
||||
|
||||
|
||||
|
||||
@@ -12,4 +12,5 @@ return [
|
||||
*/
|
||||
'private_key' => env('PASSPORT_PRIVATE_KEY'),
|
||||
'public_key' => env('PASSPORT_PUBLIC_KEY'),
|
||||
'expiration_years' => env('API_TOKEN_EXPIRATION_YEARS', 20),
|
||||
];
|
||||
+5
-5
@@ -1,10 +1,10 @@
|
||||
<?php
|
||||
return array (
|
||||
'app_version' => 'v5.0.5',
|
||||
'full_app_version' => 'v5.0.5-52-g63a8535de',
|
||||
'build_version' => '5509',
|
||||
'app_version' => 'v5.0.6',
|
||||
'full_app_version' => 'v5.0.6-5526-g8a7cd8764',
|
||||
'build_version' => '5526',
|
||||
'prerelease_version' => '',
|
||||
'hash_version' => 'g63a8535de',
|
||||
'full_hash' => 'v5.0.5-52-g63a8535de',
|
||||
'hash_version' => 'g8a7cd8764',
|
||||
'full_hash' => 'v5.0.6-5526-g8a7cd8764',
|
||||
'branch' => 'master',
|
||||
);
|
||||
File diff suppressed because one or more lines are too long
Vendored
+26
-26
File diff suppressed because one or more lines are too long
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"/js/build/app.js": "/js/build/app.js?id=fc54bb0c7977c14f519b",
|
||||
"/js/build/app.js": "/js/build/app.js?id=df0e9d334d5c0b0eb048",
|
||||
"/css/build/AdminLTE.css": "/css/build/AdminLTE.css?id=59413334823616b81341",
|
||||
"/css/build/app.css": "/css/build/app.css?id=032fd8c3fce99c7fd862",
|
||||
"/css/build/overrides.css": "/css/build/overrides.css?id=0b4aefd7ef0c117ef23a",
|
||||
@@ -34,5 +34,5 @@
|
||||
"/css/dist/bootstrap-table.css": "/css/dist/bootstrap-table.css?id=1e77fde04b3f42432581",
|
||||
"/js/build/vendor.js": "/js/build/vendor.js?id=aff75d5aad5e7b429723",
|
||||
"/js/dist/bootstrap-table.js": "/js/dist/bootstrap-table.js?id=58d95c93430f2ae33392",
|
||||
"/js/dist/all.js": "/js/dist/all.js?id=0a2c2c95ab18fa16faa1"
|
||||
"/js/dist/all.js": "/js/dist/all.js?id=5dc677546cc6d86e605d"
|
||||
}
|
||||
|
||||
@@ -31,8 +31,10 @@
|
||||
<table class="table table-borderless m-b-none" v-if="tokens.length > 0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="col-md-9">Name</th>
|
||||
<th class="col-md-3"><span class="sr-only">Delete</span></th>
|
||||
<th class="col-md-3">Name</th>
|
||||
<th class="col-md-2">Created</th>
|
||||
<th class="col-md-2">Expires</th>
|
||||
<th class="col-md-2"><span class="sr-only">Delete</span></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@@ -43,6 +45,14 @@
|
||||
{{ token.name }}
|
||||
</td>
|
||||
|
||||
<td style="vertical-align: middle;">
|
||||
{{ token.created_at }}
|
||||
</td>
|
||||
|
||||
<td style="vertical-align: middle;">
|
||||
{{ token.expires_at }}
|
||||
</td>
|
||||
|
||||
<!-- Delete Button -->
|
||||
<td style="vertical-align: middle;" class="text-right">
|
||||
<a class="action-link btn btn-danger btn-sm" @click="revoke(token)">
|
||||
|
||||
@@ -27,6 +27,8 @@
|
||||
<code>{{ url('/api/v1') }}</code></p>
|
||||
|
||||
<p>When you generate an API token, be sure to copy it down immediately as they will not be visible to you again. </p>
|
||||
|
||||
<p>API tokens will expire in {{ config('passport.expiration_years') }} years.</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -154,8 +154,9 @@ View Assets for {{ $user->present()->fullName() }}
|
||||
}'>
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="col-md-5">{{ trans('general.name') }}</th>
|
||||
<th class="col-md-4">{{ trans('general.name') }}</th>
|
||||
<th class="col-md-4">{{ trans('admin/hardware/form.serial') }}</th>
|
||||
<th class="col-md-4">{{ trans('general.category') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -169,6 +170,7 @@ View Assets for {{ $user->present()->fullName() }}
|
||||
------------
|
||||
@endcan
|
||||
</td>
|
||||
<td>{{ $license->category->name }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
@@ -211,13 +213,15 @@ View Assets for {{ $user->present()->fullName() }}
|
||||
}'>
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="col-md-12">{{ trans('general.name') }}</th>
|
||||
<th class="col-md-8">{{ trans('general.name') }}</th>
|
||||
<th class="col-md-4">{{ trans('general.category') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach ($user->consumables as $consumable)
|
||||
<tr>
|
||||
<td>{{ $consumable->name }}</td>
|
||||
<td>{{ $consumable->category->name }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
@@ -264,13 +268,15 @@ View Assets for {{ $user->present()->fullName() }}
|
||||
}'>
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="col-md-12">Name</th>
|
||||
<th class="col-md-8">{{ trans('general.name') }}</th>
|
||||
<th class="col-md-4">{{ trans('general.category') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach ($user->accessories as $accessory)
|
||||
<tr>
|
||||
<td>{{ $accessory->name }}</td>
|
||||
<td>{{ $accessory->category->name }}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
|
||||
Reference in New Issue
Block a user