Changeset - d2319cb2ba9b
[Not reviewed]
Merge default
0 5 0
Mads Kiilerich (mads) - 6 years ago 2019-12-19 20:50:33
mads@kiilerich.com
Merge stable
5 files changed with 12 insertions and 7 deletions:
0 comments (0 inline, 0 general)
kallithea/bin/ldap_sync.py
Show inline comments
 
@@ -29,12 +29,13 @@ from __future__ import print_function
 

	
 
import urllib2
 
import uuid
 
from ConfigParser import ConfigParser
 

	
 
import ldap
 

	
 
from kallithea.lib.compat import json
 

	
 

	
 
config = ConfigParser()
 
config.read('ldap_sync.conf')
 

	
kallithea/i18n/ru/LC_MESSAGES/kallithea.po
Show inline comments
 
@@ -77,13 +77,13 @@ msgstr "Нажмите чтобы добавить новый файл"
 

	
 
msgid "%s at %s"
 
msgstr "%s (%s)"
 

	
 
msgid "You can only delete files with revision being a valid branch"
 
msgstr ""
 
"Вы можете удалять файлы только в ревизии, связанной с существующей веткой "
 
"Вы можете удалять файлы только в ревизии, являющейся корректной веткой"
 

	
 
msgid "Deleted file %s via Kallithea"
 
msgstr "Файл %s удалён с помощью Kallithea"
 

	
 
msgid "Successfully deleted file %s"
 
msgstr "Файл %s удалён"
 
@@ -91,13 +91,13 @@ msgstr "Файл %s удалён"
 
msgid "Error occurred during commit"
 
msgstr "Во время коммита произошла ошибка"
 

	
 
msgid "You can only edit files with revision being a valid branch"
 
msgstr ""
 
"Вы можете редактировать файлы только в ревизии, связанной с существующей "
 
"веткой "
 
"веткой"
 

	
 
msgid "Edited file %s via Kallithea"
 
msgstr "Файл %s отредактирован с помощью Kallithea"
 

	
 
msgid "No changes"
 
msgstr "Без изменений"
 
@@ -708,15 +708,15 @@ msgid_plural "%d minutes"
 
msgstr[0] "%d минута"
 
msgstr[1] "%d минут"
 
msgstr[2] "%d минуты"
 

	
 
msgid "%d second"
 
msgid_plural "%d seconds"
 
msgstr[0] "%d секунды"
 
msgstr[0] "%d секунда"
 
msgstr[1] "%d секунды"
 
msgstr[2] "%d секунды"
 
msgstr[2] "%d секунд"
 

	
 
msgid "in %s"
 
msgstr "в %s"
 

	
 
msgid "%s ago"
 
msgstr "%s назад"
 
@@ -834,13 +834,13 @@ msgid "Cannot assign this group as paren
 
msgstr "Невозможно использовать эту группу как родителя"
 

	
 
msgid "Group \"%(group_name)s\" already exists"
 
msgstr "Группа \"%(group_name)s\" уже существует"
 

	
 
msgid "Repository with name \"%(group_name)s\" already exists"
 
msgstr "Репозитарий с  именем \"%(group_name)s\" уже существует"
 
msgstr "Репозиторий с именем «%(group_name)s» уже существует"
 

	
 
msgid "Invalid characters (non-ascii) in password"
 
msgstr "Недопустимые символы (не ascii) в пароле"
 

	
 
msgid "Invalid old password"
 
msgstr "Неверно задан старый пароль"
kallithea/lib/ssh.py
Show inline comments
 
@@ -63,12 +63,14 @@ def parse_pub_key(ssh_key):
 
    Traceback (most recent call last):
 
    ...
 
    SshKeyParseError: Incorrect SSH key - unexpected characters in base64 part "AAAAB3NzaC1yc2EAAAA'LVGhpcyBpcyBmYWtlIQ"
 
    >>> parse_pub_key(''' ssh-rsa  AAAAB3NzaC1yc2EAAAALVGhpcyBpcyBmYWtlIQ== and a comment
 
    ... ''')
 
    ('ssh-rsa', '\x00\x00\x00\x07ssh-rsa\x00\x00\x00\x0bThis is fake!', 'and a comment\n')
 
    >>> parse_pub_key('''ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIP1NA2kBQIKe74afUXmIWD9ByDYQJqUwW44Y4gJOBRuo''')
 
    ('ssh-ed25519', '\x00\x00\x00\x0bssh-ed25519\x00\x00\x00 \xfdM\x03i\x01@\x82\x9e\xef\x86\x9fQy\x88X?A\xc86\x10&\xa50[\x8e\x18\xe2\x02N\x05\x1b\xa8', '')
 
    """
 
    if not ssh_key:
 
        raise SshKeyParseError(_("SSH key is missing"))
 

	
 
    parts = ssh_key.split(None, 2)
 
    if len(parts) < 2:
 
@@ -83,13 +85,13 @@ def parse_pub_key(ssh_key):
 

	
 
    try:
 
        decoded = keyvalue.decode('base64')
 
    except binascii.Error:
 
        raise SshKeyParseError(_("Incorrect SSH key - failed to decode base64 part %r") % keyvalue)
 

	
 
    if not decoded.startswith('\x00\x00\x00\x07' + str(keytype) + '\x00'):
 
    if not decoded.startswith('\x00\x00\x00' + chr(len(keytype)) + str(keytype) + '\x00'):
 
        raise SshKeyParseError(_("Incorrect SSH key - base64 part is not %r as claimed but %r") % (str(keytype), str(decoded[4:].split('\0', 1)[0])))
 

	
 
    return keytype, decoded, comment
 

	
 

	
 
SSH_OPTIONS = 'no-pty,no-port-forwarding,no-X11-forwarding,no-agent-forwarding'
kallithea/templates/admin/settings/settings_visual.html
Show inline comments
 
@@ -55,12 +55,14 @@ ${h.form(url('admin_settings_visual'), m
 
                %if c.ssh_enabled:
 
                <label class="control-label">${_('SSH Clone URL')}:</label>
 
                <div>
 
                    ${h.text('clone_ssh_tmpl', size=80, class_='form-control')}
 
                    <span class="help-block">${_('''Schema for constructing SSH clone URL, eg. 'ssh://{system_user}@{hostname}/{repo}'.''')}</span>
 
                </div>
 
                %else:
 
                ${h.hidden('clone_ssh_tmpl', size=80, class_='form-control')}
 
                %endif
 
            </div>
 

	
 
            <div class="form-group">
 
                <label class="control-label" for="dashboard_items">${_('Repository page size')}:</label>
 
                <div>
scripts/make-release
Show inline comments
 
@@ -16,13 +16,13 @@ trap cleanup EXIT
 

	
 
echo "Setting up a fresh virtualenv in $venv"
 
virtualenv -p python2 "$venv"
 
. "$venv/bin/activate"
 

	
 
echo "Install/verify tools needed for building and uploading stuff"
 
pip install --upgrade -e . -r dev_requirements.txt twine
 
pip install --upgrade -e . -r dev_requirements.txt twine python-ldap python-pam
 

	
 
echo "Cleanup and update copyrights ... and clean checkout"
 
scripts/run-all-cleanup
 
scripts/update-copyrights.py
 
hg up -cr .
 

	
0 comments (0 inline, 0 general)