/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 Makefile

  • Committer: Teddy Hogeborn
  • Date: 2014-06-14 23:43:07 UTC
  • Revision ID: teddy@recompile.se-20140614234307-i0mh9r2n4orkqtki
plugin-runner: Release memory and close FD's correctly in all cases.

* plugins.d/mandos-client.c (main): Init "direntries" to NULL.  Close
                                    "dir_fd" at fallback label.  Do
                                    not free "direntries" if
                                    scandirat() or scandir() failed.
                                    Do free(direntries) at fallback
                                    label.

Show diffs side-by-side

added added

removed removed

Lines of Context:
264
264
        @echo "# ignored.  The messages are caused by not running as root, but   #"
265
265
        @echo "# you should NOT run \"make run-client\" as root unless you also    #"
266
266
        @echo "# unpacked and compiled Mandos as root, which is NOT recommended. #"
267
 
        @echo "# From plugin-runner: setgid: Operation not permitted             #"
268
 
        @echo "#                     setuid: Operation not permitted             #"
 
267
        @echo "# From plugin-runner: setuid: Operation not permitted             #"
269
268
        @echo "# From askpass-fifo:  mkfifo: Permission denied                   #"
270
 
        @echo "# From mandos-client:                                             #"
271
 
        @echo "#             Failed to raise privileges: Operation not permitted #"
272
 
        @echo "#             Warning: network hook \"*\" exited with status *      #"
 
269
        @echo "# From mandos-client: setuid: Operation not permitted             #"
 
270
        @echo "#                     seteuid: Operation not permitted            #"
 
271
        @echo "#                     klogctl: Operation not permitted            #"
273
272
        @echo "###################################################################"
274
 
# We set GNOME_KEYRING_CONTROL to block pam_gnome_keyring
275
273
        ./plugin-runner --plugin-dir=plugins.d \
276
274
                --config-file=plugin-runner.conf \
277
275
                --options-for=mandos-client:--seckey=keydir/seckey.txt,--pubkey=keydir/pubkey.txt,--network-hook-dir=network-hooks.d \
278
 
                --env-for=mandos-client:GNOME_KEYRING_CONTROL= \
279
276
                $(CLIENTARGS)
280
277
 
281
278
# Used by run-client
296
293
        install --directory confdir
297
294
        install --mode=u=rw $< $@
298
295
# Add a client password
299
 
        ./mandos-keygen --dir keydir --password --no-ssh >> $@
 
296
        ./mandos-keygen --dir keydir --password >> $@
300
297
statedir:
301
298
        install --directory statedir
302
299