title: How Do I Connect to a Redis Sentinel that requirespass with ServiceStack.Redis?
body: <p>I have a simple redis cluster on my local machine that consists of:</p>
  
  <ul>
  <li>master on port 3679</li>
  <li>slave on port 6380</li>
  <li>sentinel on port 26379</li>
  </ul>
  
  <p>I am using <strong>ServiceStack.Redis</strong> to connect with no problems so far. Today I added a password to each of them using the <code>requirepass 42</code> setting. I can connect to all of them using Redis Desktop Manager fine and everything works as expected.</p>
  
  <p>Using the following code, I get an error when I attempt to connect. Removing the password works as expected.</p>
  
  <pre><code>var config = RedisConfiguration.Instance;
  
  Func&lt;string, string&gt; hostFilter = host =&gt; string.IsNullOrEmpty(config.SecurityKey)
                                      ? $"{host}?db={config.Database}"
                                      : $"{config.SecurityKey}@{host}?db={config.Database}";
  
  
  var sentinelHosts = config.SentinelHosts.Select(hostFilter);
  var sentinel = new RedisSentinel(sentinelHosts, config.ServiceName)
  {
      HostFilter = hostFilter,
      RedisManagerFactory = (master, slaves) =&gt; new RedisManagerPool(master)
  };
  
  sentinel.OnFailover += manager =&gt; Logger?.Warn($"Redis fail over to {sentinel.GetMaster()}");
  
  sentinel.Start()
  </code></pre>
  
  <p>This code throw a RedisException <strong>"No Redis Sentinels were available"</strong> with an inner exception of <strong>"unknown command 'AUTH'"</strong>.</p>
  
  <p>I am not clear if I am using the ServiceStack.Redis library improperly or my Redis cluster configuration is incorrect.</p>
  
  <p>Can some one point me in the right direction?</p>