summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorGerrit Uitslag <klapinklapin@gmail.com>2014-05-19 20:45:57 +0200
committerGerrit Uitslag <klapinklapin@gmail.com>2014-05-19 20:45:57 +0200
commitb66e5840006078112b8da741b2c612e446afd452 (patch)
treea7067fa152428b3c0b41cae8435a94997167bacb /lib
parentc8d7c9382a31eaccc516f088312894797f4fe4bb (diff)
parent54b26fbe1e0f9efaba143d88ea8581933f5c8dc8 (diff)
downloadrpg-b66e5840006078112b8da741b2c612e446afd452.tar.gz
rpg-b66e5840006078112b8da741b2c612e446afd452.tar.bz2
Merge remote-tracking branch 'origin/master' into trailingcolons
Conflicts: lib/plugins/usermanager/lang/nl/intro.txt
Diffstat (limited to 'lib')
-rw-r--r--lib/plugins/authad/lang/ja/lang.php8
-rw-r--r--lib/plugins/authad/lang/ja/settings.php2
-rw-r--r--lib/plugins/authldap/auth.php60
-rw-r--r--lib/plugins/authldap/lang/ja/settings.php7
-rw-r--r--lib/plugins/extension/lang/ja/intro_install.txt2
-rw-r--r--lib/plugins/extension/lang/ja/intro_plugins.txt2
-rw-r--r--lib/plugins/extension/lang/ja/intro_templates.txt2
-rw-r--r--lib/plugins/extension/lang/ja/lang.php4
-rw-r--r--lib/plugins/extension/lang/nl/lang.php2
-rw-r--r--lib/plugins/revert/lang/nl/intro.txt2
-rw-r--r--lib/plugins/revert/lang/nl/lang.php3
-rw-r--r--lib/plugins/usermanager/lang/nl/intro.txt2
-rw-r--r--lib/plugins/usermanager/lang/nl/lang.php3
13 files changed, 89 insertions, 10 deletions
diff --git a/lib/plugins/authad/lang/ja/lang.php b/lib/plugins/authad/lang/ja/lang.php
new file mode 100644
index 000000000..b40aa5da3
--- /dev/null
+++ b/lib/plugins/authad/lang/ja/lang.php
@@ -0,0 +1,8 @@
+<?php
+
+/**
+ * @license GPL 2 (http://www.gnu.org/licenses/gpl.html)
+ *
+ * @author PzF_X <jp_minecraft@yahoo.co.jp>
+ */
+$lang['domain'] = 'ログオン時のドメイン';
diff --git a/lib/plugins/authad/lang/ja/settings.php b/lib/plugins/authad/lang/ja/settings.php
index f308249ef..118e8348c 100644
--- a/lib/plugins/authad/lang/ja/settings.php
+++ b/lib/plugins/authad/lang/ja/settings.php
@@ -5,6 +5,7 @@
*
* @author Satoshi Sahara <sahara.satoshi@gmail.com>
* @author Hideaki SAWADA <chuno@live.jp>
+ * @author PzF_X <jp_minecraft@yahoo.co.jp>
*/
$lang['account_suffix'] = 'アカウントの接尾語。例:<code>@my.domain.org</code>';
$lang['base_dn'] = 'ベースDN。例:<code>DC=my,DC=domain,DC=org</code>';
@@ -12,6 +13,7 @@ $lang['domain_controllers'] = 'ドメインコントローラのカンマ区
$lang['admin_username'] = '全ユーザーデータへのアクセス権のある特権Active Directoryユーザー。任意ですが、メール通知の登録等の特定の動作に必要。';
$lang['admin_password'] = '上記ユーザーのパスワード';
$lang['sso'] = 'Kerberos か NTLM を使ったシングルサインオン(SSO)をしますか?';
+$lang['sso_charset'] = 'サーバーは空のUTF-8かLatin-1でKerberosかNTLMユーザネームを送信します。iconv拡張モジュールが必要です。';
$lang['real_primarygroup'] = '"Domain Users" を仮定する代わりに本当のプライマリグループを解決する(低速)';
$lang['use_ssl'] = 'SSL接続を使用しますか?使用した場合、下のSSLを有効にしないでください。';
$lang['use_tls'] = 'TLS接続を使用しますか?使用した場合、上のSSLを有効にしないでください。';
diff --git a/lib/plugins/authldap/auth.php b/lib/plugins/authldap/auth.php
index 6c3637e15..0d5e130ea 100644
--- a/lib/plugins/authldap/auth.php
+++ b/lib/plugins/authldap/auth.php
@@ -36,8 +36,8 @@ class auth_plugin_authldap extends DokuWiki_Auth_Plugin {
return;
}
- // auth_ldap currently just handles authentication, so no
- // capabilities are set
+ // Add the capabilities to change the password
+ $this->cando['modPass'] = true;
}
/**
@@ -264,6 +264,62 @@ class auth_plugin_authldap extends DokuWiki_Auth_Plugin {
}
/**
+ * Definition of the function modifyUser in order to modify the password
+ */
+
+ function modifyUser($user,$changes){
+
+ // open the connection to the ldap
+ if(!$this->_openLDAP()){
+ msg('LDAP cannot connect: '. htmlspecialchars(ldap_error($this->con)));
+ return false;
+ }
+
+ // find the information about the user, in particular the "dn"
+ $info = $this->getUserData($user,true);
+ if(empty($info['dn'])) {
+ msg('LDAP cannot find your user dn');
+ return false;
+ }
+ $dn = $info['dn'];
+
+ // find the old password of the user
+ list($loginuser,$loginsticky,$loginpass) = auth_getCookie();
+ if ($loginuser !== null) { // the user is currently logged in
+ $secret = auth_cookiesalt(!$loginsticky, true);
+ $pass = auth_decrypt($loginpass, $secret);
+
+ // bind with the ldap
+ if(!@ldap_bind($this->con, $dn, $pass)){
+ msg('LDAP user bind failed: '. htmlspecialchars($dn) .': '.htmlspecialchars(ldap_error($this->con)), 0, __LINE__, __FILE__);
+ return false;
+ }
+ } elseif ($this->getConf('binddn') && $this->getConf('bindpw')) {
+ // we are changing the password on behalf of the user (eg: forgotten password)
+ // bind with the superuser ldap
+ if (!@ldap_bind($this->con, $this->getConf('binddn'), $this->getConf('bindpw'))){
+ $this->_debug('LDAP bind as superuser: '.htmlspecialchars(ldap_error($this->con)), 0, __LINE__, __FILE__);
+ return false;
+ }
+ }
+ else {
+ return false; // no otherway
+ }
+
+ // Generate the salted hashed password for LDAP
+ $phash = new PassHash();
+ $hash = $phash->hash_ssha($changes['pass']);
+
+ // change the password
+ if(!@ldap_mod_replace($this->con, $dn,array('userpassword' => $hash))){
+ msg('LDAP mod replace failed: '. htmlspecialchars($dn) .': '.htmlspecialchars(ldap_error($this->con)));
+ return false;
+ }
+
+ return true;
+ }
+
+ /**
* Most values in LDAP are case-insensitive
*
* @return bool
diff --git a/lib/plugins/authldap/lang/ja/settings.php b/lib/plugins/authldap/lang/ja/settings.php
index 3c0e08f6a..6cff0ea67 100644
--- a/lib/plugins/authldap/lang/ja/settings.php
+++ b/lib/plugins/authldap/lang/ja/settings.php
@@ -6,6 +6,7 @@
* @author Satoshi Sahara <sahara.satoshi@gmail.com>
* @author Hideaki SAWADA <sawadakun@live.jp>
* @author Hideaki SAWADA <chuno@live.jp>
+ * @author PzF_X <jp_minecraft@yahoo.co.jp>
*/
$lang['server'] = 'LDAPサーバー。ホスト名(<code>localhost</code>)又は完全修飾URL(<code>ldap://server.tld:389</code>)';
$lang['port'] = '上記が完全修飾URLでない場合、LDAPサーバーポート';
@@ -15,8 +16,14 @@ $lang['userfilter'] = 'ユーザーアカウントを探すためのL
$lang['groupfilter'] = 'グループを探すLDAP抽出条件。例:<code>(&amp;(objectClass=posixGroup)(|(gidNumber=%{gid})(memberUID=%{user})))</code>';
$lang['version'] = '使用するプロトコルのバージョン。<code>3</code>を設定する必要がある場合があります。';
$lang['starttls'] = 'TLS接続を使用しますか?';
+$lang['referrals'] = '紹介に従いますか?';
+$lang['deref'] = 'どのように間接参照のエイリアスにしますか?';
$lang['binddn'] = '匿名バインドでは不十分な場合、オプションバインドユーザーのDN。例:<code>cn=admin, dc=my, dc=home</code>';
$lang['bindpw'] = '上記ユーザーのパスワード';
+$lang['userscope'] = 'ユーザー検索の範囲を限定させる';
+$lang['groupscope'] = 'グループ検索の範囲を限定させる';
+$lang['groupkey'] = 'ユーザー属性をグループのメンバーシップから設定します(代わりに標準のADグループ)。
+例えば、部署や電話番号などです。';
$lang['debug'] = 'エラーに関して追加のデバッグ情報を表示する。';
$lang['deref_o_0'] = 'LDAP_DEREF_NEVER';
$lang['deref_o_1'] = 'LDAP_DEREF_SEARCHING';
diff --git a/lib/plugins/extension/lang/ja/intro_install.txt b/lib/plugins/extension/lang/ja/intro_install.txt
index 889ed6879..9f99b8202 100644
--- a/lib/plugins/extension/lang/ja/intro_install.txt
+++ b/lib/plugins/extension/lang/ja/intro_install.txt
@@ -1 +1 @@
-ここでは、アップロードするかダウンロードURLを指定して、手動でプラグインやテンプレートをインストールできます。
+アップロードするかダウンロードURLを指定して、手動でプラグインやテンプレートをインストールできます。
diff --git a/lib/plugins/extension/lang/ja/intro_plugins.txt b/lib/plugins/extension/lang/ja/intro_plugins.txt
index 9bfc68431..b8251c7e8 100644
--- a/lib/plugins/extension/lang/ja/intro_plugins.txt
+++ b/lib/plugins/extension/lang/ja/intro_plugins.txt
@@ -1 +1 @@
-このDokuWikiに現在インストールされているプラグインです。ここでは、これらプラグインを有効化、無効化、アンインストールすることができます。同様にプラグインのアップデートも表示されます。アップデート前に、プラグインのマニュアルをお読みください。 \ No newline at end of file
+このDokuWikiに現在インストールされているプラグインです。これらプラグインを有効化、無効化、アンインストールできます。更新はできる場合のみ表示されます。更新前に、プラグインの解説をお読みください。 \ No newline at end of file
diff --git a/lib/plugins/extension/lang/ja/intro_templates.txt b/lib/plugins/extension/lang/ja/intro_templates.txt
index f97694aaa..5de6d2f0d 100644
--- a/lib/plugins/extension/lang/ja/intro_templates.txt
+++ b/lib/plugins/extension/lang/ja/intro_templates.txt
@@ -1 +1 @@
-このDokuWikiに現在インストールされているテンプレートです。[[?do=admin&page=config|設定管理]]で使用するテンプレートを選択できます。 \ No newline at end of file
+このDokuWikiに現在インストールされているテンプレートです。使用するテンプレートは[[?do=admin&page=config|設定管理]]で選択できます。 \ No newline at end of file
diff --git a/lib/plugins/extension/lang/ja/lang.php b/lib/plugins/extension/lang/ja/lang.php
index b42e4aefd..dec46d629 100644
--- a/lib/plugins/extension/lang/ja/lang.php
+++ b/lib/plugins/extension/lang/ja/lang.php
@@ -4,6 +4,7 @@
* @license GPL 2 (http://www.gnu.org/licenses/gpl.html)
*
* @author Hideaki SAWADA <chuno@live.jp>
+ * @author PzF_X <jp_minecraft@yahoo.co.jp>
*/
$lang['menu'] = '拡張機能管理';
$lang['tab_plugins'] = 'インストール済プラグイン';
@@ -52,8 +53,10 @@ $lang['provides'] = '提供:';
$lang['status'] = '状態:';
$lang['status_installed'] = 'インストール済';
$lang['status_not_installed'] = '未インストール';
+$lang['status_protected'] = '保護されています';
$lang['status_enabled'] = '有効';
$lang['status_disabled'] = '無効';
+$lang['status_unmodifiable'] = '編集不可';
$lang['status_plugin'] = 'プラグイン';
$lang['status_template'] = 'テンプレート';
$lang['status_bundled'] = '同梱';
@@ -83,3 +86,4 @@ $lang['nopluginperms'] = 'プラグインディレクトリが書き込
$lang['git'] = 'この拡張機能は Git 経由でインストールされており、ここで更新すべきでないかもしれません。';
$lang['install_url'] = 'URL からインストール:';
$lang['install_upload'] = '拡張機能をアップロード:';
+$lang['repo_error'] = 'プラグインのリポジトリに接続できません。サーバーが www.dokuwiki.org に接続できることやプロキシの設定を確認して下さい。';
diff --git a/lib/plugins/extension/lang/nl/lang.php b/lib/plugins/extension/lang/nl/lang.php
index 524c2b2e7..c1c72e812 100644
--- a/lib/plugins/extension/lang/nl/lang.php
+++ b/lib/plugins/extension/lang/nl/lang.php
@@ -6,7 +6,7 @@
* @author Rene <wllywlnt@yahoo.com>
* @author Gerrit Uitslag <klapinklapin@gmail.com>
*/
-$lang['menu'] = 'Uitbreidings Beheerder';
+$lang['menu'] = 'Uitbreidingen';
$lang['tab_plugins'] = 'Geïnstalleerde Plugins';
$lang['tab_templates'] = 'Geïnstalleerde Templates';
$lang['tab_search'] = 'Zoek en installeer';
diff --git a/lib/plugins/revert/lang/nl/intro.txt b/lib/plugins/revert/lang/nl/intro.txt
index db8f5a06c..efa325839 100644
--- a/lib/plugins/revert/lang/nl/intro.txt
+++ b/lib/plugins/revert/lang/nl/intro.txt
@@ -1,3 +1,3 @@
-===== Herstelmanager =====
+===== Herstel =====
Deze pagina helpt u bij het herstellen van pagina's na een spam-aanval. Vul een zoekterm in (bijvoorbeeld een spam url) om een lijst te krijgen van bekladde pagina's, bevestig dat de pagina's inderdaad spam bevatten en herstel de wijzigingen.
diff --git a/lib/plugins/revert/lang/nl/lang.php b/lib/plugins/revert/lang/nl/lang.php
index ee8678e63..d04b96869 100644
--- a/lib/plugins/revert/lang/nl/lang.php
+++ b/lib/plugins/revert/lang/nl/lang.php
@@ -16,8 +16,9 @@
* @author Ricardo Guijt <ricardoguijt@gmail.com>
* @author Gerrit <klapinklapin@gmail.com>
* @author Remon <no@email.local>
+ * @author Rene <wllywlnt@yahoo.com>
*/
-$lang['menu'] = 'Herstelmanager';
+$lang['menu'] = 'Herstel';
$lang['filter'] = 'Zoek naar bekladde pagina\'s';
$lang['revert'] = 'Herstel geselecteerde pagina\'s';
$lang['reverted'] = '%s hersteld naar revisie %s';
diff --git a/lib/plugins/usermanager/lang/nl/intro.txt b/lib/plugins/usermanager/lang/nl/intro.txt
index 46968ac2d..819e64d7d 100644
--- a/lib/plugins/usermanager/lang/nl/intro.txt
+++ b/lib/plugins/usermanager/lang/nl/intro.txt
@@ -1 +1 @@
-====== Gebruikersmanager ======
+====== Gebruikersbeheer ======
diff --git a/lib/plugins/usermanager/lang/nl/lang.php b/lib/plugins/usermanager/lang/nl/lang.php
index 5cebede89..3f9902e14 100644
--- a/lib/plugins/usermanager/lang/nl/lang.php
+++ b/lib/plugins/usermanager/lang/nl/lang.php
@@ -15,8 +15,9 @@
* @author Jeroen
* @author Ricardo Guijt <ricardoguijt@gmail.com>
* @author Gerrit Uitslag <klapinklapin@gmail.com>
+ * @author Rene <wllywlnt@yahoo.com>
*/
-$lang['menu'] = 'Gebruikersmanager';
+$lang['menu'] = 'Gebruikersbeheer';
$lang['noauth'] = '(gebruikersauthenticatie niet beschikbaar)';
$lang['nosupport'] = '(gebruikersbeheer niet ondersteund)';
$lang['badauth'] = 'ongeldige authenticatiemethode';