aboutsummaryrefslogtreecommitdiffhomepage
path: root/routes/keys.php
diff options
context:
space:
mode:
Diffstat (limited to 'routes/keys.php')
-rw-r--r--routes/keys.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/routes/keys.php b/routes/keys.php
new file mode 100644
index 0000000..52c7b3a
--- /dev/null
+++ b/routes/keys.php
@@ -0,0 +1,18 @@
+<?php
+/*
+|--------------------------------------------------------------------------
+| Routes for public keys
+|--------------------------------------------------------------------------
+|
+| Here is where you can register web routes for your application. These
+| routes are loaded by the RouteServiceProvider within a group which
+| contains the "web" middleware group. Now create something great!
+|
+ */
+Auth::routes();
+Route::middleware('auth', 'throttle:30') // throttle to 30 per minute
+ ->group(function () {
+ Route::get('keys/cookie/public/', 'PublicKeyController@setUsersKeyByCookie');
+ Route::get('keys/public/{user_id}', 'PublicKeyController@getUsersKey');
+ Route::post('keys/public', 'PublicKeyController@setUsersKey');
+ });