/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to mandos

  • Committer: Teddy Hogeborn
  • Date: 2019-11-16 15:56:49 UTC
  • Revision ID: teddy@recompile.se-20191116155649-5uep6eubrwbbbomq
Documentation fix: Correct example in password-agent(8mandos)

* dracut-module/password-agent.xml (EXAMPLE): Fix the example using
  the "default location" of mandos-client to actually use the default.

Show diffs side-by-side

added added

removed removed

Lines of Context:
78
78
import collections
79
79
import codecs
80
80
import unittest
81
 
import random
82
81
 
83
82
import dbus
84
83
import dbus.service
92
91
 
93
92
if sys.version_info.major == 2:
94
93
    __metaclass__ = type
95
 
    str = unicode
96
94
 
97
95
# Show warnings by default
98
96
if not sys.warnoptions:
124
122
            # No value found
125
123
            SO_BINDTODEVICE = None
126
124
 
 
125
if sys.version_info.major == 2:
 
126
    str = unicode
 
127
 
127
128
if sys.version_info < (3, 2):
128
129
    configparser.Configparser = configparser.SafeConfigParser
129
130
 
1036
1037
        if self.checker_initiator_tag is not None:
1037
1038
            GLib.source_remove(self.checker_initiator_tag)
1038
1039
        self.checker_initiator_tag = GLib.timeout_add(
1039
 
            random.randrange(int(self.interval.total_seconds() * 1000
1040
 
                                 + 1)),
 
1040
            int(self.interval.total_seconds() * 1000),
1041
1041
            self.start_checker)
1042
1042
        # Schedule a disable() when 'timeout' has passed
1043
1043
        if self.disable_initiator_tag is not None:
1413
1413
                raise ValueError("Byte arrays not supported for non-"
1414
1414
                                 "'ay' signature {!r}"
1415
1415
                                 .format(prop._dbus_signature))
1416
 
            value = dbus.ByteArray(bytes(value))
 
1416
            value = dbus.ByteArray(b''.join(chr(byte)
 
1417
                                            for byte in value))
1417
1418
        prop(value)
1418
1419
 
1419
1420
    @dbus.service.method(dbus.PROPERTIES_IFACE,