diff --git a/README.txt b/README.txt
new file mode 100644
index 0000000..a4d0883
--- /dev/null
+++ b/README.txt
@@ -0,0 +1,23 @@
+Services Basic Authentication
+=============================
+
+This module adds HTTP basic authentication to the Services module.
+
+
+Installation
+------------
+
+Unpack the module and place the services_basic_auth folder in your site's
+module directory (e.g. sites/all/modules).
+
+
+CGI/FastCGI compatibility
+-------------------------
+
+If you are using the CGI/FastCGI server API, you must apply a patch to your
+.htaccess file for basic authentication to work.
+
+You can either apply the included patch "htaccess-fastcgi.patch" or add the
+following rewrite rule to your .htaccess file manually:
+
+    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
diff --git a/htaccess-fastcgi.patch b/htaccess-fastcgi.patch
new file mode 100644
index 0000000..e46f966
--- /dev/null
+++ b/htaccess-fastcgi.patch
@@ -0,0 +1,13 @@
+diff --git a/.htaccess b/.htaccess
+index 246edc2..e579b6b 100644
+--- a/.htaccess
++++ b/.htaccess
+@@ -128,4 +128,8 @@ DirectoryIndex index.php index.html index.htm
+       Header append Vary Accept-Encoding
+     </FilesMatch>
+   </IfModule>
++
++  # PHP FastCGI doesn't support HTTP Basic Authentication out of the
++  # box so we need this workaround. See http://drupal.org/node/1864628.
++  RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
+ </IfModule>
diff --git a/services_basic_auth.inc b/services_basic_auth.inc
index dc4e391..f7df0b3 100644
--- a/services_basic_auth.inc
+++ b/services_basic_auth.inc
@@ -19,6 +19,13 @@
  *   Returns nothing, or a error message if authentication fails.
  */
 function _services_basic_auth_authenticate_call($settings, $method, $args) {
+  // PHP FastCGI doesn't support HTTP Basic Authentication out of the box so we
+  // need this workaround. Requires a patch to .htaccess.
+  // @see http://drupal.org/node/1864628.
+  if (isset($_SERVER['HTTP_AUTHORIZATION']) AND !empty($_SERVER['HTTP_AUTHORIZATION'])) {
+    list($_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW']) = explode(':', base64_decode(substr($_SERVER['HTTP_AUTHORIZATION'], 6)), 2);
+  }
+
   if (user_is_anonymous() && isset($_SERVER['PHP_AUTH_USER']) && isset($_SERVER['PHP_AUTH_PW'])) {
     $form_state = array();
     $form_state['values']['name'] = $_SERVER['PHP_AUTH_USER'];
