Пример #1
0
<?php

OCP\App::register(array('order' => 10, 'id' => 'remoteStorage', 'name' => 'remoteStorage compatibility'));
OCP\App::registerPersonal('remoteStorage', 'settings');
Пример #2
0
* GNU AFFERO GENERAL PUBLIC LICENSE for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library.  If not, see <http://www.gnu.org/licenses/>.
*
*
* This uses the Zend OpenID implementation, find a tutorial about it at http://framework.zend.com/manual/en/zend.openid.html .
*
*/
OC::$CLASSPATH['OC_OpenIdProviderUserSession'] = 'user_openid_provider/lib/OpenIdProviderUserSession.php';
OC::$CLASSPATH['OC_OpenIdProviderStorage'] = 'user_openid_provider/lib/OpenIdProviderStorage.php';
$userName = '';
if (strpos($_SERVER["REQUEST_URI"], '?') and !strpos($_SERVER["REQUEST_URI"], '=')) {
    if (strpos($_SERVER["REQUEST_URI"], '/?') !== false) {
        $userName = substr($_SERVER["REQUEST_URI"], strpos($_SERVER["REQUEST_URI"], '/?') + 2);
    } elseif (strpos($_SERVER["REQUEST_URI"], '.php?') !== false) {
        $userName = substr($_SERVER["REQUEST_URI"], strpos($_SERVER["REQUEST_URI"], '.php?') + 5);
    }
}
$remote_token = 'openid_provider';
if (($pos = strpos($_SERVER["REQUEST_URI"], $remote_token)) !== false) {
    $pos += strlen($remote_token) + 1;
    $userName = substr($_SERVER['REQUEST_URI'], $pos);
}
//die('username: '******'') {
    OCP\Util::addHeader('link', array('rel' => 'openid.server', 'href' => OCP\Util::linkToRemote($remote_token) . $userName));
    OCP\Util::addHeader('link', array('rel' => 'openid.delegate', 'href' => OCP\Util::linkToAbsolute('', '?') . $userName));
}
OCP\App::registerPersonal('user_openid_provider', 'settings');
Пример #3
0
<?php

/**
 * ownCloud - RainLoop mail plugin
 *
 * @author RainLoop Team
 * @copyright 2015 RainLoop Team
 *
 * https://github.com/RainLoop/owncloud
 */
OC::$CLASSPATH['OC_RainLoop_Helper'] = OC_App::getAppPath('rainloop') . '/lib/RainLoopHelper.php';
OCP\App::registerAdmin('rainloop', 'admin');
OCP\App::registerPersonal('rainloop', 'personal');
if (OCP\Config::getAppValue('rainloop', 'rainloop-autologin', false)) {
    OCP\Util::connectHook('OC_User', 'post_login', 'OC_RainLoop_Helper', 'login');
    OCP\Util::connectHook('OC_User', 'post_setPassword', 'OC_RainLoop_Helper', 'changePassword');
}
OCP\Util::connectHook('OC_User', 'logout', 'OC_RainLoop_Helper', 'logout');
OCP\Util::addScript('rainloop', 'rainloop');
OCP\App::addNavigationEntry(array('id' => 'rainloop_index', 'order' => 10, 'href' => OCP\Util::linkToRoute('rainloop_index'), 'icon' => OCP\Util::imagePath('rainloop', 'mail.png'), 'name' => 'Email'));
Пример #4
0
<?php

/**
* ownCloud - Tattoo
*
* @author Arthur Schiwon
* @copyright 2012 Arthur Schiwon blizzz@owncloud.com
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
* License as published by the Free Software Foundation; either
* version 3 of the License, or any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
* GNU AFFERO GENERAL PUBLIC LICENSE for more details.
*
* You should have received a copy of the GNU Affero General Public
* License along with this library.  If not, see <http://www.gnu.org/licenses/>.
*
*/
OCP\App::registerPersonal('tattoo', 'settings');
$wallpaper = OCP\Config::getUserValue(OCP\User::getUser(), 'tattoo', 'wallpaper', 'none');
if ($wallpaper != 'none') {
    OCP\Util::addStyle('tattoo', 'tattoo');
    OCP\Util::addScript('tattoo', 'tattoo');
}
Пример #5
0
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library.  If not, see <http://www.gnu.org/
 *
 */
