summaryrefslogtreecommitdiff
path: root/src/services/vyos-http-api-server
AgeCommit message (Collapse)Author
2024-09-20http-api: T6326: return full warning/error output through apiJohn Estabrook
Configuration error output is not returned in full to the http-api when running under vyos-configd, due to an early implementation 'workaround' of vyos-configd writing directly to the session tty. This is corrected to return all ambient stdout (notably vyos.base.Warning) and error messages directly to the originating caller, which may be from a session tty or a ConfigSession instance. As the http-api runs in the latter case, the full output is returned.
2024-08-13T5743: HTTPS API ability to import PKI certificatesNataliia Solomko
2024-05-27T5786: Add set/show system image to /image endpointkhramshinr
2024-03-28config-sync: T6185: combine data for sections/configs in one commandJohn Estabrook
Package path/section data in single command containing a tree (dict) of section paths and the accompanying config data. This drops the call to get_config_dict and the need for a list of commands in request.
2024-03-22config-sync: T6145: batch section requests for commit by priorityJohn Estabrook
2024-03-05http-api: T6069: fix allocation outside of thread lockJohn Estabrook
2024-01-09https: T5902: remove virtual-host configurationChristian Breunig
We have not seen the adoption of the https virtual-host CLI option. What it did? * Create multiple webservers each listening on a different IP/port (but in the same VRF) * All webservers shared one common document root * All webservers shared the same SSL certificates * All webservers could have had individual allow-client configurations * API could be enabled for a particular virtual-host but was always enabled on the default host This configuration tried to provide a full webserver via the CLI but VyOS is a router and the Webserver is there for an API or to serve files for a local-ui. Changes Remove support for virtual-hosts as it's an incomplete and thus mostly useless "thing". Migrate all allow-client statements to one top-level allow statement.
2023-12-20https api: T5844: allow the server to start without API keysDaniil Baturin
and use only PAM auth and JWT
2023-11-26http-api: T5782: use single config-mode script for https and http-apiJohn Estabrook
2023-11-22http-api: T5768: remove auxiliary http-api.confJohn Estabrook
2023-11-21T5767: HTTPS API add reboot and poweroff endpointsViacheslav Hletenko
Add ability to reboot and poweroff the system via API curl -k --location --request POST 'https://vyos/reboot' \ --form data='{"op": "reboot", "path": ["now"]}' \ --form key='apikey' curl -k --location --request POST 'https://vyos/poweroff' \ --form data='{"op": "poweroff", "path": ["now"]}' \ --form key='apikey'
2023-11-20http: T5762: api: make API socket backend communication the one and only defaultChristian Breunig
Why: Smoketests fail as they can not establish IPv6 connection to uvicorn backend server. https://github.com/vyos/vyos-1x/pull/2481 added a bunch of new smoketests. While debugging those failing, it was uncovered, that uvicorn only listens on IPv4 connections vyos@vyos# netstat -tulnp | grep 8080 (Not all processes could be identified, non-owned process info will not be shown, you would have to be root to see it all.) tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN - As the CLI already has an option to move the API communication from an IP to a UNIX domain socket, the best idea is to make this the default way of communication, as we never directly talk to the API server but rather use the NGINX reverse proxy.
2023-10-09http-api: T2612: reload server within configsession for api self-configJohn Estabrook
2023-10-09http-api: T2612: send response before reconfiguring api serverJohn Estabrook
2023-06-20http-api: T5305: configure operations should not be defined asyncJohn Estabrook
2023-06-10http-api: T5248: add endpoint /configure-sectionJohn Estabrook
2023-06-10http-api: T5263: add base model for generalizationJohn Estabrook
2023-06-10http-api: T5263: factor out function _configure_op for generalizationJohn Estabrook
2023-06-10http-api: T5263: consistent string formattingJohn Estabrook
2023-06-10http-api: T5263: simplify form errorsJohn Estabrook
2023-06-10http-api: T5263: path validator should provide messageJohn Estabrook
2023-04-23http-api: T5175: check value of attribute for FastAPI>=0.91.0John Estabrook
FastAPI v0.92.0 (starlette v0.24.0) sets default attribute Request._form; check for value == None instead of existence when overriding Request class.
2023-02-14http-api: T5006: add explicit async to retrieve/configure methodsJohn Estabrook
2023-01-09container: T4880: add REST API endpoint for add/delelete/show imagesJohn Estabrook
2022-11-06graphql: T4803: allow 'Authorization' header in CORS middlewareJohn Estabrook
2022-10-25graphql: T4574: set byte length of shared secret from CLIJohn Estabrook
2022-10-25graphql: T4574: set token expiration time in claimsJohn Estabrook
2022-10-25graphql: T4574: add context to read token in queries/mutationsJohn Estabrook
2022-10-25graphql: T4574: read config and generate schema with/without key authJohn Estabrook
2022-10-21graphql: T4768: change name of api child node from 'gql' to 'graphql'John Estabrook
2022-10-14http-api: T4749: transition to config_dictJohn Estabrook
2022-08-22graphql: T3993: add missing sys.exit()John Estabrook
2022-07-24graphql: T3993: disable introspection unless set in CLIJohn Estabrook
2022-05-26http-api: T4442: Add action resetViacheslav Hletenko
Add action 'reset' (op-mode) for HTTP-API http://localhost/reset curl --unix-socket /run/api.sock -X POST -Fkey=mykey \ -Fdata='{"op": "reset", "path": ["ip", "bgp", "192.0.2.14"]}' \ http://localhost/reset
2022-04-07http api: T4347: return complete and consistent error codesJohn Estabrook
2022-03-27graphql: T3993: add unsettable gql option; this is not exposed by CLIJohn Estabrook
2021-12-15http-api: T4076: allow setting CORS option 'Access-Control-Allow-Origin'John Estabrook
2021-12-13http-api: T4071: allow API to bind to unix domain socketJohn Estabrook
2021-11-15graphql: T3993: move schema generation to bindings.py; clean up for lintingJohn Estabrook
2021-08-06http-api: T2768: example using GraphQL for high-level config operationsJohn Estabrook
2021-08-06Revert "http-api: T2768: example using GraphQL for high-level config operations"John Estabrook
This reverts commit a2b959c50c96698da173b9c4720369a51442cc5c.
2021-08-06http-api: T2768: example using GraphQL for high-level config operationsJohn Estabrook
2021-06-12http-api: T3616: update for strict content-type check in FastAPI 0.65.2John Estabrook
FastAPI 0.65.2 checks content-type request header before assuming JSON, closing a well-known loophole. This requires a modification of the code providing backwards compatibility of multipart forms.
2021-03-26http api: T3412: use FastAPI as web framework; support application/jsonJohn Estabrook
Replace the Flask micro-framework with FastAPI, in order to support extensions to the API and OpenAPI 3.* generation. This change will remain backwards compatible with previous versions. Notably, the multipart forms version of requests remain supported; in addition application/json requests are now natively supported.
2020-10-21http-api: T3007: use ConfigSession config load script, not backend loadJohn Estabrook
2020-07-22http-api: remove unneeded check for VyOSErrorJohn Estabrook
The only calls to config (return_value, return_values, exists) do not throw VyOSError; remove unneeded except.
2020-05-06http api: T2395: add waitress as production WSGI serverJohn Estabrook
2020-05-06http api: T2395: replace bottle with flask as microframeworkJohn Estabrook
2020-05-06http api: use decorator to get command data from requestJohn Estabrook
2020-05-06http api: catch appropriate errorsJohn Estabrook