Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/CZEMacLeod/WebAPI2-Owin
Example MSBuild.SDK.SystemWeb project for WebAPI2 hosted with Owin.
https://github.com/CZEMacLeod/WebAPI2-Owin
Last synced: about 2 months ago
JSON representation
Example MSBuild.SDK.SystemWeb project for WebAPI2 hosted with Owin.
- Host: GitHub
- URL: https://github.com/CZEMacLeod/WebAPI2-Owin
- Owner: CZEMacLeod
- License: mit
- Created: 2022-06-18T22:51:56.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-06-18T23:00:56.000Z (over 2 years ago)
- Last Synced: 2024-06-28T05:38:16.877Z (3 months ago)
- Language: JavaScript
- Size: 544 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# WebAPI2 Owin
Example project using [MSBuild.SDK.SystemWeb](https://github.com/CZEMacLeod/MSBuild.SDK.SystemWeb) to show WebAPI2 with Owin.
This is based on an Empty template from the SDK.
The Values controller was added from an example ASP.Net4 project.
Owin was added using with it set to host on SystemWeb - `Microsoft.Owin.Host.SystemWeb`
WebAPI2 was added to host in Owin - `Microsoft.AspNet.WebApi.Owin`.
Newtonsoft.Json was directly added to the project to ensure the newest version.
The latest release version of `Microsoft.Net.Compilers.Toolset` was selected by adding the
```xml
4.2.0
```
line to the project file.The web.config was set to automatically add binding redirects (required for `Microsoft.Owin` and `Newtonsoft.Json`) by adding the
```xml
Overwrite
```
line to the project file.The values controller was tweaked to show the identity of the accessing user using Owin Authentication.
The `launchSettings.json` file was tweaked to:
- Run in 64bit mode
- Launch the api/values url to hit the controller's get method.
- Enable windows authentication to use the logged in user to show in the values controller.