$l = OC_L10N::get('media');
OC::$CLASSPATH['OCA\\Media\\Media'] = 'media/lib/media.php';
OC::$CLASSPATH['OCA\\Media\\Ampache'] = 'media/lib/ampache.php';
OC::$CLASSPATH['OCA\\Media\\SearchProvider'] = 'media/lib/media.php';
OC::$CLASSPATH['OCA\\Media\\Collection'] = 'media/lib/collection.php';
OC::$CLASSPATH['OCA\\Media\\Scanner'] = 'media/lib/scanner.php';
OC::$CLASSPATH['OCA\\Media\\Extractor'] = 'media/lib/extractor.php';
OC::$CLASSPATH['OCA\\Media\\Extractor_GetID3'] = 'media/lib/extractor.php';
OC::$CLASSPATH['OCA\\Media\\Extractable'] = 'media/lib/track.php';
OC::$CLASSPATH['OCA\\Media\\Track'] = 'media/lib/track.php';
//we need to have the sha256 hash of passwords for ampache
OCP\Util::connectHook('OC_User', 'post_login', 'OCA\\Media\\Media', 'loginListener');
OCP\Util::connectHook('OC_User', 'post_setPassword', 'OCA\\Media\\Media', 'passwordChangeListener');
//connect to the filesystem for auto updating
OCP\Util::connectHook('OC_Filesystem', 'post_write', 'OCA\\Media\\Media', 'updateFile');
//listen for file deletions to clean the database if a song is deleted
OCP\Util::connectHook('OC_Filesystem', 'post_delete', 'OCA\\Media\\Media', 'deleteFile');
//list for file moves to update the database
OCP\Util::connectHook('OC_Filesystem', 'post_rename', 'OCA\\Media\\Media', 'moveFile');
OCP\App::registerPersonal('media', 'settings');
OCP\App::addNavigationEntry(array('id' => 'media_index', 'order' => 2, 'href' => OCP\Util::linkTo('media', 'index.php'), 'icon' => OCP\Util::imagePath('core', 'places/music.svg'), 'name' => $l->t('Music')));
OC_Search::registerProvider('OCA\\Media\\SearchProvider');
Пример #6
0
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 */
use OCA\ocUsageCharts\AppInfo\Chart;
OCP\App::checkAppEnabled('ocusagecharts');
OCP\App::setActiveNavigationEntry('ocusagecharts');
OCP\App::registerPersonal('ocusagecharts', 'personal');
OCP\App::registerAdmin('ocusagecharts', 'admin');
OCP\App::addNavigationEntry(array('id' => 'ocusagecharts', 'order' => 60, 'href' => \OCP\Util::linkToRoute('ocusagecharts.chart.frontpage'), 'icon' => OCP\Util::imagePath('ocusagecharts', 'iconchart.png'), 'name' => \OC_L10N::get('ocusagecharts')->t('ocUsageCharts')));
\OCP\Util::addStyle('ocusagecharts', 'style');
\OCP\Backgroundjob::registerJob('OCA\\ocUsageCharts\\Job\\UpdateChartsJob');
$app = new Chart();
$x = $app->getContainer()->query('FileHooks');
$x->register();
$useApi = $app->getContainer()->query('ServerContainer')->getConfig()->getAppValue($app->getContainer()->query('AppName'), 'useapi');
if ($useApi) {
    \OCP\Backgroundjob::registerJob('OCA\\ocUsageCharts\\Job\\UpdateContentStatisticsJob');
}
Пример #7
0
OC::$CLASSPATH['OC_ocDownloader'] = 'apps/ocdownloader/lib/ocDownloader.class.php';

$l = OC_L10N::get('ocdownloader');

if(!OC_ocDownloader::isUpToDate(OCP\Config::getAppValue('ocdownloader', 'installed_version'))){
	OC_ocDownloader::initProviders(dirname(__FILE__) . '/providers.xml');
}

OCP\App::register(Array(
	'order' => 30,
	'id' => 'ocdownloader',
	'name' => 'ocDownloader'
));

OCP\App::addNavigationEntry(Array(
	'id' => 'ocdownloader_index',
	'order' => 30,
	'href' => OCP\Util::linkTo('ocdownloader', 'downloader.php'),
	'icon' => OCP\Util::imagePath('ocdownloader', 'dl.png'),
	'name' => 'ocDownloader'
));

OCP\App::registerPersonal('ocdownloader', 'personalsettings');

$data_dir = OCP\Config::getSystemValue('datadirectory', '');
if(OCP\User::getUser() && strlen($data_dir) != 0){
	$fs = OCP\Files::getStorage('files');
	if(!$fs->is_dir('/Downloads')){
		$fs->mkdir('/Downloads');
	}
}
Пример #8
0
<?php

