SSH Avahi Service

  • Download

Uploaded on Mon 16th June, 2008 at 22:54 by Phill Sparks

Description

If you're running Avahi in linux you can place this in your /etc/avahi/services/ directory and rename to sshd.service to broadcast that you are SSH capable.

Code

  1. <?xml version="1.0" standalone='no'?>
  2. <!DOCTYPE service-group SYSTEM "avahi-service.dtd">
  3. <service-group>
  4.         <name>My Server</name>
  5.         <service>
  6.                 <type>_ssh._tcp</type>
  7.                 <port>22</port>
  8.         </service>
  9.     <service>
  10.         <type>_fish._tcp</type>
  11.         <port>22</port>
  12.     </service>
  13.     <service>
  14.         <type>_scp._tcp</type>
  15.         <port>22</port>
  16.     </service>
  17. </service-group>

Comments

  1. David Edmundson David Edmundson wrote:

    Rather than making the user replace the hostname it can be done automatically.

    1. <service-group>
    2.   <name replace-wildcards="yes">SSH on %h</name>
    3.   <service>
    4.     <type>_ssh._tcp</type>
    5.     <port>22</port>
    6.   </service>
    7. </service-group>

    It'd be nice if someone modded sshd to make it report itself automatically, along with Apache,VNC and all the other network services.

    Sat 27th September, 2008

  2. Phill Sparks Phill Sparks wrote:

    Ah neat trick! Are there any other % vars that you have come across? I prefer nice names rather than hostnames when I browse bonjour. Some services are bonjour aware, maybe we should look at how to go about patching each?

    Sun 28th September, 2008

You need to login before you can leave a comment. If you do not have an account you can register for free.