Nathanael Demacon
Nathanael Demacon
I didn't know `Include` directives could work inside `Host` directives. sshs is using [sshconfig](https://github.com/mikkeloscar/sshconfig), I implemented it limiting usage inside of `Host` directives (https://github.com/mikkeloscar/sshconfig/blob/9ddb34f89ae36bf3ab5662bcd715458a9c93a16e/parser.go#L149). I'll try to fix this this...
@jarrodCoombes this is the maximum I can do with `known_hosts`, using `sshs generate --known-hosts` it will generate `Host`, `Hostname` and `Port` for each entry. `--known-hosts` is required because I though...
> Are the changes reflected in the pre-build binaries in the releases? Sadly no, you need to build it yourself. But it's just calling `makeˋ.
Did you checkout to branch `feature/generator-known-hosts`?
@jarrodCoombes you can find a built version in the artifacts: https://github.com/quantumsheep/sshs/actions/runs/1828649999
With your example, for instance: ``` [server.domain.tld]:222,[xx.xx.xx.xx]:222 ecdsa-sha2-nistp256 server2.domain.tld,server2,yy.yy.yy.yy ecdsa-sha2-nistp256 ``` It gives this output in the last commit: ```nginx Host server.domain.tld:222 Hostname server.domain.tld Port 222 Host xx.xx.xx.xx:222 Hostname xx.xx.xx.xx...
> I think that leads to quite a bit of redundancy and clutter. But what do you do for this: ``` [server.domain.tld]:222,[xx.xx.xx.xx]:222,[server2.domain.tld]:222 ecdsa-sha2-nistp256 ``` Or even: ``` [server.domain.tld]:222,[xx.xx.xx.xx]:222,[server.domain.tld]:333 ecdsa-sha2-nistp256 ```
Should be better in the last commit (check artifacts at https://github.com/quantumsheep/sshs/actions/runs/1849655613). I added `--known-hosts-allow-single-ip` option to allow lines without a valid domain name.
> I think this: > > ``` > 5.6.7.8:333 ecdsa-sha2-nistp256 > ``` > > Should return > > ``` > Host "5.6.7.8" > Hostname 5.6.7.8 > User > Port 333...
> What about this: > > ``` > Host 5.6.7.8 > Hostname 5.6.7.8 > User > Port 333 > > Host 5.6.7.8 > Hostname 5.6.7.8 > User > Port 222...