$l = OC_L10N::get('calendar');
OC::$CLASSPATH['OC_Calendar_App'] = 'apps/calendar/lib/app.php';
OC::$CLASSPATH['OC_Calendar_Calendar'] = 'apps/calendar/lib/calendar.php';
OC::$CLASSPATH['OC_Calendar_Object'] = 'apps/calendar/lib/object.php';
OC::$CLASSPATH['OC_Calendar_Hooks'] = 'apps/calendar/lib/hooks.php';
OC::$CLASSPATH['OC_Connector_Sabre_CalDAV'] = 'apps/calendar/lib/connector_sabre.php';
OC::$CLASSPATH['OC_Calendar_Share'] = 'apps/calendar/lib/share.php';
OC::$CLASSPATH['OC_Search_Provider_Calendar'] = 'apps/calendar/lib/search.php';
OCP\Util::connectHook('OC_User', 'post_deleteUser', 'OC_Calendar_Hooks', 'deleteUser');
OCP\Util::addscript('calendar', 'loader');
OCP\Util::addscript("3rdparty", "chosen/chosen.jquery.min");
OCP\Util::addStyle("3rdparty", "chosen/chosen");
OCP\App::register(array('order' => 10, 'id' => 'calendar', 'name' => 'Calendar'));
OCP\App::addNavigationEntry(array('id' => 'calendar_index', 'order' => 10, 'href' => OCP\Util::linkTo('calendar', 'index.php'), 'icon' => OCP\Util::imagePath('calendar', 'icon.svg'), 'name' => $l->t('Calendar')));
OCP\App::registerPersonal('calendar', 'settings');
OC_Search::registerProvider('OC_Search_Provider_Calendar');
Пример #9
0
*
* @author Florian Hülsmann
* @copyright 2012 Florian Hülsmann <*****@*****.**>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
* License as published by the Free Software Foundation; either
* version 3 of the License, or any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
* GNU AFFERO GENERAL PUBLIC LICENSE for more details.
*
* You should have received a copy of the GNU Affero General Public
* License along with this library.  If not, see <http://www.gnu.org/licenses/>.
*
*/
$l = OC_L10N::get('notify');
OC::$CLASSPATH['OC_Notify'] = 'apps/notify/lib/notify.php';
if (OCP\User::isLoggedIn()) {
    // this makes no sense for guests, so only for users
    OCP\Util::addScript('notify', 'notifications');
    OCP\Util::addStyle('notify', 'notifications');
    OCP\Util::addStyle('notify', 'customNotifications');
    OCP\Util::addHeader('link', array('rel' => 'alternate', 'type' => 'application/atom+xml', 'title' => $l->t('ownCloud notifications (%s)', 'Atom 1.0'), 'href' => OCP\Util::linkToRemote('notify_feed') . 'feed.atom'));
    OCP\Util::addHeader('link', array('rel' => 'alternate', 'type' => 'application/rss+xml', 'title' => $l->t('ownCloud notifications (%s)', 'RSS 2.0'), 'href' => OCP\Util::linkToRemote('notify_feed') . 'feed.atom'));
    OCP\App::registerPersonal('notify', 'personal');
    OCP\Util::connectHook('OC_User', 'post_deleteUser', 'OC_Notify', 'post_deleteUser');
    OCP\Util::connectHook('OCP\\Share', 'post_shared', 'OC_Notify', 'post_shared');
}
Пример #10
0
 * Copyright (C) 2013 Andreas Ergenzinger andreas.ergenzinger@uni-konstanz.de
 *
 * This library is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this library. If not, see <http://www.gnu.org/licenses/>.
 */
require_once OC_App::getAppPath('user_shibboleth') . '/appinfo/bootstrap.php';
OCP\App::registerAdmin('user_shibboleth', 'settings');
OCP\App::registerPersonal('user_shibboleth', 'personal');
// register user backend
OC_User::useBackend(new OCA\user_shibboleth\UserShibboleth());
// add settings page to navigation
$entry = array('id' => 'user_shibboleth_settings', 'order' => 1, 'href' => OCP\Util::linkTo('user_shibboleth', 'settings.php'), 'name' => 'Shibboleth Authentication');
//add login button
$link = OCA\user_shibboleth\LoginLib::getForwardingPageUrl();
$buttonText = 'Shibboleth';
$federationName = OCP\Config::getAppValue('user_shibboleth', 'federation_name', '');
if ($federationName !== '') {
    $buttonText .= ' – ' . $federationName;
}
$shibbolethLogin = array('href' => $link, 'name' => $buttonText);
OC_App::registerLogIn($shibbolethLogin);
Пример #11
0
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library.  If not, see <http://www.gnu.org/licenses/>.
 *
 */
