summaryrefslogtreecommitdiff
path: root/rest
Commit message (Collapse)AuthorAgeFilesLines
* Name the RestOAuth2Error enumCorentin Noël2022-08-091-2/+2
| | | | This allows it to be used in the GObject introspection
* vala: Add Rest-1.0.metadataCorentin Noël2022-08-092-0/+32
| | | | | Fixes some missing symbols that are supported by Vala but not by the GObject introspection yet.
* Make the single-header usableCorentin Noël2022-08-094-11/+15
| | | | | | | The pkg-config is only declaring the rest-1.0 directory so we always need to use rest/rest-foo.h and not rest-foo.h Also make sure to include all the headers.
* params: Fix annotations with rest_params_iter_nextCorentin Noël2022-08-091-7/+19
| | | | | | The parameters are not optional as they are always accessed. They can be NULL when the iter is finished, actually always set it so that we are sure to always have an initialized variable
* meson: Add rest header to generate_girCorentin Noël2022-08-091-0/+1
| | | | Allows bindings to use the single header
* Remove oauth1 proxyGünther Wagner2022-06-197-1412/+1
| | | | | | | OAuth1 is discouraged to be used nowadays. Only flickr is the only service we used in the past which needed oauth1. They probably won't update their API to OAuth2 and therefore it was dropped in GOA. Following this example, dropping OAuth1 support too for librest.
* Release 0.9.1Günther Wagner2022-06-191-0/+1
|
* Allow convenient use of librest as a subprojectEmmanuele Bassi2022-06-161-0/+2
| | | | | | | | Meson allows projects to specify the dependency object when used as subprojects; this avoids having to know the variable name to import into the superproject. See: https://mesonbuild.com/Reference-manual_builtin_meson.html#mesonoverride_dependency
* utils: Change alloc function to mallocGünther Wagner2022-03-281-2/+2
| | | | This fixes problems with bindings if they want to free resources
* OAuth2Proxy.fetch_access_token: Provide client secretCodedOre2022-03-071-0/+1
|
* auth: document auth as deprecatedGünther Wagner2022-02-032-0/+9
|
* restore ABIGünther Wagner2022-02-021-0/+2
|
* docs: Fix gtk-doc warningBastien Nocera2022-02-021-1/+1
| | | | ../rest/rest-params.c:224: Warning: Rest: rest_params_as_string_hash_table: unknown parameter 'self' in documentation comment, should be 'params'
* auth: Fix compile-time warningsBastien Nocera2022-02-021-2/+2
| | | | | | | | | | | | | | | | | | ../rest/rest-oauth2-proxy.c: In function ‘rest_oauth2_proxy_build_authorization_url’: /usr/include/glib-2.0/glib/glib-autocleanups.h:28:3: warning: ‘params_string’ may be used uninitialized [-Wmaybe-uninitialized] 28 | g_free (*pp); | ^~~~~~~~~~~~ ../rest/rest-oauth2-proxy.c:355:21: note: ‘params_string’ was declared here 355 | g_autofree gchar *params_string; | ^~~~~~~~~~~~~ ../rest/rest-oauth2-proxy.c: In function ‘rest_oauth2_proxy_new_call’: /usr/include/glib-2.0/glib/glib-autocleanups.h:28:3: warning: ‘auth’ may be used uninitialized in this function [-Wmaybe-uninitialized] 28 | g_free (*pp); | ^~~~~~~~~~~~ ../rest/rest-oauth2-proxy.c:114:21: note: ‘auth’ was declared here 114 | g_autofree gchar *auth; | ^~~~
* auth: remove auth from proxy and callGünther Wagner2022-02-014-82/+21
| | | | | Currently it has not practical use. I will rethink how to implement this in nicer way in order to make one-request basic auths possible.
* proxy-call: prevent message form if no params availableGünther Wagner2022-02-011-6/+12
|
* rest: correct includepath of headerGünther Wagner2022-01-131-2/+2
|
* meson: show vapi option in summaryGünther Wagner2022-01-131-0/+4
| | | | | Also protect against misconfiguration of introspection and vapi as introspection is needed for vapi generation
* Fix merge conflicts.CodedOre2022-01-1327-1143/+1723
|\
| * tests: fix warningsGünther Wagner2022-01-121-2/+1
| |
| * params: reworked to boxed and listGünther Wagner2022-01-124-86/+171
| | | | | | | | | | | | | | RestParams was implemented as HashTable. Limitations are that it did not preserved the order of individual parameters aswell as duplicates aren't allowed. Reworked it to a GList and introduced reference counting and a boxed type.
| * xml: modernizedGünther Wagner2022-01-122-24/+29
| |
| * fixed deprecated g_memdupGünther Wagner2022-01-121-1/+1
| |
| * oauth_proxy_call: remove private usageGünther Wagner2022-01-122-74/+20
| | | | | | | | Instead use public API of OAuthProxy
| * oauth_proxy: modernized and alignedGünther Wagner2022-01-122-116/+154
| |
| * rest-proxy: modernized and alignedGünther Wagner2022-01-122-67/+63
| |
| * OAuth2 Pkce WorkflowGünther Wagner2022-01-1217-777/+1287
| |
| * oauth: fix payloadGünther Wagner2022-01-111-1/+3
| | | | | | | | | | | | Due to the change to soup3 we save the payload now as GBytes. The trailing '\0' is not part of that and therefore one has to create a full string afterwards.
* | Generate vapi for RestCodedOre2022-01-131-0/+8
|/
* soup3: added conditional option to mesongwagner/soup3Günther Wagner2021-11-041-1/+1
|
* Port to libsoup3Carlos Garcia Campos2021-11-044-78/+465
|
* Use GUri instead of SoupURICarlos Garcia Campos2021-11-042-16/+25
|
* Port to the Meson build systemNiels De Graef2021-10-211-0/+107
| | | | | | | | | | | | | | | | | | | See the [Meson website] for a full reference. To build, test and/or install the librest library, you essentially need the following commands: ``` $ meson build $ ninja -C build $ meson test -C build $ ninja -C build install ``` For the GNOME initiative, see https://wiki.gnome.org/Initiatives/GnomeGoals/MesonPorting [Meson website]: http://mesonbuild.com/ https://gitlab.gnome.org/GNOME/librest/merge_requests/1
* Add several missing annotationstintou/annotations-fixesCorentin Noël2020-10-152-8/+19
| | | | Most of them are taken from the Vala overrides: https://gitlab.gnome.org/GNOME/vala/-/blob/master/vapi/metadata/Rest-0.7.metadata
* xml: Don't crash parsing empty XML stringChristophe Fergeau2017-10-181-0/+3
| | | | | | | | | Calling rest_xml_parser_parse_from_data() with an empty string ("") currently causes a crash as xmlReaderForMemory() returns NULL in that case, and we then try to dereference this pointer without checking it's non-NULL. https://bugzilla.gnome.org/show_bug.cgi?id=789053
* proxycall: remove double-assign to status_{code,message}Timm Bäder2017-10-171-3/+0
| | | | | This is already done in finish_call and the g_strdup to priv->status_message was leaking the previously set one.
* RestProxy: Set the payload after _uploadTimm Bäder2017-10-171-1/+1
| | | | | Before this, it was impossible to get the server payload from a proxy call invoked via rest_proxy_call_upload.
* xml-node: Define the order in which attributes & children are printedDebarshi Ray2017-10-161-1/+22
| | | | | | | | | | | | | The order in which GHashTable returns its key-value pairs is undefined. Therefore the output of rest_xml_node_print can change based on the GHashTable implementation. While not strictly necessary, it would be nice to avoid that. Having a stable order, even if it is not documented and depends on the current RestXmlNode code, is handy for testing. This was the main reason behind the tests/xml.c breakage. https://bugzilla.gnome.org/show_bug.cgi?id=788960
* xml-node: Unbreak the creation of top-level nodesDebarshi Ray2017-10-161-1/+0
| | | | | | | | | | The rest_xml_node_add_child API explicitly documents NULL parents as the way to create top-level nodes. This had broken the second half of tests/xml.c. Fallout from b11a1664cd4dfcc62b07b4a68adc220fd1eb8305 https://bugzilla.gnome.org/show_bug.cgi?id=788960
* xml-node: Remove stray blank spaceDebarshi Ray2017-10-161-1/+1
| | | | | | | | This had broken tests/xml.c. Fallout from 61a7b231bd8b9d1b8d02dca120389e79d38b428d https://bugzilla.gnome.org/show_bug.cgi?id=788960
* oauth2-proxy: Use G_DEFINE_TYPE_WITH_PRIVATEDebarshi Ray2017-08-041-6/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=785818
* rest-proxy-auth: Use G_DEFINE_TYPE_WITH_PRIVATEDebarshi Ray2017-08-041-7/+4
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=785818
* oauth2-proxy-call: Use G_DECLARE_DERIVABLE_TYPEDebarshi Ray2017-08-041-22/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=785811
* oauth-proxy-call: Use G_DECLARE_DERIVABLE_TYPEDebarshi Ray2017-08-041-22/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=785811
* rest-xml-parser: Use G_DECLARE_DERIVABLE_TYPEDebarshi Ray2017-08-041-23/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=785811
* rest-proxy-call: Use G_DECLARE_DERIVABLE_TYPEDebarshi Ray2017-08-041-23/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=785811
* rest-proxy: Use G_DECLARE_DERIVABLE_TYPEDebarshi Ray2017-08-041-23/+1
| | | | | | Bump minimum GLib version to 2.44.0. https://bugzilla.gnome.org/show_bug.cgi?id=785811
* RestProxy: Remove unused session_syncTimm Bäder2016-07-191-1/+0
|
* RestProxyCall: Add documentation for _syncTimm Bäder2016-07-191-0/+14
|
* RestProxyCall: Make sure _sync reliably sets error_outTimm Bäder2016-07-192-2/+24
| | | | | | | Currently rest_proxy_call_sync (and everything else using prepare_message) might return FALSE without setting @error at all. Add two new error codes to indicate the possible problems and reliably set the error if something went wrong.