From: Nathaniel Chen Date: Tue, 5 Mar 2013 19:46:34 +0000 (-0800) Subject: hostnamed: allow more special characters in pretty hostname X-Git-Tag: v198~68 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=commitdiff_plain;h=ebe5d6d0d05d1f17c96315c42f8d9bcf5e13ba9d;hp=ebe5d6d0d05d1f17c96315c42f8d9bcf5e13ba9d hostnamed: allow more special characters in pretty hostname this addresses the bug at: https://bugs.freedesktop.org/show_bug.cgi?id=59311 https://bugzilla.redhat.com/show_bug.cgi?id=895299 hostnamectl is supposed to allow a range of special characters for the 'pretty' hostname: $ hostnamectl set-hostname --pretty "Nathaniels Desktop !@#$%" ..however, it rejects apostrophes, double quotes, and backslashes. The manual for hostnamectl suggests that this should be allowed. It makes sense to reject \0, \n, etc. pretty_string_is_safe() is the same as string_is_safe(), but allows more special characters. ---