$l = new OC_L10N('roundcube');
OC::$CLASSPATH['OC_Mail_NetworkingException'] = OC_App::getAppPath('roundcube') . '/lib/MailNetworkingException.class.php';
OC::$CLASSPATH['OC_Mail_LoginException'] = OC_App::getAppPath('roundcube') . '/lib/MailLoginException.class.php';
OC::$CLASSPATH['OC_Mail_RC_InstallNotFoundException'] = OC_App::getAppPath('roundcube') . '/lib/MailRoundCubeNotFoundException.class.php';
OC::$CLASSPATH['OC_Mail_Object'] = OC_App::getAppPath('roundcube') . '/lib/MailObject.class.php';
OC::$CLASSPATH['OC_RoundCube_App'] = OC_App::getAppPath('roundcube') . '/lib/RoundCubeApp.class.php';
OC::$CLASSPATH['OC_RoundCube_DB_Util'] = OC_App::getAppPath('roundcube') . '/lib/RoundCubeDBUtil.class.php';
OC::$CLASSPATH['OC_RoundCube_Login'] = OC_App::getAppPath('roundcube') . '/lib/RoundCubeLogin.class.php';
OC::$CLASSPATH['OC_RoundCube_AuthHelper'] = OC_App::getAppPath('roundcube') . '/lib/RoundCubeAuthHelper.class.php';
OCP\Util::connectHook('OC_User', 'post_login', 'OC_RoundCube_AuthHelper', 'login');
OCP\Util::connectHook('OC_User', 'logout', 'OC_RoundCube_AuthHelper', 'logout');
OCP\Util::connectHook('OC_User', 'post_setPassword', 'OC_RoundCube_AuthHelper', 'changePasswordListener');
// set refresh interval in JS namespace
OCP\Util::connectHook('\\OCP\\Config', 'js', 'OC_RoundCube_AuthHelper', 'jsLoadHook');
// probably no longer needed, now that we use routes ...
if (!OCP\Config::getAppValue('roundcube', 'rcNoCronRefresh', false)) {
    OCP\BackgroundJob::AddRegularTask('OC_RoundCube_AuthHelper', 'refresh');
}
// Add global JS routines; this one triggers an RC session refresh by
// periodically calling the refresh-script via js setInterval()
OCP\Util::addScript('roundcube', 'routes');
OCP\App::registerAdmin('roundcube', 'adminSettings');
OCP\App::registerPersonal('roundcube', 'userSettings');
OCP\App::addNavigationEntry(array('id' => 'roundcube_index', 'order' => 10, 'href' => OCP\Util::linkTo('roundcube', 'index.php'), 'icon' => OCP\Util::imagePath('roundcube', 'mail.svg'), 'name' => $l->t('Webmail')));
Пример #12
0
<?php

OC::$CLASSPATH['OC_Contacts_App'] = 'apps/contacts/lib/app.php';
OC::$CLASSPATH['OC_Contacts_Addressbook'] = 'apps/contacts/lib/addressbook.php';
OC::$CLASSPATH['OC_Contacts_VCard'] = 'apps/contacts/lib/vcard.php';
OC::$CLASSPATH['OC_Contacts_Hooks'] = 'apps/contacts/lib/hooks.php';
OC::$CLASSPATH['OC_Connector_Sabre_CardDAV'] = 'apps/contacts/lib/connector_sabre.php';
OC::$CLASSPATH['OC_Search_Provider_Contacts'] = 'apps/contacts/lib/search.php';
OCP\Util::connectHook('OC_User', 'post_deleteUser', 'OC_Contacts_Hooks', 'deleteUser');
OCP\Util::connectHook('OC_Calendar', 'getEvents', 'OC_Contacts_Hooks', 'getBirthdayEvents');
OCP\Util::connectHook('OC_Calendar', 'getSources', 'OC_Contacts_Hooks', 'getCalenderSources');
OCP\App::register(array('order' => 10, 'id' => 'contacts', 'name' => 'Contacts'));
OCP\App::addNavigationEntry(array('id' => 'contacts_index', 'order' => 10, 'href' => OCP\Util::linkTo('contacts', 'index.php'), 'icon' => OCP\Util::imagePath('settings', 'users.svg'), 'name' => OC_L10N::get('contacts')->t('Contacts')));
OCP\App::registerPersonal('contacts', 'settings');
OCP\Util::addscript('contacts', 'loader');
OC_Search::registerProvider('OC_Search_Provider_Contacts');
Пример #13
0
<?php

/**
 * ownCloud
 *
 * @author Michal Jaskurzynski
 * @copyright 2012 Michal Jaskurzynski mjaskurzynski@gmail.com
 *
 */
