@@ -145,19 +145,17 @@ func (o *Options) SetRealClientIPParser(s ipapi.RealClientIPParser) { o.realClie
145// NewOptions constructs a new Options with defaulted values
145// NewOptions constructs a new Options with defaulted values
146func NewOptions() *Options {
146func NewOptions() *Options {
147 return &Options{
147 return &Options{
148− ProxyPrefix: "/oauth2",
148+ ProxyPrefix: "/oauth2",
149− ProviderType: "google",
149+ ProviderType: "google",
150− PingPath: "/ping",
150+ PingPath: "/ping",
151− ProxyWebSockets: true,
151+ ProxyWebSockets: true,
152− HTTPAddress: "127.0.0.1:4180",
152+ HTTPAddress: "127.0.0.1:4180",
153− HTTPSAddress: ":443",
153+ HTTPSAddress: ":443",
154− RealClientIPHeader: "X-Real-IP",
154+ RealClientIPHeader: "X-Real-IP",
155− ForceHTTPS: false,
155+ ForceHTTPS: false,
156− DisplayHtpasswdForm: true,
156+ DisplayHtpasswdForm: true,
157− Cookie: cookieDefaults(),
157+ Cookie: cookieDefaults(),
158− Session: SessionOptions{
158+ Session: sessionOptionsDefaults(),
161 AzureTenant: "common",
159 AzureTenant: "common",
162 SetXAuthRequest: false,
160 SetXAuthRequest: false,
163 SkipAuthPreflight: false,
161 SkipAuthPreflight: false,
@@ -241,6 +239,7 @@ func NewFlagSet() *pflag.FlagSet {
241 flagSet.String("ping-user-agent", "", "special User-Agent that will be used for basic health checks")
239 flagSet.String("ping-user-agent", "", "special User-Agent that will be used for basic health checks")
242 flagSet.Bool("proxy-websockets", true, "enables WebSocket proxying")
240 flagSet.Bool("proxy-websockets", true, "enables WebSocket proxying")
243 flagSet.String("session-store-type", "cookie", "the session storage provider to use")
241 flagSet.String("session-store-type", "cookie", "the session storage provider to use")
242+ flagSet.Bool("session-cookie-minimal", false, "strip OAuth tokens from cookie session stores if they aren't needed (cookie session store only)")
244 flagSet.String("redis-connection-url", "", "URL of redis server for redis session storage (eg: redis://HOST[:PORT])")
243 flagSet.String("redis-connection-url", "", "URL of redis server for redis session storage (eg: redis://HOST[:PORT])")
245 flagSet.Bool("redis-use-sentinel", false, "Connect to redis via sentinels. Must set --redis-sentinel-master-name and --redis-sentinel-connection-urls to use this feature")
244 flagSet.Bool("redis-use-sentinel", false, "Connect to redis via sentinels. Must set --redis-sentinel-master-name and --redis-sentinel-connection-urls to use this feature")
246 flagSet.String("redis-sentinel-master-name", "", "Redis sentinel master name. Used in conjunction with --redis-use-sentinel")
245 flagSet.String("redis-sentinel-master-name", "", "Redis sentinel master name. Used in conjunction with --redis-use-sentinel")