Merge branch 'develop' of projects.ceondo.com:indefero into develop
This commit is contained in:
commit
fba5841bdc
@ -86,7 +86,7 @@ class IDF_Form_Password extends Pluf_Form
|
|||||||
$return_url = Pluf_HTTP_URL_urlForView('IDF_Views::passwordRecoveryInputCode');
|
$return_url = Pluf_HTTP_URL_urlForView('IDF_Views::passwordRecoveryInputCode');
|
||||||
$tmpl = new Pluf_Template('idf/user/passrecovery-email.txt');
|
$tmpl = new Pluf_Template('idf/user/passrecovery-email.txt');
|
||||||
$cr = new Pluf_Crypt(md5(Pluf::f('secret_key')));
|
$cr = new Pluf_Crypt(md5(Pluf::f('secret_key')));
|
||||||
$code = trim($cr->encrypt($user->email.':'.$user->id.':'.time()),
|
$code = trim($cr->encrypt($user->email.':'.$user->id.':'.time().':primary'),
|
||||||
'~');
|
'~');
|
||||||
$code = substr(md5(Pluf::f('secret_key').$code), 0, 2).$code;
|
$code = substr(md5(Pluf::f('secret_key').$code), 0, 2).$code;
|
||||||
$url = Pluf::f('url_base').Pluf_HTTP_URL_urlForView('IDF_Views::passwordRecovery', array($code), array(), false);
|
$url = Pluf::f('url_base').Pluf_HTTP_URL_urlForView('IDF_Views::passwordRecovery', array($code), array(), false);
|
||||||
|
@ -63,7 +63,7 @@ class IDF_Form_UserChangeEmail extends Pluf_Form
|
|||||||
throw new Pluf_Form_Invalid(__('The validation key is not valid. Please copy/paste it from your confirmation email.'));
|
throw new Pluf_Form_Invalid(__('The validation key is not valid. Please copy/paste it from your confirmation email.'));
|
||||||
}
|
}
|
||||||
$cr = new Pluf_Crypt(md5(Pluf::f('secret_key')));
|
$cr = new Pluf_Crypt(md5(Pluf::f('secret_key')));
|
||||||
return explode(':', $cr->decrypt($encrypted), 3);
|
return explode(':', $cr->decrypt($encrypted), 4);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -34,6 +34,11 @@ class IDF_Template_IssueComment extends Pluf_Template_Tag
|
|||||||
|
|
||||||
function start($text, $request, $echo=true, $wordwrap=true, $esc=true, $autolink=true, $nl2br=false)
|
function start($text, $request, $echo=true, $wordwrap=true, $esc=true, $autolink=true, $nl2br=false)
|
||||||
{
|
{
|
||||||
|
// PHP sets the backtrack limit quite low, so some regexes may
|
||||||
|
// fail unexpectedly on large inputs or weird cornercases (see issue 618)
|
||||||
|
$pcre_backtrack_limit = ini_get('pcre.backtrack_limit');
|
||||||
|
ini_set('pcre.backtrack_limit', 10000000);
|
||||||
|
|
||||||
$this->project = $request->project;
|
$this->project = $request->project;
|
||||||
$this->request = $request;
|
$this->request = $request;
|
||||||
$this->scm = IDF_Scm::get($request->project);
|
$this->scm = IDF_Scm::get($request->project);
|
||||||
@ -67,6 +72,8 @@ class IDF_Template_IssueComment extends Pluf_Template_Tag
|
|||||||
} else {
|
} else {
|
||||||
return $text;
|
return $text;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ini_set('pcre.backtrack_limit', $pcre_backtrack_limit);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -34,6 +34,11 @@ class IDF_Template_Markdown extends Pluf_Template_Tag
|
|||||||
|
|
||||||
function start($text, $request)
|
function start($text, $request)
|
||||||
{
|
{
|
||||||
|
// PHP sets the backtrack limit quite low, so some regexes may
|
||||||
|
// fail unexpectedly on large inputs or weird cornercases (see issue 618)
|
||||||
|
$pcre_backtrack_limit = ini_get('pcre.backtrack_limit');
|
||||||
|
ini_set('pcre.backtrack_limit', 10000000);
|
||||||
|
|
||||||
$this->project = $request->project;
|
$this->project = $request->project;
|
||||||
$this->request = $request;
|
$this->request = $request;
|
||||||
// Replace like in the issue text
|
// Replace like in the issue text
|
||||||
@ -56,6 +61,8 @@ class IDF_Template_Markdown extends Pluf_Template_Tag
|
|||||||
$text);
|
$text);
|
||||||
$filter = new IDF_Template_MarkdownPrefilter();
|
$filter = new IDF_Template_MarkdownPrefilter();
|
||||||
echo $filter->go(Pluf_Text_MarkDown_parse($text));
|
echo $filter->go(Pluf_Text_MarkDown_parse($text));
|
||||||
|
|
||||||
|
ini_set('pcre.backtrack_limit', $pcre_backtrack_limit);
|
||||||
}
|
}
|
||||||
|
|
||||||
function callbackWikiPageNoName($m)
|
function callbackWikiPageNoName($m)
|
||||||
|
@ -5,7 +5,7 @@ $(document).ready(function() {
|
|||||||
.addClass("wiki-" + this.tagName.toLowerCase())
|
.addClass("wiki-" + this.tagName.toLowerCase())
|
||||||
.appendTo('#wiki-toc-content');
|
.appendTo('#wiki-toc-content');
|
||||||
});
|
});
|
||||||
if ($('#wiki-toc-content').size() < 2)
|
if ($('#wiki-toc-content *').size() < 2)
|
||||||
$('#wiki-toc').hide();
|
$('#wiki-toc').hide();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user