OC::$CLASSPATH['OCA_mozilla_sync\\InputData'] = 'apps/mozilla_sync/lib/inputdata.php';
OC::$CLASSPATH['OCA_mozilla_sync\\OutputData'] = 'apps/mozilla_sync/lib/outputdata.php';
OC::$CLASSPATH['OCA_mozilla_sync\\User'] = '******';
OC::$CLASSPATH['OCA_mozilla_sync\\UrlParser'] = 'apps/mozilla_sync/lib/urlparser.php';
OC::$CLASSPATH['OCA_mozilla_sync\\Utils'] = 'apps/mozilla_sync/lib/utils.php';
OC::$CLASSPATH['OCA_mozilla_sync\\Storage'] = 'apps/mozilla_sync/lib/storage.php';
OC::$CLASSPATH['OCA_mozilla_sync\\Service'] = 'apps/mozilla_sync/lib/service.php';
OC::$CLASSPATH['OCA_mozilla_sync\\StorageService'] = 'apps/mozilla_sync/lib/storageservice.php';
OC::$CLASSPATH['OCA_mozilla_sync\\UserService'] = 'apps/mozilla_sync/lib/userservice.php';
OCP\App::registerPersonal('mozilla_sync', 'settings');
Пример #14
0
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
 * License as published by the Free Software Foundation; either 
 * version 3 of the License, or any later version.
 * 
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
 *  
 * You should have received a copy of the GNU Lesser General Public 
 * License along with this library.  If not, see <http://www.gnu.org/licenses/>.
 * 
 */
OCP\App::register(array('order' => 70, 'id' => 'documents', 'name' => 'Documents'));
//OCP\App::registerAdmin('documents', 'settings');
OCP\App::registerPersonal('documents', 'personal');
OCP\App::addNavigationEntry(array('id' => 'documents_index', 'order' => 2, 'href' => OCP\Util::linkTo('documents', 'index.php'), 'icon' => OCP\Util::imagePath('documents', 'documents.svg'), 'name' => OCA\Documents\Config::getL10n()->t('Documents')));
OC::$CLASSPATH['OCA\\Documents\\Controller'] = 'documents/ajax/controller.php';
OC::$CLASSPATH['OCA\\Documents\\DocumentController'] = 'documents/ajax/documentController.php';
OC::$CLASSPATH['OCA\\Documents\\SessionController'] = 'documents/ajax/sessionController.php';
OC::$CLASSPATH['OCA\\Documents\\UserController'] = 'documents/ajax/userController.php';
OC::$CLASSPATH['OCA\\Documents\\Download_Simple'] = 'documents/lib/download/simple.php';
OC::$CLASSPATH['OCA\\Documents\\Download_Range'] = 'documents/lib/download/range.php';
OC::$CLASSPATH['OCA\\Documents\\Db_Session'] = 'documents/lib/db/session.php';
OC::$CLASSPATH['OCA\\Documents\\Db_Member'] = 'documents/lib/db/member.php';
OC::$CLASSPATH['OCA\\Documents\\Db_Op'] = 'documents/lib/db/op.php';
//Script for registering file actions
OCP\Util::addScript('documents', 'viewer/viewer');
//Listen to delete file signal
OCP\Util::connectHook('OC_Filesystem', 'delete', "OCA\\Documents\\Storage", "onDelete");
Пример #15
0
<?php

/**
* Copyright (c) 2011 Marvin Thomas Rabe <*****@*****.**>
* Copyright (c) 2011 Arthur Schiwon <*****@*****.**>
* This file is licensed under the Affero General Public License version 3 or
* later.
* See the COPYING-README file.
*/
OC::$CLASSPATH['OC_Bookmarks_Bookmarks'] = 'apps/bookmarks/lib/bookmarks.php';
OC::$CLASSPATH['OC_Search_Provider_Bookmarks'] = 'apps/bookmarks/lib/search.php';
OCP\App::register(array('order' => 70, 'id' => 'bookmark', 'name' => 'Bookmarks'));
$l = new OC_l10n('bookmarks');
OCP\App::addNavigationEntry(array('id' => 'bookmarks_index', 'order' => 70, 'href' => OCP\Util::linkTo('bookmarks', 'index.php'), 'icon' => OCP\Util::imagePath('bookmarks', 'bookmarks.png'), 'name' => $l->t('Bookmarks')));
OCP\App::registerPersonal('bookmarks', 'settings');
OCP\Util::addscript('bookmarks', 'bookmarksearch');
OC_Search::registerProvider('OC_Search_Provider_Bookmarks');
Пример #16
0
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License, version 3,
 * along with this program.  If not, see <http://www.gnu.org/licenses/>
 *
 */
