Ignore:
Timestamp:
Sep 5, 2014, 4:03:00 PM (10 years ago)
Author:
alloc
Message:

fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • binary-improvements/7dtd-server-fixes/src/NetConnections/Servers/Web/Web.cs

    r163 r168  
    11using System;
    22using System.Collections.Generic;
     3using System.IO;
    34using System.Net;
    45using System.Text;
     
    2526
    2627                                _listener.Prefixes.Add (String.Format ("http://*:{0}/", port));
    27                                 //_listener.AuthenticationSchemes = AuthenticationSchemes.Basic;
     28                                if (File.Exists (Application.dataPath + "/../webserver/protect"))
     29                                        _listener.AuthenticationSchemes = AuthenticationSchemes.Basic;
    2830                                _listener.Start ();
    2931
     
    4345                                );
    4446
    45                                 Log.Out ("Started Webserver on " + port);
     47                                Log.Out ("Started Webserver on " + port + " (authentication " + (_listener.AuthenticationSchemes == AuthenticationSchemes.Basic ? "enabled" : "disabled") + ")");
    4648                        } catch (Exception e) {
    4749                                Log.Out ("Error in Web.ctor: " + e);
Note: See TracChangeset for help on using the changeset viewer.