Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
memcache
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
memcache
Commits
773d3e81
Commit
773d3e81
authored
Dec 23, 2014
by
Jeremy Andrews
Committed by
Jeremy Andrews
Dec 23, 2014
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#2382225
by Jeremy: Support Memcached SASL
parent
a6a1ca8b
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
README.txt
+21
-4
21 additions, 4 deletions
README.txt
dmemcache.inc
+3
-0
3 additions, 0 deletions
dmemcache.inc
with
24 additions
and
4 deletions
README.txt
+
21
−
4
View file @
773d3e81
...
...
@@ -503,3 +503,20 @@ Other options you could experiment with:
reported that this can speed up the Binary protocol (see above). This
tells the TCP stack to send packets immediately and without waiting for
a full payload, reducing per-packet network latency (disabling "Nagling").
It's possible to enable SASL authentication as documented here:
http://php.net/manual/en/memcached.setsaslauthdata.php
https://code.google.com/p/memcached/wiki/SASLHowto
SASL authentication requires a memcached server with SASL support (version 1.4.3
or greater built with --enable-sasl and started with the -S flag) and the PECL
memcached client version 2.0.0 or greater also built with SASL support. Once
these requirements are satisfied you can then enable SASL support in the Drupal
memcache module by enabling the binary protocol and setting
memcache_sasl_username and memcache_sasl_password in settings.php. For example:
$conf['memcache_options'] = array(
Memcached::OPT_BINARY_PROTOCOL => TRUE,
);
$conf['memcache_sasl_username'] = 'yourSASLUsername';
$conf['memcache_sasl_password'] = 'yourSASLPassword';
This diff is collapsed.
Click to expand it.
dmemcache.inc
+
3
−
0
View file @
773d3e81
...
...
@@ -636,6 +636,9 @@ function dmemcache_instance() {
foreach
(
$memconf
as
$key
=>
$value
)
{
$memcache
->
setOption
(
$key
,
$value
);
}
if
(
$sasl_username
=
variable_get
(
'memcache_sasl_username'
,
''
)
&&
$sasl_password
=
variable_get
(
'memcache_sasl_password'
,
''
))
{
$memcache
->
setSaslAuthData
(
$sasl_username
,
$sasl_password
);
}
return
$memcache
;
}
else
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment