=== modified file 'TODO'
--- TODO 2008-11-09 06:40:29 +0000
+++ TODO 2008-11-11 16:07:18 +0000
@@ -15,17 +15,22 @@
Probably using D-Bus
See also [[*Mandos-tools]]
*** Client class
- + getHostname
- + getChecker
- + setChecker
+ Remove unneeded Get* methods?
*** Main server
+ Clients
out_signature="ao"
- Does this have to be "getClients" so as not to collide with the
+ Does this have to be "GetClients" so as not to collide with the
interface name?
- + setLogLevel
+ + SetLogLevel
syslogger.setLevel(logging.WARNING)
- + quit
+ + Quit
+ + GetClientsProperties "aa{sv}":
+ dbus.Array(dbus.Dictionary({dbus.String("name"):
+ dbus.String("foo", variant_level=1),
+ dbus.String("created"):
+ dbus.Array(dbus.Int16(2008), ...,
+ variant_level=1)}))
+ + [[http://log.ometer.com/2007-05.html][Best D-Bus practices]]
** TODO Implement --foreground :bugs:
[[info:standards:Option%20Table][Table of Long Options]]
** TODO Implement --socket
@@ -33,6 +38,8 @@
** TODO Date+time on console log messages :bugs:
Is this the default?
** TODO delete hook when clients fall out by timeout
+ This will not be strictly necessary when the D-Bus interface is
+ implemented.
* Mandos-tools/utilities
All of this probably using D-Bus
=== modified file 'mandos'
--- mandos 2008-11-09 06:40:29 +0000
+++ mandos 2008-11-11 16:07:18 +0000
@@ -11,7 +11,8 @@
# and some lines in "main".
#
# Everything else is
-# Copyright © 2008 Teddy Hogeborn & Björn Påhlsson
+# Copyright © 2008 Teddy Hogeborn
+# Copyright © 2008 Björn Påhlsson
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -68,11 +69,11 @@
version = "1.0.2"
logger = logging.Logger('mandos')
-syslogger = logging.handlers.SysLogHandler\
- (facility = logging.handlers.SysLogHandler.LOG_DAEMON,
- address = "/dev/log")
-syslogger.setFormatter(logging.Formatter\
- ('Mandos: %(levelname)s: %(message)s'))
+syslogger = (logging.handlers.SysLogHandler
+ (facility = logging.handlers.SysLogHandler.LOG_DAEMON,
+ address = "/dev/log"))
+syslogger.setFormatter(logging.Formatter
+ ('Mandos: %(levelname)s: %(message)s'))
logger.addHandler(syslogger)
console = logging.StreamHandler()
@@ -111,16 +112,13 @@
a sensible number of times
"""
def __init__(self, interface = avahi.IF_UNSPEC, name = None,
- servicetype = None, port = None, TXT = None, domain = "",
- host = "", max_renames = 32768):
+ servicetype = None, port = None, TXT = None,
+ domain = "", host = "", max_renames = 32768):
self.interface = interface
self.name = name
self.type = servicetype
self.port = port
- if TXT is None:
- self.TXT = []
- else:
- self.TXT = TXT
+ self.TXT = TXT if TXT is not None else []
self.domain = domain
self.host = host
self.rename_count = 0
@@ -135,9 +133,9 @@
self.name = server.GetAlternativeServiceName(self.name)
logger.info(u"Changing Zeroconf service name to %r ...",
str(self.name))
- syslogger.setFormatter(logging.Formatter\
+ syslogger.setFormatter(logging.Formatter
('Mandos (%s): %%(levelname)s:'
- ' %%(message)s' % self.name))
+ ' %%(message)s' % self.name))
self.remove()
self.add()
self.rename_count += 1
@@ -149,10 +147,10 @@
"""Derived from the Avahi example code"""
global group
if group is None:
- group = dbus.Interface\
- (bus.get_object(avahi.DBUS_NAME,
+ group = dbus.Interface(bus.get_object
+ (avahi.DBUS_NAME,
server.EntryGroupNew()),
- avahi.DBUS_INTERFACE_ENTRY_GROUP)
+ avahi.DBUS_INTERFACE_ENTRY_GROUP)
group.connect_to_signal('StateChanged',
entry_group_state_changed)
logger.debug(u"Adding Zeroconf service '%s' of type '%s' ...",
@@ -180,9 +178,9 @@
uniquely identify the client
secret: bytestring; sent verbatim (over TLS) to client
host: string; available for use by the checker command
- created: datetime.datetime(); object creation, not client host
- started: bool()
- last_checked_ok: datetime.datetime() or None if not yet checked OK
+ created: datetime.datetime(); (UTC) object creation
+ started: datetime.datetime(); (UTC) last started
+ last_checked_ok: datetime.datetime(); (UTC) or None
timeout: datetime.timedelta(); How long from last_checked_ok
until this client is invalid
interval: datetime.timedelta(); How often to start a new checker
@@ -203,24 +201,6 @@
_timeout_milliseconds: Used when calling gobject.timeout_add()
_interval_milliseconds: - '' -
"""
- interface = u"org.mandos_system.Mandos.Clients"
-
- @dbus.service.method(interface, out_signature="s")
- def getName(self):
- "D-Bus getter method"
- return self.name
-
- @dbus.service.method(interface, out_signature="s")
- def getFingerprint(self):
- "D-Bus getter method"
- return self.fingerprint
-
- @dbus.service.method(interface, in_signature="ay",
- byte_arrays=True)
- def setSecret(self, secret):
- "D-Bus setter method"
- self.secret = secret
-
def _set_timeout(self, timeout):
"Setter function for the 'timeout' attribute"
self._timeout = timeout
@@ -234,16 +214,6 @@
timeout = property(lambda self: self._timeout, _set_timeout)
del _set_timeout
- @dbus.service.method(interface, out_signature="t")
- def getTimeout(self):
- "D-Bus getter method"
- return self._timeout_milliseconds
-
- @dbus.service.signal(interface, signature="t")
- def TimeoutChanged(self, t):
- "D-Bus signal"
- pass
-
def _set_interval(self, interval):
"Setter function for the 'interval' attribute"
self._interval = interval
@@ -258,22 +228,12 @@
interval = property(lambda self: self._interval, _set_interval)
del _set_interval
- @dbus.service.method(interface, out_signature="t")
- def getInterval(self):
- "D-Bus getter method"
- return self._interval_milliseconds
-
- @dbus.service.signal(interface, signature="t")
- def IntervalChanged(self, t):
- "D-Bus signal"
- pass
-
def __init__(self, name = None, stop_hook=None, config=None):
"""Note: the 'checker' key in 'config' sets the
'checker_command' attribute and *not* the 'checker'
attribute."""
dbus.service.Object.__init__(self, bus,
- "/Mandos/Clients/%s"
+ "/Mandos/clients/%s"
% name.replace(".", "_"))
if config is None:
config = {}
@@ -282,23 +242,22 @@
# Uppercase and remove spaces from fingerprint for later
# comparison purposes with return value from the fingerprint()
# function
- self.fingerprint = config["fingerprint"].upper()\
- .replace(u" ", u"")
+ self.fingerprint = (config["fingerprint"].upper()
+ .replace(u" ", u""))
logger.debug(u" Fingerprint: %s", self.fingerprint)
if "secret" in config:
self.secret = config["secret"].decode(u"base64")
elif "secfile" in config:
with closing(open(os.path.expanduser
(os.path.expandvars
- (config["secfile"])))) \
- as secfile:
+ (config["secfile"])))) as secfile:
self.secret = secfile.read()
else:
raise TypeError(u"No secret or secfile for client %s"
% self.name)
self.host = config.get("host", "")
- self.created = datetime.datetime.now()
- self.started = False
+ self.created = datetime.datetime.utcnow()
+ self.started = None
self.last_checked_ok = None
self.timeout = string_to_delta(config["timeout"])
self.interval = string_to_delta(config["interval"])
@@ -311,29 +270,24 @@
def start(self):
"""Start this client's checker and timeout hooks"""
- self.started = True
+ self.started = datetime.datetime.utcnow()
# Schedule a new checker to be started an 'interval' from now,
# and every interval from then on.
- self.checker_initiator_tag = gobject.timeout_add\
- (self._interval_milliseconds,
- self.start_checker)
+ self.checker_initiator_tag = (gobject.timeout_add
+ (self._interval_milliseconds,
+ self.start_checker))
# Also start a new checker *right now*.
self.start_checker()
# Schedule a stop() when 'timeout' has passed
- self.stop_initiator_tag = gobject.timeout_add\
- (self._timeout_milliseconds,
- self.stop)
+ self.stop_initiator_tag = (gobject.timeout_add
+ (self._timeout_milliseconds,
+ self.stop))
# Emit D-Bus signal
self.StateChanged(True)
- @dbus.service.signal(interface, signature="b")
- def StateChanged(self, started):
- "D-Bus signal"
- pass
-
def stop(self):
"""Stop this client."""
- if getattr(self, "started", False):
+ if getattr(self, "started", None) is not None:
logger.info(u"Stopping client %s", self.name)
else:
return False
@@ -346,12 +300,11 @@
self.stop_checker()
if self.stop_hook:
self.stop_hook(self)
+ self.started = None
# Emit D-Bus signal
self.StateChanged(False)
# Do not run this again if called by a gobject.timeout_add
return False
- # D-Bus variant
- Stop = dbus.service.method(interface)(stop)
def __del__(self):
self.stop_hook = None
@@ -361,8 +314,8 @@
"""The checker has completed, so take appropriate actions."""
self.checker_callback_tag = None
self.checker = None
- if os.WIFEXITED(condition) \
- and (os.WEXITSTATUS(condition) == 0):
+ if (os.WIFEXITED(condition)
+ and (os.WEXITSTATUS(condition) == 0)):
logger.info(u"Checker for %(name)s succeeded",
vars(self))
# Emit D-Bus signal
@@ -379,22 +332,16 @@
# Emit D-Bus signal
self.CheckerCompleted(False)
- @dbus.service.signal(interface, signature="b")
- def CheckerCompleted(self, success):
- "D-Bus signal"
- pass
-
def bump_timeout(self):
"""Bump up the timeout for this client.
This should only be called when the client has been seen,
alive and well.
"""
- self.last_checked_ok = datetime.datetime.now()
+ self.last_checked_ok = datetime.datetime.utcnow()
gobject.source_remove(self.stop_initiator_tag)
- self.stop_initiator_tag = gobject.timeout_add\
- (self._timeout_milliseconds, self.stop)
- # D-Bus variant
- bumpTimeout = dbus.service.method(interface)(bump_timeout)
+ self.stop_initiator_tag = (gobject.timeout_add
+ (self._timeout_milliseconds,
+ self.stop))
def start_checker(self):
"""Start a new checker subprocess if one is not running.
@@ -433,9 +380,9 @@
self.checker = subprocess.Popen(command,
close_fds=True,
shell=True, cwd="/")
- self.checker_callback_tag = gobject.child_watch_add\
- (self.checker.pid,
- self.checker_callback)
+ self.checker_callback_tag = (gobject.child_watch_add
+ (self.checker.pid,
+ self.checker_callback))
# Emit D-Bus signal
self.CheckerStarted(command)
except OSError, error:
@@ -444,15 +391,6 @@
# Re-run this periodically if run by gobject.timeout_add
return True
- @dbus.service.signal(interface, signature="s")
- def CheckerStarted(self, command):
- pass
-
- @dbus.service.method(interface, out_signature="b")
- def checkerIsRunning(self):
- "D-Bus getter method"
- return self.checker is not None
-
def stop_checker(self):
"""Force the checker process, if any, to stop."""
if self.checker_callback_tag:
@@ -470,36 +408,183 @@
if error.errno != errno.ESRCH: # No such process
raise
self.checker = None
- # D-Bus variant
- StopChecker = dbus.service.method(interface)(stop_checker)
def still_valid(self):
"""Has the timeout not yet passed for this client?"""
if not self.started:
return False
- now = datetime.datetime.now()
+ now = datetime.datetime.utcnow()
if self.last_checked_ok is None:
return now < (self.created + self.timeout)
else:
return now < (self.last_checked_ok + self.timeout)
- # D-Bus variant
- stillValid = dbus.service.method(interface, out_signature="b")\
- (still_valid)
-
- del interface
+
+ ## D-Bus methods & signals
+ _interface = u"org.mandos_system.Mandos.Client"
+
+ def _datetime_to_dbus_struct(dt):
+ return dbus.Struct(dt.year, dt.month, dt.day, dt.hour,
+ dt.minute, dt.second, dt.microsecond,
+ signature="nyyyyyu")
+
+ # BumpTimeout - method
+ BumpTimeout = dbus.service.method(_interface)(bump_timeout)
+ BumpTimeout.__name__ = "BumpTimeout"
+
+ # IntervalChanged - signal
+ @dbus.service.signal(_interface, signature="t")
+ def IntervalChanged(self, t):
+ "D-Bus signal"
+ pass
+
+ # CheckerCompleted - signal
+ @dbus.service.signal(_interface, signature="b")
+ def CheckerCompleted(self, success):
+ "D-Bus signal"
+ pass
+
+ # CheckerIsRunning - method
+ @dbus.service.method(_interface, out_signature="b")
+ def CheckerIsRunning(self):
+ "D-Bus getter method"
+ return self.checker is not None
+
+ # CheckerStarted - signal
+ @dbus.service.signal(_interface, signature="s")
+ def CheckerStarted(self, command):
+ "D-Bus signal"
+ pass
+
+ # GetChecker - method
+ @dbus.service.method(_interface, out_signature="s")
+ def GetChecker(self):
+ "D-Bus getter method"
+ return self.checker_command
+
+ # GetCreated - method
+ @dbus.service.method(_interface, out_signature="(nyyyyyu)")
+ def GetCreated(self):
+ "D-Bus getter method"
+ return datetime_to_dbus_struct(self.created)
+
+ # GetFingerprint - method
+ @dbus.service.method(_interface, out_signature="s")
+ def GetFingerprint(self):
+ "D-Bus getter method"
+ return self.fingerprint
+
+ # GetHost - method
+ @dbus.service.method(_interface, out_signature="s")
+ def GetHost(self):
+ "D-Bus getter method"
+ return self.host
+
+ # GetInterval - method
+ @dbus.service.method(_interface, out_signature="t")
+ def GetInterval(self):
+ "D-Bus getter method"
+ return self._interval_milliseconds
+
+ # GetName - method
+ @dbus.service.method(_interface, out_signature="s")
+ def GetName(self):
+ "D-Bus getter method"
+ return self.name
+
+ # GetStarted - method
+ @dbus.service.method(_interface, out_signature="(nyyyyyu)")
+ def GetStarted(self):
+ "D-Bus getter method"
+ if self.started is not None:
+ return datetime_to_dbus_struct(self.started)
+ else:
+ return dbus.Struct(0, 0, 0, 0, 0, 0, 0,
+ signature="nyyyyyu")
+
+ # GetTimeout - method
+ @dbus.service.method(_interface, out_signature="t")
+ def GetTimeout(self):
+ "D-Bus getter method"
+ return self._timeout_milliseconds
+
+ # SetChecker - method
+ @dbus.service.method(_interface, in_signature="s")
+ def SetChecker(self, checker):
+ "D-Bus setter method"
+ self.checker_command = checker
+
+ # SetHost - method
+ @dbus.service.method(_interface, in_signature="s")
+ def SetHost(self, host):
+ "D-Bus setter method"
+ self.host = host
+
+ # SetInterval - method
+ @dbus.service.method(_interface, in_signature="t")
+ def SetInterval(self, milliseconds):
+ self.interval = datetime.timdeelta(0, 0, 0, milliseconds)
+
+ # SetTimeout - method
+ @dbus.service.method(_interface, in_signature="t")
+ def SetTimeout(self, milliseconds):
+ self.timeout = datetime.timedelta(0, 0, 0, milliseconds)
+
+ # SetSecret - method
+ @dbus.service.method(_interface, in_signature="ay",
+ byte_arrays=True)
+ def SetSecret(self, secret):
+ "D-Bus setter method"
+ self.secret = str(secret)
+
+ # Start - method
+ Start = dbus.service.method(_interface)(start)
+ Start.__name__ = "Start"
+
+ # StartChecker - method
+ StartChecker = dbus.service.method(_interface)(start_checker)
+ StartChecker.__name__ = "StartChecker"
+
+ # StateChanged - signal
+ @dbus.service.signal(_interface, signature="b")
+ def StateChanged(self, started):
+ "D-Bus signal"
+ pass
+
+ # StillValid - method
+ StillValid = (dbus.service.method(_interface, out_signature="b")
+ (still_valid))
+ StillValid.__name__ = "StillValid"
+
+ # Stop - method
+ Stop = dbus.service.method(_interface)(stop)
+ Stop.__name__ = "Stop"
+
+ # StopChecker - method
+ StopChecker = dbus.service.method(_interface)(stop_checker)
+ StopChecker.__name__ = "StopChecker"
+
+ # TimeoutChanged - signal
+ @dbus.service.signal(_interface, signature="t")
+ def TimeoutChanged(self, t):
+ "D-Bus signal"
+ pass
+
+ del _datetime_to_dbus_struct
+ del _interface
def peer_certificate(session):
"Return the peer's OpenPGP certificate as a bytestring"
# If not an OpenPGP certificate...
- if gnutls.library.functions.gnutls_certificate_type_get\
- (session._c_object) \
- != gnutls.library.constants.GNUTLS_CRT_OPENPGP:
+ if (gnutls.library.functions
+ .gnutls_certificate_type_get(session._c_object)
+ != gnutls.library.constants.GNUTLS_CRT_OPENPGP):
# ...do the normal thing
return session.peer_certificate
list_size = ctypes.c_uint()
- cert_list = gnutls.library.functions.gnutls_certificate_get_peers\
- (session._c_object, ctypes.byref(list_size))
+ cert_list = (gnutls.library.functions
+ .gnutls_certificate_get_peers
+ (session._c_object, ctypes.byref(list_size)))
if list_size.value == 0:
return None
cert = cert_list[0]
@@ -509,22 +594,24 @@
def fingerprint(openpgp):
"Convert an OpenPGP bytestring to a hexdigit fingerprint string"
# New GnuTLS "datum" with the OpenPGP public key
- datum = gnutls.library.types.gnutls_datum_t\
- (ctypes.cast(ctypes.c_char_p(openpgp),
- ctypes.POINTER(ctypes.c_ubyte)),
- ctypes.c_uint(len(openpgp)))
+ datum = (gnutls.library.types
+ .gnutls_datum_t(ctypes.cast(ctypes.c_char_p(openpgp),
+ ctypes.POINTER
+ (ctypes.c_ubyte)),
+ ctypes.c_uint(len(openpgp))))
# New empty GnuTLS certificate
crt = gnutls.library.types.gnutls_openpgp_crt_t()
- gnutls.library.functions.gnutls_openpgp_crt_init\
- (ctypes.byref(crt))
+ (gnutls.library.functions
+ .gnutls_openpgp_crt_init(ctypes.byref(crt)))
# Import the OpenPGP public key into the certificate
- gnutls.library.functions.gnutls_openpgp_crt_import\
- (crt, ctypes.byref(datum),
- gnutls.library.constants.GNUTLS_OPENPGP_FMT_RAW)
+ (gnutls.library.functions
+ .gnutls_openpgp_crt_import(crt, ctypes.byref(datum),
+ gnutls.library.constants
+ .GNUTLS_OPENPGP_FMT_RAW))
# Verify the self signature in the key
crtverify = ctypes.c_uint()
- gnutls.library.functions.gnutls_openpgp_crt_verify_self\
- (crt, 0, ctypes.byref(crtverify))
+ (gnutls.library.functions
+ .gnutls_openpgp_crt_verify_self(crt, 0, ctypes.byref(crtverify)))
if crtverify.value != 0:
gnutls.library.functions.gnutls_openpgp_crt_deinit(crt)
raise gnutls.errors.CertificateSecurityError("Verify failed")
@@ -532,8 +619,9 @@
buf = ctypes.create_string_buffer(20)
buf_len = ctypes.c_size_t()
# Get the fingerprint from the certificate into the buffer
- gnutls.library.functions.gnutls_openpgp_crt_get_fingerprint\
- (crt, ctypes.byref(buf), ctypes.byref(buf_len))
+ (gnutls.library.functions
+ .gnutls_openpgp_crt_get_fingerprint(crt, ctypes.byref(buf),
+ ctypes.byref(buf_len)))
# Deinit the certificate
gnutls.library.functions.gnutls_openpgp_crt_deinit(crt)
# Convert the buffer to a Python bytestring
@@ -551,8 +639,10 @@
def handle(self):
logger.info(u"TCP connection from: %s",
unicode(self.client_address))
- session = gnutls.connection.ClientSession\
- (self.request, gnutls.connection.X509Credentials())
+ session = (gnutls.connection
+ .ClientSession(self.request,
+ gnutls.connection
+ .X509Credentials()))
line = self.request.makefile().readline()
logger.debug(u"Protocol version: %r", line)
@@ -573,8 +663,9 @@
# "+DHE-DSS"))
# Use a fallback default, since this MUST be set.
priority = self.server.settings.get("priority", "NORMAL")
- gnutls.library.functions.gnutls_priority_set_direct\
- (session._c_object, priority, None)
+ (gnutls.library.functions
+ .gnutls_priority_set_direct(session._c_object,
+ priority, None))
try:
session.handshake()
@@ -590,12 +681,11 @@
session.bye()
return
logger.debug(u"Fingerprint: %s", fpr)
- client = None
for c in self.server.clients:
if c.fingerprint == fpr:
client = c
break
- if not client:
+ else:
logger.warning(u"Client not found for fingerprint: %s",
fpr)
session.bye()
@@ -746,8 +836,9 @@
"""Call the C function if_nametoindex(), or equivalent"""
global if_nametoindex
try:
- if_nametoindex = ctypes.cdll.LoadLibrary\
- (ctypes.util.find_library("c")).if_nametoindex
+ if_nametoindex = (ctypes.cdll.LoadLibrary
+ (ctypes.util.find_library("c"))
+ .if_nametoindex)
except (OSError, AttributeError):
if "struct" not in sys.modules:
import struct
@@ -832,8 +923,8 @@
# Convert the SafeConfigParser object to a dict
server_settings = server_config.defaults()
# Use getboolean on the boolean config option
- server_settings["debug"] = server_config.getboolean\
- ("DEFAULT", "debug")
+ server_settings["debug"] = (server_config.getboolean
+ ("DEFAULT", "debug"))
del server_config
# Override the settings from the config file with command line
@@ -853,7 +944,7 @@
console.setLevel(logging.WARNING)
if server_settings["servicename"] != "Mandos":
- syslogger.setFormatter(logging.Formatter\
+ syslogger.setFormatter(logging.Formatter
('Mandos (%s): %%(levelname)s:'
' %%(message)s'
% server_settings["servicename"]))
@@ -907,8 +998,8 @@
service = AvahiService(name = server_settings["servicename"],
servicetype = "_mandos._tcp", )
if server_settings["interface"]:
- service.interface = if_nametoindex\
- (server_settings["interface"])
+ service.interface = (if_nametoindex
+ (server_settings["interface"]))
global main_loop
global bus
@@ -921,6 +1012,7 @@
avahi.DBUS_PATH_SERVER),
avahi.DBUS_INTERFACE_SERVER)
# End of Avahi example code
+ bus_name = dbus.service.BusName(u"org.mandos-system.Mandos", bus)
def remove_from_clients(client):
clients.remove(client)
@@ -1008,8 +1100,8 @@
gobject.io_add_watch(tcp_server.fileno(), gobject.IO_IN,
lambda *args, **kwargs:
- tcp_server.handle_request\
- (*args[2:], **kwargs) or True)
+ (tcp_server.handle_request
+ (*args[2:], **kwargs) or True))
logger.debug(u"Starting main loop")
main_loop.run()
=== modified file 'mandos-keygen'
--- mandos-keygen 2008-10-17 18:56:25 +0000
+++ mandos-keygen 2008-11-11 16:07:18 +0000
@@ -2,7 +2,8 @@
#
# Mandos key generator - create a new OpenPGP key for a Mandos client
#
-# Copyright © 2008 Teddy Hogeborn & Björn Påhlsson
+# Copyright © 2008 Teddy Hogeborn
+# Copyright © 2008 Björn Påhlsson
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
=== modified file 'plugin-runner.c'
--- plugin-runner.c 2008-11-01 02:26:00 +0000
+++ plugin-runner.c 2008-11-11 16:07:18 +0000
@@ -2,7 +2,8 @@
/*
* Mandos plugin runner - Run Mandos plugins
*
- * Copyright © 2008 Teddy Hogeborn & Björn Påhlsson
+ * Copyright © 2008 Teddy Hogeborn
+ * Copyright © 2008 Björn Påhlsson
*
* This program is free software: you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
=== modified file 'plugins.d/askpass-fifo.c'
--- plugins.d/askpass-fifo.c 2008-09-26 19:47:21 +0000
+++ plugins.d/askpass-fifo.c 2008-11-11 16:07:18 +0000
@@ -1,3 +1,28 @@
+/* -*- coding: utf-8 -*- */
+/*
+ * Passprompt - Read a password from a FIFO and output it
+ *
+ * Copyright © 2008 Teddy Hogeborn
+ * Copyright © 2008 Björn Påhlsson
+ *
+ * This program is free software: you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see
+ * .
+ *
+ * Contact the authors at and
+ * .
+ */
+
#define _GNU_SOURCE /* TEMP_FAILURE_RETRY() */
#include /* ssize_t */
#include /* mkfifo(), S_IRUSR, S_IWUSR */
=== modified file 'plugins.d/mandos-client.c'
--- plugins.d/mandos-client.c 2008-09-30 07:23:39 +0000
+++ plugins.d/mandos-client.c 2008-11-11 16:07:18 +0000
@@ -9,7 +9,8 @@
* "browse_callback", and parts of "main".
*
* Everything else is
- * Copyright © 2008 Teddy Hogeborn & Björn Påhlsson
+ * Copyright © 2008 Teddy Hogeborn
+ * Copyright © 2008 Björn Påhlsson
*
* This program is free software: you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
=== modified file 'plugins.d/password-prompt.c'
--- plugins.d/password-prompt.c 2008-09-30 07:23:39 +0000
+++ plugins.d/password-prompt.c 2008-11-11 16:07:18 +0000
@@ -1,8 +1,9 @@
/* -*- coding: utf-8 -*- */
/*
* Passprompt - Read a password from the terminal and print it
- *
- * Copyright © 2008 Teddy Hogeborn & Björn Påhlsson
+ *
+ * Copyright © 2008 Teddy Hogeborn
+ * Copyright © 2008 Björn Påhlsson
*
* This program is free software: you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
=== modified file 'plugins.d/splashy.c'
--- plugins.d/splashy.c 2008-10-03 09:32:30 +0000
+++ plugins.d/splashy.c 2008-11-11 16:07:18 +0000
@@ -1,3 +1,28 @@
+/* -*- coding: utf-8 -*- */
+/*
+ * Passprompt - Read a password from splashy and output it
+ *
+ * Copyright © 2008 Teddy Hogeborn
+ * Copyright © 2008 Björn Påhlsson
+ *
+ * This program is free software: you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see
+ * .
+ *
+ * Contact the authors at and
+ * .
+ */
+
#define _GNU_SOURCE /* asprintf() */
#include /* sig_atomic_t, struct sigaction,
sigemptyset(), sigaddset(), SIGINT,
=== modified file 'plugins.d/usplash.c'
--- plugins.d/usplash.c 2008-10-03 09:32:30 +0000
+++ plugins.d/usplash.c 2008-11-11 16:07:18 +0000
@@ -1,3 +1,28 @@
+/* -*- coding: utf-8 -*- */
+/*
+ * Passprompt - Read a password from usplash and output it
+ *
+ * Copyright © 2008 Teddy Hogeborn
+ * Copyright © 2008 Björn Påhlsson
+ *
+ * This program is free software: you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see
+ * .
+ *
+ * Contact the authors at and
+ * .
+ */
+
#define _GNU_SOURCE /* asprintf() */
#include /* sig_atomic_t, struct sigaction,
sigemptyset(), sigaddset(), SIGINT,