Change an entry in a config file using sed in bash.
sed -r '/PasswordAuthentication/ s/^#/ /; s/(PasswordAuthentication ).*$/\1 no/' ssh_config
^ pattern to match ^remove ^ change value
comment