Macos profile in /apple XML is not formatted correctly #139

Closed
opened 2025-12-29 01:23:52 +01:00 by adam · 0 comments
Owner

Originally created by @kyhwana on GitHub (Feb 28, 2022).

Bug description

The MacOS profile has escaped XML in it, eg:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
  <dict>
    <key>PayloadUUID</key>
    <string>redacted</string>
    <key>PayloadDisplayName</key>
    <string>Headscale</string>
    <key>PayloadDescription</key>
    <string>Configure Tailscale login server to: redacted</string>
    <key>PayloadIdentifier</key>
    <string>com.github.juanfont.headscale</string>
    <key>PayloadRemovalDisallowed</key>
    <false/>
    <key>PayloadType</key>
    <string>Configuration</string>
    <key>PayloadVersion</key>
    <integer>1</integer>
    <key>PayloadContent</key>
    <array>
    &lt;dict&gt;
        &lt;key&gt;PayloadType&lt;/key&gt;
        &lt;string&gt;io.tailscale.ipn.macos&lt;/string&gt;
        &lt;key&gt;PayloadUUID&lt;/key&gt;
        &lt;string&gt;redacted&lt;/string&gt;
        &lt;key&gt;PayloadIdentifier&lt;/key&gt;
        &lt;string&gt;com.github.juanfont.headscale&lt;/string&gt;
        &lt;key&gt;PayloadVersion&lt;/key&gt;
        &lt;integer&gt;1&lt;/integer&gt;
        &lt;key&gt;PayloadEnabled&lt;/key&gt;
        &lt;true/&gt;
        &lt;key&gt;ControlURL&lt;/key&gt;
        &lt;string&gt;redacted&lt;/string&gt;
    &lt;/dict&gt;

    </array>
  </dict>
</plist>

To Reproduce

Browse to headscale.url/apple and download the MacOS profile.

Context info

  • Version 0.15-beta1 of headscale

Fix appears to be changing line 5 of apple_mobileconfig.go "html/template" to "text/template"

Originally created by @kyhwana on GitHub (Feb 28, 2022). **Bug description** The MacOS profile has escaped XML in it, eg: ``` &lt;?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>PayloadUUID</key> <string>redacted</string> <key>PayloadDisplayName</key> <string>Headscale</string> <key>PayloadDescription</key> <string>Configure Tailscale login server to: redacted</string> <key>PayloadIdentifier</key> <string>com.github.juanfont.headscale</string> <key>PayloadRemovalDisallowed</key> <false/> <key>PayloadType</key> <string>Configuration</string> <key>PayloadVersion</key> <integer>1</integer> <key>PayloadContent</key> <array> &lt;dict&gt; &lt;key&gt;PayloadType&lt;/key&gt; &lt;string&gt;io.tailscale.ipn.macos&lt;/string&gt; &lt;key&gt;PayloadUUID&lt;/key&gt; &lt;string&gt;redacted&lt;/string&gt; &lt;key&gt;PayloadIdentifier&lt;/key&gt; &lt;string&gt;com.github.juanfont.headscale&lt;/string&gt; &lt;key&gt;PayloadVersion&lt;/key&gt; &lt;integer&gt;1&lt;/integer&gt; &lt;key&gt;PayloadEnabled&lt;/key&gt; &lt;true/&gt; &lt;key&gt;ControlURL&lt;/key&gt; &lt;string&gt;redacted&lt;/string&gt; &lt;/dict&gt; </array> </dict> </plist> ``` **To Reproduce** Browse to headscale.url/apple and download the MacOS profile. **Context info** - Version 0.15-beta1 of headscale Fix appears to be changing line 5 of apple_mobileconfig.go `"html/template"` to `"text/template"`
adam added the bug label 2025-12-29 01:23:52 +01:00
adam closed this issue 2025-12-29 01:23:52 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/headscale#139