diff --git a/extensions/guacamole-auth-openid/.gitignore b/extensions/guacamole-auth-openid/.gitignore
new file mode 100644
index 000000000..30eb48707
--- /dev/null
+++ b/extensions/guacamole-auth-openid/.gitignore
@@ -0,0 +1,3 @@
+*~
+target/
+src/main/resources/generated/
diff --git a/extensions/guacamole-auth-openid/pom.xml b/extensions/guacamole-auth-openid/pom.xml
index 14aea2b04..4076998f1 100644
--- a/extensions/guacamole-auth-openid/pom.xml
+++ b/extensions/guacamole-auth-openid/pom.xml
@@ -53,6 +53,85 @@
+
+
+ com.keithbranton.mojo
+ angular-maven-plugin
+ 0.3.2
+
+
+ generate-resources
+
+ html2js
+
+
+
+
+ ${basedir}/src/main/resources
+ **/*.html
+ ${basedir}/src/main/resources/generated/templates-main/templates.js
+ app/ext/guac-openid
+
+
+
+
+
+ com.samaxes.maven
+ minify-maven-plugin
+ 1.7.5
+
+
+ default-cli
+
+ UTF-8
+
+ ${basedir}/src/main/resources
+ ${project.build.directory}/classes
+
+ /
+ /
+ openid.css
+
+
+ license.txt
+
+
+
+ **/*.css
+
+
+ /
+ /
+ openid.js
+
+
+ license.txt
+
+
+
+ **/*.js
+
+
+
+
+ **/*.test.js
+
+ CLOSURE
+
+
+
+ OFF
+ OFF
+
+
+
+
+ minify
+
+
+
+
+
org.apache.maven.plugins
@@ -105,6 +184,7 @@
**/*.jsonsrc/licenses/**/*
+ src/main/resources/templates/*.html
diff --git a/extensions/guacamole-auth-openid/src/main/resources/openidConfig.js b/extensions/guacamole-auth-openid/src/main/resources/config/openidConfig.js
similarity index 91%
rename from extensions/guacamole-auth-openid/src/main/resources/openidConfig.js
rename to extensions/guacamole-auth-openid/src/main/resources/config/openidConfig.js
index cf4c81e5d..12bc0dabb 100644
--- a/extensions/guacamole-auth-openid/src/main/resources/openidConfig.js
+++ b/extensions/guacamole-auth-openid/src/main/resources/config/openidConfig.js
@@ -25,8 +25,9 @@ angular.module('guacOpenID').config(['formServiceProvider',
// Define field for token from OpenID service
formServiceProvider.registerFieldType("GUAC_OPENID_TOKEN", {
- controller : 'guacOpenIDController',
- module : 'guacOpenID'
+ templateUrl : 'app/ext/guac-openid/templates/openidTokenField.html',
+ controller : 'guacOpenIDController',
+ module : 'guacOpenID'
});
}]);
diff --git a/extensions/guacamole-auth-openid/src/main/resources/openidController.js b/extensions/guacamole-auth-openid/src/main/resources/controllers/openidController.js
similarity index 100%
rename from extensions/guacamole-auth-openid/src/main/resources/openidController.js
rename to extensions/guacamole-auth-openid/src/main/resources/controllers/openidController.js
diff --git a/extensions/guacamole-auth-openid/src/main/resources/guac-manifest.json b/extensions/guacamole-auth-openid/src/main/resources/guac-manifest.json
index c8d626f48..e71c140fa 100644
--- a/extensions/guacamole-auth-openid/src/main/resources/guac-manifest.json
+++ b/extensions/guacamole-auth-openid/src/main/resources/guac-manifest.json
@@ -9,10 +9,20 @@
"org.apache.guacamole.auth.openid.OpenIDAuthenticationProvider"
],
+ "translations" : [
+ "translations/en.json"
+ ],
+
"js" : [
- "openidModule.js",
- "openidController.js",
- "openidConfig.js"
- ]
+ "openid.min.js"
+ ],
+
+ "css" : [
+ "openid.min.css"
+ ],
+
+ "resources" : {
+ "templates/openidTokenField.html" : "text/html"
+ }
}
diff --git a/extensions/guacamole-auth-openid/src/main/resources/license.txt b/extensions/guacamole-auth-openid/src/main/resources/license.txt
new file mode 100644
index 000000000..042f3ce1f
--- /dev/null
+++ b/extensions/guacamole-auth-openid/src/main/resources/license.txt
@@ -0,0 +1,18 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
diff --git a/extensions/guacamole-auth-openid/src/main/resources/styles/openid.css b/extensions/guacamole-auth-openid/src/main/resources/styles/openid.css
new file mode 100644
index 000000000..eab7f935d
--- /dev/null
+++ b/extensions/guacamole-auth-openid/src/main/resources/styles/openid.css
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+.openid-token-field-container {
+ height: 100%;
+ width: 100%;
+ position: fixed;
+ left: 0;
+ top: 0;
+ display: table;
+ background: white;
+}
+
+.openid-token-field {
+ width: 100%;
+ display: table-cell;
+ vertical-align: middle;
+ text-align: center;
+}
diff --git a/extensions/guacamole-auth-openid/src/main/resources/templates/openidTokenField.html b/extensions/guacamole-auth-openid/src/main/resources/templates/openidTokenField.html
new file mode 100644
index 000000000..49f6c6f0a
--- /dev/null
+++ b/extensions/guacamole-auth-openid/src/main/resources/templates/openidTokenField.html
@@ -0,0 +1,5 @@
+