Line 34 | Line 34 |
---|
$user->add_lang('acp/board');
|
$user->add_lang('acp/board');
|
include_once($phpbb_root_path . 'includes/functions_jabber.' . $phpEx);
| if (!class_exists('jabber')) { include($phpbb_root_path . 'includes/functions_jabber.' . $phpEx); }
|
$action = request_var('action', ''); $submit = (isset($_POST['submit'])) ? true : false;
| $action = request_var('action', ''); $submit = (isset($_POST['submit'])) ? true : false;
|
Line 47 | Line 50 |
---|
$this->tpl_name = 'acp_jabber'; $this->page_title = 'ACP_JABBER_SETTINGS';
|
$this->tpl_name = 'acp_jabber'; $this->page_title = 'ACP_JABBER_SETTINGS';
|
$jab_enable = request_var('jab_enable', (bool) $config['jab_enable']); $jab_host = request_var('jab_host', (string) $config['jab_host']); $jab_port = request_var('jab_port', (int) $config['jab_port']); $jab_username = request_var('jab_username', (string) $config['jab_username']); $jab_password = request_var('jab_password', (string) $config['jab_password']); $jab_package_size = request_var('jab_package_size', (int) $config['jab_package_size']); $jab_use_ssl = request_var('jab_use_ssl', (bool) $config['jab_use_ssl']);
| $jab_enable = request_var('jab_enable', (bool) $config['jab_enable']); $jab_host = request_var('jab_host', (string) $config['jab_host']); $jab_port = request_var('jab_port', (int) $config['jab_port']); $jab_username = request_var('jab_username', (string) $config['jab_username']); $jab_password = request_var('jab_password', (string) $config['jab_password']); $jab_package_size = request_var('jab_package_size', (int) $config['jab_package_size']); $jab_use_ssl = request_var('jab_use_ssl', (bool) $config['jab_use_ssl']); $jab_verify_peer = request_var('jab_verify_peer', (bool) $config['jab_verify_peer']); $jab_verify_peer_name = request_var('jab_verify_peer_name', (bool) $config['jab_verify_peer_name']); $jab_allow_self_signed = request_var('jab_allow_self_signed', (bool) $config['jab_allow_self_signed']);
|
$form_name = 'acp_jabber'; add_form_key($form_name);
| $form_name = 'acp_jabber'; add_form_key($form_name);
|
Line 73 | Line 79 |
---|
// Is this feature enabled? Then try to establish a connection if ($jab_enable) {
|
// Is this feature enabled? Then try to establish a connection if ($jab_enable) {
|
$jabber = new jabber($jab_host, $jab_port, $jab_username, $jab_password, $jab_use_ssl);
| $jabber = new jabber($jab_host, $jab_port, $jab_username, $jab_password, $jab_use_ssl, $jab_verify_peer, $jab_verify_peer_name, $jab_allow_self_signed);
|
if (!$jabber->connect()) {
| if (!$jabber->connect()) {
|
Line 107 | Line 113 |
---|
set_config('jab_host', $jab_host); set_config('jab_port', $jab_port); set_config('jab_username', $jab_username);
|
set_config('jab_host', $jab_host); set_config('jab_port', $jab_port); set_config('jab_username', $jab_username);
|
| if ($jab_password !== '********') {
|
set_config('jab_password', $jab_password);
|
set_config('jab_password', $jab_password);
|
| }
|
set_config('jab_package_size', $jab_package_size); set_config('jab_use_ssl', $jab_use_ssl);
|
set_config('jab_package_size', $jab_package_size); set_config('jab_use_ssl', $jab_use_ssl);
|
| set_config('jab_verify_peer', $jab_verify_peer); set_config('jab_verify_peer_name', $jab_verify_peer_name); set_config('jab_allow_self_signed', $jab_allow_self_signed);
|
add_log('admin', 'LOG_' . $log); trigger_error($message . adm_back_link($this->u_action));
| add_log('admin', 'LOG_' . $log); trigger_error($message . adm_back_link($this->u_action));
|
Line 122 | Line 134 |
---|
'JAB_HOST' => $jab_host, 'JAB_PORT' => ($jab_port) ? $jab_port : '', 'JAB_USERNAME' => $jab_username,
|
'JAB_HOST' => $jab_host, 'JAB_PORT' => ($jab_port) ? $jab_port : '', 'JAB_USERNAME' => $jab_username,
|
'JAB_PASSWORD' => $jab_password,
| 'JAB_PASSWORD' => $jab_password !== '' ? '********' : '',
|
'JAB_PACKAGE_SIZE' => $jab_package_size, 'JAB_USE_SSL' => $jab_use_ssl,
|
'JAB_PACKAGE_SIZE' => $jab_package_size, 'JAB_USE_SSL' => $jab_use_ssl,
|
| 'JAB_VERIFY_PEER' => $jab_verify_peer, 'JAB_VERIFY_PEER_NAME' => $jab_verify_peer_name, 'JAB_ALLOW_SELF_SIGNED' => $jab_allow_self_signed,
|
'S_CAN_USE_SSL' => jabber::can_use_ssl(), 'S_GTALK_NOTE' => (!@function_exists('dns_get_record')) ? true : false, ));
| 'S_CAN_USE_SSL' => jabber::can_use_ssl(), 'S_GTALK_NOTE' => (!@function_exists('dns_get_record')) ? true : false, ));
|