[CentOS] SSH AllowUser WildCard

Mon Feb 7 08:06:11 UTC 2011
Stephen Cox <stephencoxmail at gmail.com>

Ned, thanks but I also can read the man page.

My question is what would an entry be if the user bob can login from
17363.myhost.com and 2373.myhost.com?

Stephen

On Mon, Feb 7, 2011 at 8:49 AM, Ned Slider <ned at unixmail.co.uk> wrote:
> On 07/02/11 06:08, Stephen Cox wrote:
>> Is it possible to allow a user to login from an changing hostname like:
>>
>> username@*hoststringfixed.com
>>
>
> man sshd_config
>
> AllowUsers
> This keyword can be followed by a list of user name patterns, separated
> by spaces. If specified, login is allowed only for user names that match
> one of the patterns. `*' and `?' can be used as wildcards in the
> patterns. Only user names are valid; a numerical user ID is not
> recognized. By default, login is allowed for all users. If the pattern
> takes the form USER at HOST then USER and HOST are separately checked,
> restricting logins to particular users from particular hosts.
>
>
> So wild cards can be used although it doesn't specifically state they
> can be used with the HOST part. Try it and see, my guess is it will work.
>
> _______________________________________________
> CentOS mailing list
> CentOS at centos.org
> http://lists.centos.org/mailman/listinfo/centos
>



-- 
Stephen Cox