FS#40841 - [netctl] stores profiles with dashes using \x2d

Attached to Project: Arch Linux
Opened by Grandwizard Xerxes (GWXerxes) - Saturday, 14 June 2014, 15:29 GMT
Last edited by Jouke Witteveen (jouke) - Tuesday, 17 June 2014, 11:53 GMT
Task Type Bug Report
Category Arch Projects
Status Closed
Assigned To Jouke Witteveen (jouke)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Using netctl to start/enable a profile with a (-) dash in filename will result in the hex value (\x2d) for the dash being used in the symlink for the profile.

Additionaly if the profile fails to start, using 'systemctl status netctl@<profile name with \x2d>.service' will fail to provide any information.

Additional info:
* package version(s)
* config and/or log files etc.
netctl :1.7-1
systemd :212-3
Console log of process: http://pastebin.com/1VR5LAqR

Steps to reproduce:
Try and start a profile with dashes in the name
This task depends upon

Closed by  Jouke Witteveen (jouke)
Tuesday, 17 June 2014, 11:53 GMT
Reason for closing:  Not a bug
Comment by Grandwizard Xerxes (GWXerxes) - Saturday, 14 June 2014, 15:40 GMT
I linked to the wrong pastebin, this is the correct version without a typo http://pastebin.com/aiMZfqbR
Comment by Jouke Witteveen (jouke) - Tuesday, 17 June 2014, 11:53 GMT
In this case escaping is done correctly by netctl and incorrectly by the user. The user should have used either `netctl status staff-it`, or properly escape the backslash using for example `systemctl status 'netctl@staff\x2dit.service'` or `systemctl status netctl@staff\\x2dit.service`.

Dashes are converted to forward slashes by systemd and therefore need to be escaped by netctl. All of this is as intended by the developers.

Loading...