OC::$CLASSPATH['OC\\Files\\Storage\\StreamWrapper'] = 'files_external/lib/streamwrapper.php';
OC::$CLASSPATH['OC\\Files\\Storage\\FTP'] = 'files_external/lib/ftp.php';
OC::$CLASSPATH['OC\\Files\\Storage\\OwnCloud'] = 'files_external/lib/owncloud.php';
OC::$CLASSPATH['OC\\Files\\Storage\\Google'] = 'files_external/lib/google.php';
OC::$CLASSPATH['OC\\Files\\Storage\\Swift'] = 'files_external/lib/swift.php';
OC::$CLASSPATH['OC\\Files\\Storage\\SMB'] = 'files_external/lib/smb.php';
OC::$CLASSPATH['OC\\Files\\Storage\\AmazonS3'] = 'files_external/lib/amazons3.php';
OC::$CLASSPATH['OC\\Files\\Storage\\Dropbox'] = 'files_external/lib/dropbox.php';
OC::$CLASSPATH['OC\\Files\\Storage\\SFTP'] = 'files_external/lib/sftp.php';
OC::$CLASSPATH['OC_Mount_Config'] = 'files_external/lib/config.php';
OC::$CLASSPATH['OCA\\Files\\External\\Api'] = 'files_external/lib/api.php';
require_once __DIR__ . '/../3rdparty/autoload.php';
// register Application object singleton
\OC_Mount_Config::$app = new \OCA\Files_external\Appinfo\Application();
$appContainer = \OC_Mount_Config::$app->getContainer();
$l = \OC::$server->getL10N('files_external');
OCP\App::registerAdmin('files_external', 'settings');
if (OCP\Config::getAppValue('files_external', 'allow_user_mounting', 'yes') == 'yes') {
    OCP\App::registerPersonal('files_external', 'personal');
}
\OCA\Files\App::getNavigationManager()->add(["id" => 'extstoragemounts', "appname" => 'files_external', "script" => 'list.php', "order" => 30, "name" => $l->t('External storage')]);
$mountProvider = $appContainer->query('OCA\\Files_External\\Config\\ConfigAdapter');
\OC::$server->getMountProviderCollection()->registerProvider($mountProvider);
Пример #17
0
<?php

//require_once 'files_versions/versions.php';
OC::$CLASSPATH['OCA_Versions\\Storage'] = 'apps/files_versions/lib/versions.php';
OC::$CLASSPATH['OCA_Versions\\Hooks'] = 'apps/files_versions/lib/hooks.php';
OCP\App::registerAdmin('files_versions', 'settings');
OCP\App::registerPersonal('files_versions', 'settings-personal');
OCP\Util::addscript('files_versions', 'versions');
// Listen to write signals
OCP\Util::connectHook('OC_Filesystem', 'post_write', "OCA_Versions\\Hooks", "write_hook");
// Listen to delete and rename signals
OCP\Util::connectHook('OC_Filesystem', 'delete', "OCA_Versions\\Hooks", "remove_hook");
OCP\Util::connectHook('OC_Filesystem', 'rename', "OCA_Versions\\Hooks", "rename_hook");
Пример #18
0
<?php

/**
* ownCloud - user_migrate
*
* @author Tom Needham
* @copyright 2012 Tom Needham tom@owncloud.com
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
* License as published by the Free Software Foundation; either
* version 3 of the License, or any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
* GNU AFFERO GENERAL PUBLIC LICENSE for more details.
*
* You should have received a copy of the GNU Affero General Public
* License along with this library.  If not, see <http://www.gnu.org/licenses/>.
*
*/
OCP\App::registerPersonal('user_migrate', 'settings');
OCP\Util::addscript('user_migrate', 'export');
OCP\Util::addstyle('user_migrate', 'style');
// add settings page to navigation
$entry = array('id' => "user_migrate_settings", 'order' => 1, 'href' => OCP\Util::linkTo("user_migrate", "admin.php"), 'name' => 'Import');
Пример #19
0
<?php

/**
 * ownCloud - Activity App
 *
 * @author Frank Karlitschek
 * @copyright 2013 Frank Karlitschek frank@owncloud.org
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
 * License as published by the Free Software Foundation; either
 * version 3 of the License, or any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
 *
 * You should have received a copy of the GNU Affero General Public
 * License along with this library.  If not, see <http://www.gnu.org/licenses/>.
 *
 */
