{"action":"created","issue":{"url":"https://api.github.com/repos/aspnet/IISIntegration/issues/278","repository_url":"https://api.github.com/repos/aspnet/IISIntegration","labels_url":"https://api.github.com/repos/aspnet/IISIntegration/issues/278/labels{/name}","comments_url":"https://api.github.com/repos/aspnet/IISIntegration/issues/278/comments","events_url":"https://api.github.com/repos/aspnet/IISIntegration/issues/278/events","html_url":"https://github.com/aspnet/IISIntegration/issues/278","id":180938824,"number":278,"title":"User.Identity.Name is null","user":{"login":"danjford","id":7963046,"avatar_url":"https://avatars.githubusercontent.com/u/7963046?v=3","gravatar_id":"","url":"https://api.github.com/users/danjford","html_url":"https://github.com/danjford","followers_url":"https://api.github.com/users/danjford/followers","following_url":"https://api.github.com/users/danjford/following{/other_user}","gists_url":"https://api.github.com/users/danjford/gists{/gist_id}","starred_url":"https://api.github.com/users/danjford/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danjford/subscriptions","organizations_url":"https://api.github.com/users/danjford/orgs","repos_url":"https://api.github.com/users/danjford/repos","events_url":"https://api.github.com/users/danjford/events{/privacy}","received_events_url":"https://api.github.com/users/danjford/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/aspnet/IISIntegration/labels/invalid","name":"invalid","color":"e6e6e6"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-10-04T16:15:23Z","updated_at":"2016-10-04T17:29:33Z","closed_at":null,"body":"Hi,\r\n\r\nWhen running my application in Visual Studio 2015, I can access my User's Name by using User.Identity.Name.\r\n\r\nHowever, when I publish my application using `dotnet publish -c release` and run the resulting `.exe` from the publish folder, my application loads but `User.Identity.Name` is null which causes issues in parts of the system.\r\n\r\nOn publish my project has the same config as [aspnet/JavascriptServices](https://github.com/aspnet/JavaScriptServices/tree/dev/templates/Angular2Spa) i.e. \r\n\r\n```\r\n  \"scripts\": {\r\n    \"prepublish\": [\r\n      \"npm install\",\r\n      \"node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js --env.prod\",\r\n      \"node node_modules/webpack/bin/webpack.js --env.prod\"\r\n    ],\r\n    \"postpublish\": [ \"dotnet publish-iis --publish-folder %publish:OutputPath% --framework %publish:FullTargetFramework%\" ]\r\n  },\r\n```\r\n\r\nThe `windowsAuthentication` and `anonymousAuthentication` properties are configured in `launchSettings.json` i.e. \r\n\r\n```\r\n{\r\n  \"iisSettings\": {\r\n      \"windowsAuthentication\": true,\r\n      \"anonymousAuthentication\": false\r\n   }\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/aspnet/IISIntegration/issues/comments/251455980","html_url":"https://github.com/aspnet/IISIntegration/issues/278#issuecomment-251455980","issue_url":"https://api.github.com/repos/aspnet/IISIntegration/issues/278","id":251455980,"user":{"login":"Tratcher","id":1821173,"avatar_url":"https://avatars.githubusercontent.com/u/1821173?v=3","gravatar_id":"","url":"https://api.github.com/users/Tratcher","html_url":"https://github.com/Tratcher","followers_url":"https://api.github.com/users/Tratcher/followers","following_url":"https://api.github.com/users/Tratcher/following{/other_user}","gists_url":"https://api.github.com/users/Tratcher/gists{/gist_id}","starred_url":"https://api.github.com/users/Tratcher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Tratcher/subscriptions","organizations_url":"https://api.github.com/users/Tratcher/orgs","repos_url":"https://api.github.com/users/Tratcher/repos","events_url":"https://api.github.com/users/Tratcher/events{/privacy}","received_events_url":"https://api.github.com/users/Tratcher/received_events","type":"User","site_admin":false},"created_at":"2016-10-04T17:29:33Z","updated_at":"2016-10-04T17:29:33Z","body":"Make sure `forwardWindowsAuthToken=\"false\"` is enabled in the web.config\r\nhttps://github.com/aspnet/JavaScriptServices/blob/dev/templates/Angular2Spa/web.config#L12"}}
{"actor":{"display_login":"Tratcher"}}