RewriteEngine On
RewriteCond %{REQUEST_URI} ^/index\.php$ [OR]
- RewriteCond %{REQUEST_URI} ^/$
+ RewriteCond %{REQUEST_URI} ^/$ [OR]
+ RewriteCond %{REQUEST_URI} ^/api/page
RewriteRule ^(.+)$ /panel? [L]
RewriteCond %{REQUEST_FILENAME} !-d
"^/themes/(.+)$" => "/themes/$1",
"^/assets/(.+)$" => "/assets/$1",
"^/((index\.php)?\?.+)?$" => "/index.php/panel/",
+ "^/api/page" => "/index.php/panel/",
"^/(.+)$" => "/index.php/$1"
)
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/index\.php$ [OR]
- RewriteCond %{REQUEST_URI} ^/$
+ RewriteCond %{REQUEST_URI} ^/$ [OR]
+ RewriteCond %{REQUEST_URI} ^/api/page
RewriteRule ^(.+)$ /panel? [L]
RewriteCond %{REQUEST_FILENAME} !-d
"^/themes/(.+)$" => "/themes/$1",
"^/assets/(.+)$" => "/assets/$1",
"^/((index\.php)?\?.+)?$" => "/index.php/panel/",
+ "^/api/page" => "/index.php/panel/",
"^/(.+)$" => "/index.php/$1"
)
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/index\.php$ [OR]
- RewriteCond %{REQUEST_URI} ^/$
+ RewriteCond %{REQUEST_URI} ^/$ [OR]
+ RewriteCond %{REQUEST_URI} ^/api/page
RewriteRule ^(.+)$ /panel? [L]
RewriteCond %{REQUEST_FILENAME} !-d
"^/themes/(.+)$" => "/themes/$1",
"^/assets/(.+)$" => "/assets/$1",
"^/((index\.php)?\?.+)?$" => "/index.php/panel/",
+ "^/api/page" => "/index.php/panel/",
"^/(.+)$" => "/index.php/$1"
)
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/index\.php$ [OR]
- RewriteCond %{REQUEST_URI} ^/$
+ RewriteCond %{REQUEST_URI} ^/$ [OR]
+ RewriteCond %{REQUEST_URI} ^/api/page
RewriteRule ^(.+)$ /panel? [L]
RewriteCond %{REQUEST_FILENAME} !-d
"^/themes/(.+)$" => "/themes/$1",
"^/assets/(.+)$" => "/assets/$1",
"^/((index\.php)?\?.+)?$" => "/index.php/panel/",
+ "^/api/page" => "/index.php/panel/",
"^/(.+)$" => "/index.php/$1"
)
--- /dev/null
+<?php
+/*
+ * Bacula(R) - The Network Backup Solution
+ * Baculum - Bacula web interface
+ *
+ * Copyright (C) 2013-2019 Kern Sibbald
+ *
+ * The main author of Baculum is Marcin Haba.
+ * The original author of Bacula is Kern Sibbald, with contributions
+ * from many others, a complete list can be found in the file AUTHORS.
+ *
+ * You may use this file and others of this release according to the
+ * license defined in the LICENSE file, which includes the Affero General
+ * Public License, v3.0 ("AGPLv3") and some additional permissions and
+ * terms pursuant to its AGPLv3 Section 7.
+ *
+ * This notice must be preserved when any source code is
+ * conveyed and/or propagated.
+ *
+ * Bacula(R) is a registered trademark of Kern Sibbald.
+ */
+
+Prado::using('Application.API.Pages.OAuth2.Authorize');
+?>
--- /dev/null
+<?php
+/*
+ * Bacula(R) - The Network Backup Solution
+ * Baculum - Bacula web interface
+ *
+ * Copyright (C) 2013-2019 Kern Sibbald
+ *
+ * The main author of Baculum is Marcin Haba.
+ * The original author of Bacula is Kern Sibbald, with contributions
+ * from many others, a complete list can be found in the file AUTHORS.
+ *
+ * You may use this file and others of this release according to the
+ * license defined in the LICENSE file, which includes the Affero General
+ * Public License, v3.0 ("AGPLv3") and some additional permissions and
+ * terms pursuant to its AGPLv3 Section 7.
+ *
+ * This notice must be preserved when any source code is
+ * conveyed and/or propagated.
+ *
+ * Bacula(R) is a registered trademark of Kern Sibbald.
+ */
+
+Prado::using('Application.API.Pages.OAuth2.RequestToken');
+?>
<using namespace="Application.API.Class.BaculumAPIServer" />
</paths>
<modules>
- <!-- auth modules -->
+ <!-- OAuth2 - only to be compatible with old OAuth2 endpoints -->
+ <!-- Remove it in the future but keep oauth2_token (it is used in this service to remove old tokens) -->
+ <module id="oauth2" class="Application.API.Class.OAuth2.BaculumOAuth2" />
+ <module id="oauth2_config" class="Application.API.Class.OAuth2.OAuth2Config" />
+ <module id="oauth2_authid" class="Application.API.Class.OAuth2.AuthIdManager" />
<module id="oauth2_token" class="Application.API.Class.OAuth2.TokenManager" />
+
<!-- database modules -->
<module id="db" class="Application.API.Class.Database" />
<module id="client" class="Application.API.Class.ClientManager" />
<urls>
<!-- #### NEW API version 1 #### -->
+
+ <!-- OAuth2 - only to be compatible with old OAuth2 endpoints -->
+ <!-- Remove it in the future -->
+ <url ServiceParameter="Authorize" pattern="api/auth/" />
+ <url ServiceParameter="RequestToken" pattern="api/token/" />
+
<!-- general endpoint -->
<url ServiceParameter="Welcome" pattern="api/v1/welcome/" />
<!-- bconsole endpoints -->