$l = OC_L10N::get('activity');
// add an navigation entry
OCP\App::addNavigationEntry(array('id' => 'activity', 'order' => 1, 'href' => OCP\Util::linkToRoute('activity.index'), 'icon' => OCP\Util::imagePath('activity', 'activity.svg'), 'name' => $l->t('Activity')));
// register the hooks for filesystem operations. All other events from other apps has to be send via the public api
OCA\Activity\Hooks::register();
// Personal settings for notifications and emails
OCP\App::registerPersonal('activity', 'personal');
// Cron job for sending Emails
OCP\Backgroundjob::registerJob('OCA\\Activity\\BackgroundJob\\EmailNotification');
Пример #20
0
//check if curl extension installed
if (!in_array('curl', get_loaded_extensions())) {
    return;
}
$userName = '';
if (strpos($_SERVER["REQUEST_URI"], '?') and !strpos($_SERVER["REQUEST_URI"], '=')) {
    if (strpos($_SERVER["REQUEST_URI"], '/?')) {
        $userName = substr($_SERVER["REQUEST_URI"], strpos($_SERVER["REQUEST_URI"], '/?') + 2);
    } elseif (strpos($_SERVER["REQUEST_URI"], '.php?')) {
        $userName = substr($_SERVER["REQUEST_URI"], strpos($_SERVER["REQUEST_URI"], '.php?') + 5);
    }
}
OCP\Util::addHeader('link', array('rel' => 'openid.server', 'href' => OCP\Util::linkToAbsolute("user_openid", "user.php") . '/' . $userName));
OCP\Util::addHeader('link', array('rel' => 'openid.delegate', 'href' => OCP\Util::linkToAbsolute("user_openid", "user.php") . '/' . $userName));
OCP\App::registerPersonal('user_openid', 'settings');
require_once 'apps/user_openid/user_openid.php';
//active the openid backend
OC_User::useBackend('openid');
//check for results from openid requests
if (isset($_GET['openid_mode']) and $_GET['openid_mode'] == 'id_res') {
    OCP\Util::writeLog('user_openid', 'openid retured', OCP\Util::DEBUG);
    $openid = new SimpleOpenID();
    $openid->SetIdentity($_GET['openid_identity']);
    $openid_validation_result = $openid->ValidateWithServer();
    if ($openid_validation_result == true) {
        // OK HERE KEY IS VALID
        OCP\Util::writeLog('user_openid', 'auth sucessfull', OCP\Util::DEBUG);
        $identity = $openid->GetIdentity();
        OCP\Util::writeLog('user_openid', 'auth as ' . $identity, OCP\Util::DEBUG);
        $user = OC_USER_OPENID::findUserForIdentity($identity);
Пример #21
0
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
 *
 * You should have received a copy of the GNU AFFERO GENERAL PUBLIC
 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
 * Displays <a href="http://opensource.org/licenses/AGPL-3.0">GNU AFFERO GENERAL PUBLIC LICENSE</a>
 * @license http://opensource.org/licenses/AGPL-3.0 GNU AFFERO GENERAL PUBLIC LICENSE
 *
 */
include_once "user_otp/lib/otp.php";
OC::$CLASSPATH['OC_USER_OTP'] = 'user_otp/lib/otp.php';
OCP\App::registerAdmin('user_otp', 'adminSettings');
OCP\App::registerPersonal('user_otp', 'personalSettings');
//if(OCP\Config::getAppValue('user_otp','forceCreateUsers')){
//    OCP\Util::connectHook('OC_User','pre_createUser','OC_USER_OTP','deleteBackends');
//}
//if(OCP\Config::getAppValue('user_otp','disableBackends')){
//    OC_User::clearBackends();
//}
// Nothing to do if user is already logged
//if (!OCP\User::isLoggedIn()){
if (OCP\Config::getAppValue('user_otp', 'authMethod', _AUTH_DEFAULT_) !== _AUTH_STANDARD_) {
    //OC_Log::write('user_otp', 'app load', OC_Log::DEBUG);
    $usedBackends = OC_User::getUsedBackends();
    OC_User::clearBackends();
    OC_USER_OTP::registerBackends($usedBackends);
    OC_User::useBackend('OTP');
    //$otpBackend = new OC_USER_OTP($usedBackends);
Пример #22
0
    // User related hooks
    OCA\Encryption\Helper::registerUserHooks();
    // Sharing related hooks
    OCA\Encryption\Helper::registerShareHooks();
    // Filesystem related hooks
    OCA\Encryption\Helper::registerFilesystemHooks();
    // App manager related hooks
    OCA\Encryption\Helper::registerAppHooks();
    if (!in_array('crypt', stream_get_wrappers())) {
        stream_wrapper_register('crypt', 'OCA\\Encryption\\Stream');
    }
    // check if we are logged in
    if (OCP\User::isLoggedIn()) {
        // ensure filesystem is loaded
        if (!\OC\Files\Filesystem::$loaded) {
            \OC_Util::setupFS();
        }
        $view = new OC_FilesystemView('/');
        $sessionReady = OCA\Encryption\Helper::checkRequirements();
        if ($sessionReady) {
            $session = new \OCA\Encryption\Session($view);
        }
    }
} else {
    // logout user if we are in maintenance to force re-login
    OCP\User::logout();
}
// Register settings scripts
OCP\App::registerAdmin('files_encryption', 'settings-admin');
OCP\App::registerPersonal('files_encryption', 'settings-personal');
Пример #23
0
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library.  If not, see <http://www.gnu.org/licenses/>.
 *
 */
OCP\App::checkAppEnabled('storagecharts2');
$l = new OC_L10N('storagecharts2');
OC::$CLASSPATH['OC_DLStCharts'] = OC_App::getAppPath('storagecharts2') . "/lib/db.class.php";
OC::$CLASSPATH['OC_DLStChartsLoader'] = OC_App::getAppPath('storagecharts2') . "/lib/loader.class.php";
OCP\App::addNavigationEntry(array('id' => 'storagecharts2_index', 'order' => 60, 'href' => OCP\Util::linkTo('storagecharts2', 'index.php'), 'icon' => OCP\Util::imagePath('storagecharts2', 'app.svg'), 'name' => $l->t('Usage')));
OCP\App::registerPersonal('storagecharts2', 'settings');
// Get storage value for logged in user
$data_dir = OCP\Config::getSystemValue('datadirectory', '');
if (OCP\User::getUser() && strlen($data_dir) != 0) {
    $fs = OCP\Files::getStorage('files');
    // workaround to detect OC version
    $ocVersion = @reset(OCP\Util::getVersion());
    // OC 5
    if ($ocVersion < 6) {
        OCP\Util::writeLog('storagecharts2', 'Running on OwnCloud 5', OCP\Util::DEBUG);
        $used = OC_DLStCharts::getTotalDataSize(OC::$CONFIG_DATADIRECTORY);
        // OC 6 or greater
    } else {
        $datadir = OC_Config::getValue('datadirectory') . '/' . OCP\User::getUser();
        OCP\Util::writeLog('storagecharts2', 'Running on OwnCloud ' . $ocVersion, OCP\Util::DEBUG);
        $used = OC_DLStCharts::getTotalDataSize($datadir);
Пример #24
0
<?php

OC::$CLASSPATH['OCA\\Mail\\App'] = 'apps/mail/lib/mail.php';
OC::$CLASSPATH['OCA\\Mail\\Account'] = 'apps/mail/lib/account.php';
OC::$CLASSPATH['OCA\\Mail\\Mailbox'] = 'apps/mail/lib/mailbox.php';
OC::$CLASSPATH['OCA\\Mail\\Message'] = 'apps/mail/lib/message.php';
OC::$CLASSPATH['OC_Translation_Handler'] = 'apps/mail/lib/OC_Translation_Handler.php';
OCP\App::addNavigationEntry(array('id' => 'mail_index', 'order' => 1, 'href' => OCP\Util::linkTo('mail', 'index.php'), 'icon' => OCP\Util::imagePath('mail', 'icon.png'), 'name' => 'Mail'));
OCP\App::registerPersonal('mail', 'settings');
Пример #25
0
$app_path = OC_APP::getAppPath('user_wordpress');
require_once $app_path . '/lib/wordpress.class.php';
require_once $app_path . '/user_wordpress.php';
require_once $app_path . '/group_wordpress.php';
OC::$CLASSPATH['OC_wordpress_images_menu_sites_icon'] = $app_path . '/img/wordpress.svg';
$normalize_path = str_replace('\\', '/', OC_APP::getAppPath('user_wordpress'));
$path_array = explode('/', $normalize_path);
array_pop($path_array);
$app_folder = array_pop($path_array);
OC::$CLASSPATH['OC_wordpress'] = $app_folder . '/lib/wordpress.class.php';
OC::$CLASSPATH['OC_wordpress_site_list'] = $app_path . '/wordpress.php';
OCP\Util::addStyle('user_wordpress', 'wordpress');
OCP\Util::addScript('user_wordpress', 'wordpress');
OCP\App::register(array('order' => 29, 'id' => 'cloudpress', 'name' => 'Cloudpress'));
OCP\App::registerAdmin('user_wordpress', 'settings');
OCP\App::registerPersonal('user_wordpress', 'persopress');
$wp_instance = new OC_wordpress();
if (isset($_POST['wordpress_settings_post'])) {
    foreach ($wp_instance->params as $param => $value) {
        if (isset($_POST[$param])) {
            OC_Appconfig::setValue('user_wordpress', $param, $_POST[$param]);
            $wp_instance->params[$param] = $_POST[$param];
        } else {
            OC_Appconfig::setValue('user_wordpress', $param, '');
            $wp_instance->params[$param] = '';
        }
    }
}
if ($wp_instance->params['wordpress_add_button'] == 1) {
    OCP\App::addNavigationEntry(array('id' => 'wordpress_sites', 'order' => 70, 'href' => OCP\Util::linkTo('user_wordpress', 'wordpress.php'), 'icon' => OC::$CLASSPATH['OC_wordpress_images_menu_sites_icon'], 'name' => 'Sites'));
}