[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/url-http-oauth 85ea04418c 01/24: url-http-oauth.el: New
From: |
Thomas Fitzsimmons |
Subject: |
[elpa] externals/url-http-oauth 85ea04418c 01/24: url-http-oauth.el: New package |
Date: |
Mon, 8 May 2023 21:10:43 -0400 (EDT) |
branch: externals/url-http-oauth
commit 85ea04418c810bb9ecf64f5a85fefc0a719e962f
Author: Thomas Fitzsimmons <fitzsim@fitzsim.org>
Commit: Thomas Fitzsimmons <fitzsim@fitzsim.org>
url-http-oauth.el: New package
* url-http-oauth.el: New package.
* .gitignore: Ignore autogenerated files.
---
.gitignore | 3 +++
url-http-oauth.el | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 54 insertions(+)
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000000..0a4f7ee4c7
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,3 @@
+/url-http-oauth-pkg.el
+/url-http-oauth-autoloads.el
+*.elc
diff --git a/url-http-oauth.el b/url-http-oauth.el
new file mode 100644
index 0000000000..ba0916d30f
--- /dev/null
+++ b/url-http-oauth.el
@@ -0,0 +1,51 @@
+;;; url-http-oauth.el --- Add OAuth 2.0 authentication support to URL library
-*- lexical-binding: t -*-
+
+;; Copyright (C) 2023 Free Software Foundation, Inc.
+
+;; Author: Thomas Fitzsimmons <fitzsim@fitzsim.org>
+;; Version: 0
+;; Keywords: comm, data, processes, hypermedia
+
+;; This program is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; This program is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+;;; Commentary:
+;;
+;; This package provides an OAuth 2.0 handler for Emacs's URL library.
+;;
+;; Installation:
+;;
+;; M-x package-install RET url-http-oauth RET
+
+;;; Code:
+(require 'url-auth)
+(require 'url-http)
+(require 'url-util)
+
+(defvar url-http-oauth--registered-oauth-urls nil
+ "A hash table mapping URL strings to lists of OAuth 2.0 configuration
items.")
+
+;;; Public function called by `url-get-authentication'.
+;;;###autoload
+(defun url-oauth-auth (url &optional _prompt _overwrite _realm _args)
+ "Return an OAuth 2.0 HTTP authorization header.
+URL is a structure representing a parsed URL."
+ nil)
+
+;;; Register `url-oauth-auth' HTTP authentication method.
+;;;###autoload
+(url-register-auth-scheme "oauth" nil 9)
+
+(provide 'url-http-oauth)
+
+;;; url-http-oauth.el ends here
- [elpa] branch externals/url-http-oauth created (now 40c46af10c), Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 85ea04418c 01/24: url-http-oauth.el: New package,
Thomas Fitzsimmons <=
- [elpa] externals/url-http-oauth cd6df20689 03/24: Implement authorization and access-token steps, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth e104630233 11/24: Convert to URL settings alist, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 334e644a43 07/24: Finish bearer proof-of-concept, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 9d5c820c90 14/24: Fix auth-source lookups, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 972011f217 04/24: Shorten header line to fit into 80 columns, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 8719575647 10/24: Add scope argument to top-level interpose function, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 3b3f9fe53f 12/24: Support extra arguments on authorization URL, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 8601d89d43 18/24: Complete regexp, list and token refresh design, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth ee73bb0450 19/24: Make functions private, fix some bugs, Thomas Fitzsimmons, 2023/05/08
- [elpa] externals/url-http-oauth 7e825a8765 21/24: Allow per-provider user-agent interaction function, Thomas Fitzsimmons, 2023/05/08