From ca72073b49841f776c3a3b455954bbdbeda9189c Mon Sep 17 00:00:00 2001 From: Daniel Kontsek Date: Fri, 28 Oct 2016 17:27:44 +0200 Subject: [PATCH] Updated for Guacamole 0.9.9 --- .gitignore | 1 + README.md | 6 ++--- pom.xml | 24 +++++-------------- .../auth}/RedisAuthenticationProvider.java | 9 +++++-- .../properties/RedisGuacamoleProperties.java | 2 +- src/main/resources/guac-manifest.json | 8 +++++++ 6 files changed, 26 insertions(+), 24 deletions(-) rename src/main/java/{com/erigones/guacamole/net/auth/redis => org/erigones/guacamole/net/auth}/RedisAuthenticationProvider.java (96%) rename src/main/java/{com/erigones/guacamole/net/auth/redis => org/erigones/guacamole/net/auth}/properties/RedisGuacamoleProperties.java (95%) create mode 100644 src/main/resources/guac-manifest.json diff --git a/.gitignore b/.gitignore index abf949c..2fb8d11 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ target/ .*.swp +.DS_Store diff --git a/README.md b/README.md index 709ac60..a3c3e5c 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ guacamole-auth-redis ==================== -[Guacamole](http://guac-dev.org/) Redis authentication plugin. +[Guacamole](http://guac-dev.org/) Redis authentication extension. Build @@ -27,10 +27,10 @@ Install Configure --------- -- Edit the Guacamole configuration file (`/etc/guacamole/guacamole.properties`): +- Edit the Guacamole configuration file (`guacamole.properties`): # Auth provider class - auth-provider: com.erigones.guacamole.net.auth.redis.RedisAuthenticationProvider + auth-provider: org.erigones.guacamole.net.auth.RedisAuthenticationProvider # Redis properties redis-host: localhost diff --git a/pom.xml b/pom.xml index 525af71..4d04f98 100644 --- a/pom.xml +++ b/pom.xml @@ -2,10 +2,10 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> 4.0.0 - com.erigones.guacamole + org.erigones.guacamole guacamole-auth-redis jar - 0.1.0 + 0.2.0 guacamole-auth-redis https://github.com/erigones/guacamole-auth-redis @@ -19,6 +19,7 @@ org.apache.maven.plugins maven-compiler-plugin + 2.3.2 1.6 1.6 @@ -28,38 +29,25 @@ - - - org.slf4j - slf4j-api - 1.6.1 - - - org.slf4j - slf4j-jcl - 1.6.1 - runtime - - org.glyptodon.guacamole guacamole-common - 0.8.0 + 0.9.9 org.glyptodon.guacamole guacamole-ext - 0.8.1 + 0.9.9 redis.clients jedis - 2.2.1 + 2.9.0 jar compile diff --git a/src/main/java/com/erigones/guacamole/net/auth/redis/RedisAuthenticationProvider.java b/src/main/java/org/erigones/guacamole/net/auth/RedisAuthenticationProvider.java similarity index 96% rename from src/main/java/com/erigones/guacamole/net/auth/redis/RedisAuthenticationProvider.java rename to src/main/java/org/erigones/guacamole/net/auth/RedisAuthenticationProvider.java index 43ce1f5..5662141 100644 --- a/src/main/java/com/erigones/guacamole/net/auth/redis/RedisAuthenticationProvider.java +++ b/src/main/java/org/erigones/guacamole/net/auth/RedisAuthenticationProvider.java @@ -1,4 +1,4 @@ -package com.erigones.guacamole.net.auth.redis; +package org.erigones.guacamole.net.auth; import java.util.Map; @@ -9,7 +9,7 @@ import redis.clients.jedis.Jedis; import redis.clients.jedis.JedisPool; import redis.clients.jedis.JedisPoolConfig; -import com.erigones.guacamole.net.auth.redis.properties.RedisGuacamoleProperties; +import org.erigones.guacamole.net.auth.properties.RedisGuacamoleProperties; import org.glyptodon.guacamole.GuacamoleException; import org.glyptodon.guacamole.net.auth.Credentials; import org.glyptodon.guacamole.net.auth.simple.SimpleAuthenticationProvider; @@ -149,4 +149,9 @@ public Map getAuthorizedConfigurations(Credentia return new HashMap(); } } + + @Override + public String getIdentifier() { + return "redis-auth"; + } } diff --git a/src/main/java/com/erigones/guacamole/net/auth/redis/properties/RedisGuacamoleProperties.java b/src/main/java/org/erigones/guacamole/net/auth/properties/RedisGuacamoleProperties.java similarity index 95% rename from src/main/java/com/erigones/guacamole/net/auth/redis/properties/RedisGuacamoleProperties.java rename to src/main/java/org/erigones/guacamole/net/auth/properties/RedisGuacamoleProperties.java index 7f30266..5fea7e1 100644 --- a/src/main/java/com/erigones/guacamole/net/auth/redis/properties/RedisGuacamoleProperties.java +++ b/src/main/java/org/erigones/guacamole/net/auth/properties/RedisGuacamoleProperties.java @@ -1,4 +1,4 @@ -package com.erigones.guacamole.net.auth.redis.properties; +package org.erigones.guacamole.net.auth.properties; import org.glyptodon.guacamole.properties.IntegerGuacamoleProperty; import org.glyptodon.guacamole.properties.StringGuacamoleProperty; diff --git a/src/main/resources/guac-manifest.json b/src/main/resources/guac-manifest.json new file mode 100644 index 0000000..bedc0dd --- /dev/null +++ b/src/main/resources/guac-manifest.json @@ -0,0 +1,8 @@ +{ + "guacamoleVersion": "0.9.9", + "name": "Redis Authentication Extension", + "namespace": "guacamole-auth-redis", + "authProviders": [ + "org.erigones.guacamole.net.auth.RedisAuthenticationProvider" + ] +}