I'm using spring-security-oauth2
authorization server. I'm using the password grant for oauth authentication. Currently, this lets users send username and password as query parameters. This is not safe since the password is not protected by HTTP. To handle this, my frontend sends the important information as part of the request body through HTTPS.
We use springfox-swagger2
to generate API specifications. Since query parameters are permitted, the specification generates these fields as required, as you can see in this
The specification also takes in an optional body:
I'm wondering what workaround there might be to solve this issue because we are automatically generating typescript models based off the swagger specification and every time we make any changes on our specification, any manual frontend changes of the types will be replaced.