http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/java/org/apache/nifi/web/security/x509/ocsp/OcspCertificateValidator.java ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/java/org/apache/nifi/web/security/x509/ocsp/OcspCertificateValidator.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/java/org/apache/nifi/web/security/x509/ocsp/OcspCertificateValidator.java index 81e4bd6..832a63c 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/java/org/apache/nifi/web/security/x509/ocsp/OcspCertificateValidator.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/java/org/apache/nifi/web/security/x509/ocsp/OcspCertificateValidator.java @@ -42,7 +42,6 @@ import javax.net.ssl.TrustManager; import javax.net.ssl.TrustManagerFactory; import javax.net.ssl.X509TrustManager; import javax.security.auth.x500.X500Principal; -import javax.servlet.http.HttpServletRequest; import org.apache.nifi.framework.security.util.SslContextFactory; import org.apache.nifi.web.security.x509.ocsp.OcspStatus.ValidationStatus; import org.apache.nifi.web.security.x509.ocsp.OcspStatus.VerificationStatus; @@ -158,8 +157,7 @@ public class OcspCertificateValidator { } /** - * Loads the trusted certificate authorities according to the specified - * properties. + * Loads the trusted certificate authorities according to the specified properties. * * @param properties properties * @return map of certificate authorities @@ -208,12 +206,10 @@ public class OcspCertificateValidator { /** * Validates the specified certificate using OCSP if configured. * - * @param request http request + * @param certificates the client certificates * @throws CertificateStatusException ex */ - public void validate(final HttpServletRequest request) throws CertificateStatusException { - final X509Certificate[] certificates = (X509Certificate[]) request.getAttribute("javax.servlet.request.X509Certificate"); - + public void validate(final X509Certificate[] certificates) throws CertificateStatusException { // only validate if configured to do so if (client != null && certificates != null && certificates.length > 0) { final X509Certificate subjectCertificate = getSubjectCertificate(certificates); @@ -395,13 +391,9 @@ public class OcspCertificateValidator { } /** - * Gets the trusted responder certificate. The response contains the - * responder certificate, however we cannot blindly trust it. Instead, we - * use a configured trusted CA. If the responder certificate is a trusted - * CA, then we can use it. If the responder certificate is not directly - * trusted, we still may be able to trust it if it was issued by the same CA - * that issued the subject certificate. Other various checks may be required - * (this portion is currently not implemented). + * Gets the trusted responder certificate. The response contains the responder certificate, however we cannot blindly trust it. Instead, we use a configured trusted CA. If the responder + * certificate is a trusted CA, then we can use it. If the responder certificate is not directly trusted, we still may be able to trust it if it was issued by the same CA that issued the subject + * certificate. Other various checks may be required (this portion is currently not implemented). * * @param responderCertificate cert * @param issuerCertificate cert
http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/resources/nifi-web-security-context.xml ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/resources/nifi-web-security-context.xml b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/resources/nifi-web-security-context.xml index fa5b9e2..40f678c 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/resources/nifi-web-security-context.xml +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/resources/nifi-web-security-context.xml @@ -13,70 +13,45 @@ See the License for the specific language governing permissions and limitations under the License. --> -<!-- marked as lazy so that security beans are not created when applications runs in non-secure mode --> -<beans default-lazy-init="true" - xmlns="http://www.springframework.org/schema/beans" +<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xmlns:sec="http://www.springframework.org/schema/security" - xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd - http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.2.xsd"> + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> - <!-- http security configuration --> - <sec:http create-session="stateless" auto-config="false" entry-point-ref="entryPoint"> - <sec:anonymous enabled="false"/> - <sec:custom-filter ref="nodeAuthorizedUserFilter" before="PRE_AUTH_FILTER"/> - <sec:custom-filter ref="x509Filter" position="PRE_AUTH_FILTER"/> - <sec:custom-filter ref="anonymousFilter" position="ANONYMOUS_FILTER"/> - </sec:http> + <!-- certificate extractor --> + <bean id="certificateExtractor" class="org.apache.nifi.web.security.x509.X509CertificateExtractor"/> - <!-- enable method level security --> - <sec:global-method-security pre-post-annotations="enabled"/> - - <!-- entry point reference --> - <bean id="entryPoint" class="org.apache.nifi.web.security.authentication.NiFiAuthenticationEntryPoint"/> + <!-- principal extractor --> + <bean id="principalExtractor" class="org.apache.nifi.web.security.x509.SubjectDnX509PrincipalExtractor"/> - <!-- authentication manager --> - <sec:authentication-manager alias="authenticationManager"> - <sec:authentication-provider ref="preauthAuthProvider"/> - </sec:authentication-manager> - - <!-- pre-authentication provider --> - <bean id="preauthAuthProvider" class="org.springframework.security.web.authentication.preauth.PreAuthenticatedAuthenticationProvider"> - <property name="preAuthenticatedUserDetailsService"> - <bean class="org.springframework.security.core.userdetails.UserDetailsByNameServiceWrapper"> - <property name="userDetailsService" ref="userAuthorizationService"/> - </bean> - </property> + <!-- ocsp validator --> + <bean id="ocspValidator" class="org.apache.nifi.web.security.x509.ocsp.OcspCertificateValidator"> + <constructor-arg ref="nifiProperties"/> </bean> - - <!-- user details service --> - <bean id="userAuthorizationService" class="org.apache.nifi.web.security.authorization.NiFiAuthorizationService"> - <property name="userService" ref="userService"/> - <property name="properties" ref="nifiProperties"/> + + <!-- x509 validator --> + <bean id="certificateValidator" class="org.apache.nifi.web.security.x509.X509CertificateValidator"> + <property name="ocspValidator" ref="ocspValidator"/> </bean> - - <!-- performs ocsp certificate validation --> - <bean id="ocspCertificateValidator" class="org.apache.nifi.web.security.x509.ocsp.OcspCertificateValidator"> - <constructor-arg ref="nifiProperties"/> + + <!-- x509 identity provider --> + <bean id="certificateIdentityProvider" class="org.apache.nifi.web.security.x509.X509IdentityProvider"> + <property name="principalExtractor" ref="principalExtractor"/> + <property name="certificateValidator" ref="certificateValidator"/> </bean> - - <!-- custom x509 filter for checking for proxied users --> - <bean id="x509Filter" class="org.apache.nifi.web.security.x509.X509AuthenticationFilter"> - <property name="authenticationManager" ref="authenticationManager"/> - <property name="properties" ref="nifiProperties"/> + + <!-- user details service --> + <bean id="userDetailsService" class="org.apache.nifi.web.security.authorization.NiFiAuthorizationService"> <property name="userService" ref="userService"/> - <property name="certificateValidator" ref="ocspCertificateValidator"/> - <property name="continueFilterChainOnUnsuccessfulAuthentication" value="false"/> - </bean> - - <!-- custom filter for checking for proxied users that are already authenticated --> - <bean id="nodeAuthorizedUserFilter" class="org.apache.nifi.web.security.authorization.NodeAuthorizedUserFilter"> <property name="properties" ref="nifiProperties"/> </bean> - - <!-- custom anonymous filter to assign default roles based on current operating mode --> - <bean id="anonymousFilter" class="org.apache.nifi.web.security.anonymous.NiFiAnonymousUserFilter"> - <property name="userService" ref="userService"/> + + <!-- jwt service --> + <bean id="jwtService" class="org.apache.nifi.web.security.jwt.JwtService"> + <constructor-arg ref="keyService"/> + </bean> + + <!-- login identity provider --> + <bean id="loginIdentityProvider" class="org.apache.nifi.web.security.spring.LoginIdentityProviderFactoryBean"> <property name="properties" ref="nifiProperties"/> </bean> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/xsd/login-identity-providers.xsd ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/xsd/login-identity-providers.xsd b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/xsd/login-identity-providers.xsd new file mode 100644 index 0000000..628f390 --- /dev/null +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/main/xsd/login-identity-providers.xsd @@ -0,0 +1,49 @@ +<?xml version="1.0"?> +<!-- + 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. +--> +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> + <!-- role --> + <xs:complexType name="Provider"> + <xs:sequence> + <xs:element name="identifier" type="NonEmptyStringType"/> + <xs:element name="class" type="NonEmptyStringType"/> + <xs:element name="property" type="Property" minOccurs="0" maxOccurs="unbounded" /> + </xs:sequence> + </xs:complexType> + + <!-- Name/Value properties--> + <xs:complexType name="Property"> + <xs:simpleContent> + <xs:extension base="xs:string"> + <xs:attribute name="name" type="NonEmptyStringType"></xs:attribute> + </xs:extension> + </xs:simpleContent> + </xs:complexType> + + <xs:simpleType name="NonEmptyStringType"> + <xs:restriction base="xs:string"> + <xs:minLength value="1"/> + </xs:restriction> + </xs:simpleType> + + <!-- login identity provider --> + <xs:element name="loginIdentityProviders"> + <xs:complexType> + <xs:sequence> + <xs:element name="provider" type="Provider" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:complexType> + </xs:element> +</xs:schema> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/authorization/NiFiAuthorizationServiceTest.java ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/authorization/NiFiAuthorizationServiceTest.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/authorization/NiFiAuthorizationServiceTest.java index 6d0c3cb..5456552 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/authorization/NiFiAuthorizationServiceTest.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/authorization/NiFiAuthorizationServiceTest.java @@ -16,6 +16,7 @@ */ package org.apache.nifi.web.security.authorization; +import java.util.Arrays; import org.apache.nifi.admin.service.AccountDisabledException; import org.apache.nifi.admin.service.AccountNotFoundException; import org.apache.nifi.admin.service.AccountPendingException; @@ -24,8 +25,8 @@ import org.apache.nifi.admin.service.UserService; import org.apache.nifi.authorization.Authority; import org.apache.nifi.user.NiFiUser; import org.apache.nifi.util.NiFiProperties; -import org.apache.nifi.web.security.DnUtils; import org.apache.nifi.web.security.UntrustedProxyException; +import org.apache.nifi.web.security.token.NiFiAuthenticationRequestToken; import org.apache.nifi.web.security.user.NiFiUserDetails; import org.junit.Assert; import org.junit.Before; @@ -66,10 +67,10 @@ public class NiFiAuthorizationServiceTest { @Override public Object answer(InvocationOnMock invocation) throws Throwable { Object[] args = invocation.getArguments(); - String dn = (String) args[0]; + String identity = (String) args[0]; - if (null != dn) { - switch (dn) { + if (null != identity) { + switch (identity) { case USER_NOT_FOUND: case PROXY_NOT_FOUND: throw new AccountNotFoundException(""); @@ -81,13 +82,13 @@ public class NiFiAuthorizationServiceTest { throw new AdministrationException(); case USER: final NiFiUser monitor = new NiFiUser(); - monitor.setDn(dn); + monitor.setIdentity(identity); monitor.getAuthorities().add(Authority.ROLE_MONITOR); return monitor; case PROXY: case PROXY_PROXY: final NiFiUser proxy = new NiFiUser(); - proxy.setDn(dn); + proxy.setIdentity(identity); proxy.getAuthorities().add(Authority.ROLE_PROXY); return proxy; } @@ -103,15 +104,18 @@ public class NiFiAuthorizationServiceTest { authorizationService.setUserService(userService); } + private NiFiAuthenticationRequestToken createRequestAuthentication(final String... identities) { + return new NiFiAuthenticationRequestToken(Arrays.asList(identities)); + } + /** - * Ensures the authorization service correctly handles users invalid dn - * chain. + * Ensures the authorization service correctly handles users invalid identity chain. * * @throws Exception ex */ @Test(expected = UntrustedProxyException.class) public void testInvalidDnChain() throws Exception { - authorizationService.loadUserByUsername(USER); + authorizationService.loadUserDetails(createRequestAuthentication()); } /** @@ -121,7 +125,7 @@ public class NiFiAuthorizationServiceTest { */ @Test(expected = UsernameNotFoundException.class) public void testAccountNotFound() throws Exception { - authorizationService.loadUserByUsername(DnUtils.formatProxyDn(USER_NOT_FOUND)); + authorizationService.loadUserDetails(createRequestAuthentication(USER_NOT_FOUND)); } /** @@ -131,7 +135,7 @@ public class NiFiAuthorizationServiceTest { */ @Test(expected = AccountStatusException.class) public void testAccountDisabled() throws Exception { - authorizationService.loadUserByUsername(DnUtils.formatProxyDn(USER_DISABLED)); + authorizationService.loadUserDetails(createRequestAuthentication(USER_DISABLED)); } /** @@ -141,18 +145,17 @@ public class NiFiAuthorizationServiceTest { */ @Test(expected = AccountStatusException.class) public void testAccountPending() throws Exception { - authorizationService.loadUserByUsername(DnUtils.formatProxyDn(USER_PENDING)); + authorizationService.loadUserDetails(createRequestAuthentication(USER_PENDING)); } /** - * Ensures the authorization service correctly handles account - * administration exception. + * Ensures the authorization service correctly handles account administration exception. * * @throws Exception ex */ @Test(expected = AuthenticationServiceException.class) public void testAccountAdminException() throws Exception { - authorizationService.loadUserByUsername(DnUtils.formatProxyDn(USER_ADMIN_EXCEPTION)); + authorizationService.loadUserDetails(createRequestAuthentication(USER_ADMIN_EXCEPTION)); } /** @@ -162,10 +165,10 @@ public class NiFiAuthorizationServiceTest { */ @Test public void testNoProxy() throws Exception { - final NiFiUserDetails details = (NiFiUserDetails) authorizationService.loadUserByUsername(DnUtils.formatProxyDn(USER)); + final NiFiUserDetails details = (NiFiUserDetails) authorizationService.loadUserDetails(createRequestAuthentication(USER)); final NiFiUser user = details.getNiFiUser(); - Assert.assertEquals(USER, user.getDn()); + Assert.assertEquals(USER, user.getIdentity()); Assert.assertNull(user.getChain()); } @@ -176,21 +179,18 @@ public class NiFiAuthorizationServiceTest { */ @Test(expected = UntrustedProxyException.class) public void testInvalidProxy() throws Exception { - final String dnChain = DnUtils.formatProxyDn(USER) + DnUtils.formatProxyDn(USER); - authorizationService.loadUserByUsername(dnChain); + authorizationService.loadUserDetails(createRequestAuthentication(USER, USER)); } /** - * Ensures the authorization service correctly handles proxy not found by - * attempting to create an account request for the proxy. + * Ensures the authorization service correctly handles proxy not found by attempting to create an account request for the proxy. * * @throws Exception ex */ - @Test(expected = UsernameNotFoundException.class) + @Test(expected = UntrustedProxyException.class) public void testProxyNotFound() throws Exception { try { - final String dnChain = DnUtils.formatProxyDn(USER) + DnUtils.formatProxyDn(PROXY_NOT_FOUND); - authorizationService.loadUserByUsername(DnUtils.formatProxyDn(dnChain)); + authorizationService.loadUserDetails(createRequestAuthentication(USER, PROXY_NOT_FOUND)); } finally { Mockito.verify(userService).createPendingUserAccount(Mockito.eq(PROXY_NOT_FOUND), Mockito.anyString()); } @@ -203,19 +203,18 @@ public class NiFiAuthorizationServiceTest { */ @Test public void testProxy() throws Exception { - final String dnChain = DnUtils.formatProxyDn(USER) + DnUtils.formatProxyDn(PROXY); - final NiFiUserDetails details = (NiFiUserDetails) authorizationService.loadUserByUsername(dnChain); + final NiFiUserDetails details = (NiFiUserDetails) authorizationService.loadUserDetails(createRequestAuthentication(USER, PROXY)); final NiFiUser user = details.getNiFiUser(); // verify the user - Assert.assertEquals(USER, user.getDn()); + Assert.assertEquals(USER, user.getIdentity()); Assert.assertNotNull(user.getChain()); // get the proxy final NiFiUser proxy = user.getChain(); // verify the proxy - Assert.assertEquals(PROXY, proxy.getDn()); + Assert.assertEquals(PROXY, proxy.getIdentity()); Assert.assertNull(proxy.getChain()); } @@ -226,26 +225,25 @@ public class NiFiAuthorizationServiceTest { */ @Test public void testProxyProxy() throws Exception { - final String dnChain = DnUtils.formatProxyDn(USER) + DnUtils.formatProxyDn(PROXY) + DnUtils.formatProxyDn(PROXY_PROXY); - final NiFiUserDetails details = (NiFiUserDetails) authorizationService.loadUserByUsername(dnChain); + final NiFiUserDetails details = (NiFiUserDetails) authorizationService.loadUserDetails(createRequestAuthentication(USER, PROXY, PROXY_PROXY)); final NiFiUser user = details.getNiFiUser(); // verify the user - Assert.assertEquals(USER, user.getDn()); + Assert.assertEquals(USER, user.getIdentity()); Assert.assertNotNull(user.getChain()); // get the proxy NiFiUser proxy = user.getChain(); // verify the proxy - Assert.assertEquals(PROXY, proxy.getDn()); + Assert.assertEquals(PROXY, proxy.getIdentity()); Assert.assertNotNull(proxy.getChain()); // get the proxies proxy proxy = proxy.getChain(); // verify the proxies proxy - Assert.assertEquals(PROXY_PROXY, proxy.getDn()); + Assert.assertEquals(PROXY_PROXY, proxy.getIdentity()); Assert.assertNull(proxy.getChain()); } } http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/jwt/JwtServiceTest.java ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/jwt/JwtServiceTest.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/jwt/JwtServiceTest.java new file mode 100644 index 0000000..59c66ef --- /dev/null +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/java/org/apache/nifi/web/security/jwt/JwtServiceTest.java @@ -0,0 +1,445 @@ +/* + * 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. + */ +package org.apache.nifi.web.security.jwt; + +import io.jsonwebtoken.JwtException; +import org.apache.commons.codec.CharEncoding; +import org.apache.commons.codec.binary.Base64; +import org.apache.nifi.admin.service.AdministrationException; +import org.apache.nifi.admin.service.KeyService; +import org.apache.nifi.key.Key; +import org.apache.nifi.web.security.token.LoginAuthenticationToken; +import org.codehaus.jettison.json.JSONObject; +import org.junit.After; +import org.junit.Before; +import org.junit.Ignore; +import org.junit.Test; +import org.mockito.Mockito; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import javax.crypto.Mac; +import javax.crypto.spec.SecretKeySpec; +import java.io.UnsupportedEncodingException; +import java.security.InvalidKeyException; +import java.security.NoSuchAlgorithmException; +import java.util.LinkedHashMap; +import java.util.Map; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.fail; +import static org.mockito.Matchers.anyInt; +import static org.mockito.Matchers.anyString; +import static org.mockito.Mockito.when; + +public class JwtServiceTest { + + private static final Logger logger = LoggerFactory.getLogger(JwtServiceTest.class); + + /** + * These constant strings were generated using the tool at http://jwt.io + */ + private static final String VALID_SIGNED_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiJhbG9wcmVzdG8iLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRl" + + "ciIsImF1ZCI6Ik1vY2tJZGVudGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZ" + + "XJuYW1lIjoiYWxvcHJlc3RvIiwia2lkIjoxLCJleHAiOjI0NDc4MDg3NjEsIm" + + "lhdCI6MTQ0NzgwODcwMX0.r6aGZ6FNNYMOpcXW8BK2VYaQeX1uO0Aw1KJfjB3Q1DU"; + + // This token has an empty subject field + private static final String INVALID_SIGNED_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiIiLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsImF1ZCI6Ik1vY2tJZG" + + "VudGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxvcHJlc3RvI" + + "iwia2lkIjoxLCJleHAiOjI0NDc4MDg3NjEsImlhdCI6MTQ0NzgwODcwMX0" + + ".x_1p2M6E0vwWHWMujIUnSL3GkFoDqqICllRxo2SMNaw"; + + private static final String VALID_UNSIGNED_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiJhbG9wcmVzdG8iLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsImF1ZC" + + "I6Ik1vY2tJZGVudGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxvcHJl" + + "c3RvIiwia2lkIjoiYWxvcHJlc3RvIiwiZXhwIjoyNDQ3ODA4NzYxLCJpYXQiOjE0NDc4MDg3MDF9"; + + // This token has an empty subject field + private static final String INVALID_UNSIGNED_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiIiLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsImF1ZCI6Ik1vY2tJZGVu" + + "dGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxvcHJlc3RvIiwia2lkIjoi" + + "YWxvcHJlc3RvIiwiZXhwIjoyNDQ3ODA4NzYxLCJpYXQiOjE0NDc4MDg3MDF9"; + + // Algorithm field is "none" + private static final String VALID_MALSIGNED_TOKEN = "eyJhbGciOiJub25lIn0" + + ".eyJzdWIiOiJhbG9wcmVzdG8iLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsImF1ZC" + + "I6Ik1vY2tJZGVudGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxvcHJl" + + "c3RvIiwia2lkIjoiYWxvcHJlc3RvIiwiZXhwIjoxNDQ3ODA4NzYxLCJpYXQiOjE0NDc4MDg3MDF9" + + ".mPO_wMNMl_zjMNevhNvUoXbSJ9Kx6jAe5OxDIAzKQbI"; + + // Algorithm field is "none" and no signature is present + private static final String VALID_MALSIGNED_NO_SIG_TOKEN = "eyJhbGciOiJub25lIn0" + + ".eyJzdWIiOiJhbG9wcmVzdG8iLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsImF1ZCI6Ik1vY" + + "2tJZGVudGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxvcHJlc3RvIiwia2lkIj" + + "oiYWxvcHJlc3RvIiwiZXhwIjoyNDQ3ODA4NzYxLCJpYXQiOjE0NDc4MDg3MDF9."; + + // This token has an empty subject field + private static final String INVALID_MALSIGNED_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiIiLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsImF1ZCI6Ik1vY2tJZGVud" + + "Gl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxvcHJlc3RvIiwia2lkIjoiYW" + + "xvcHJlc3RvIiwiZXhwIjoxNDQ3ODA4NzYxLCJpYXQiOjE0NDc4MDg3MDF9.WAwmUY4KHKV2oARNodkqDkbZsfRXGZfD2Ccy64GX9QF"; + + // This token is signed but expired + private static final String EXPIRED_SIGNED_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiIiLCJpc3MiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsImF1ZCI6Ik" + + "1vY2tJZGVudGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxvc" + + "HJlc3RvIiwia2lkIjoxLCJleHAiOjE0NDc4MDg3NjEsImlhdCI6MTQ0NzgwODcw" + + "MX0.ZPDIhNKuL89vTGXcuztOYaGifwcrQy_gid4j8Sspmto"; + + // Subject is "mgilman" but signed with "alopresto" key + private static final String IMPOSTER_SIGNED_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiJtZ2lsbWFuIiwiaXNzIjoiTW9ja0lkZW50aXR5UHJvdmlkZXIiLCJ" + + "hdWQiOiJNb2NrSWRlbnRpdHlQcm92aWRlciIsInByZWZlcnJlZF91c2VybmFtZSI" + + "6ImFsb3ByZXN0byIsImtpZCI6MSwiZXhwIjoyNDQ3ODA4NzYxLCJpYXQiOjE0NDc" + + "4MDg3MDF9.aw5OAvLTnb_sHmSQOQzW-A7NImiZgXJ2ngbbNL2Ymkc"; + + // Issuer field is set to unknown provider + private static final String UNKNOWN_ISSUER_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiJhbG9wcmVzdG8iLCJpc3MiOiJVbmtub3duSWRlbnRpdHlQcm92aWRlciIsIm" + + "F1ZCI6Ik1vY2tJZGVudGl0eVByb3ZpZGVyIiwicHJlZmVycmVkX3VzZXJuYW1lIjoiYWxv" + + "cHJlc3RvIiwia2lkIjoiYWxvcHJlc3RvIiwiZXhwIjoyNDQ3ODA4NzYxLCJpYXQiOjE0NDc4MDg3MDF9" + + ".SAd9tyNwSaijWet9wvAWSNmpxmPSK4XQuLx7h3ARqBo"; + + // Issuer field is absent + private static final String NO_ISSUER_TOKEN = "eyJhbGciOiJIUzI1NiJ9" + + ".eyJzdWIiOiJhbG9wcmVzdG8iLCJhdWQiOiJNb2NrSWRlbnRpdHlQcm92a" + + "WRlciIsInByZWZlcnJlZF91c2VybmFtZSI6ImFsb3ByZXN0byIsImtpZCI" + + "6MSwiZXhwIjoyNDQ3ODA4NzYxLCJpYXQiOjE0NDc4MDg3MDF9.6kDjDanA" + + "g0NQDb3C8FmgbBAYDoIfMAEkF4WMVALsbJA"; + + private static final String DEFAULT_HEADER = "{\"alg\":\"HS256\"}"; + private static final String DEFAULT_IDENTITY = "alopresto"; + + private static final String TOKEN_DELIMITER = "."; + + private static final String HMAC_SECRET = "test_hmac_shared_secret"; + + private KeyService mockKeyService; + + // Class under test + private JwtService jwtService; + + private String generateHS256Token(String rawHeader, String rawPayload, boolean isValid, boolean isSigned) { + return generateHS256Token(rawHeader, rawPayload, HMAC_SECRET, isValid, isSigned); + } + + private String generateHS256Token(String rawHeader, String rawPayload, String hmacSecret, boolean isValid, + boolean isSigned) { + try { + logger.info("Generating token for " + rawHeader + " + " + rawPayload); + + String base64Header = Base64.encodeBase64URLSafeString(rawHeader.getBytes(CharEncoding.UTF_8)); + String base64Payload = Base64.encodeBase64URLSafeString(rawPayload.getBytes(CharEncoding.UTF_8)); + // TODO: Support valid/invalid manipulation + + final String body = base64Header + TOKEN_DELIMITER + base64Payload; + + String signature = generateHMAC(hmacSecret, body); + + return body + TOKEN_DELIMITER + signature; + } catch (NoSuchAlgorithmException | InvalidKeyException | UnsupportedEncodingException e) { + final String errorMessage = "Could not generate the token"; + logger.error(errorMessage, e); + fail(errorMessage); + return null; + } + } + + private String generateHMAC(String hmacSecret, String body) throws NoSuchAlgorithmException, + UnsupportedEncodingException, InvalidKeyException { + Mac hmacSHA256 = Mac.getInstance("HmacSHA256"); + SecretKeySpec secret_key = new SecretKeySpec(hmacSecret.getBytes("UTF-8"), "HmacSHA256"); + hmacSHA256.init(secret_key); + return Base64.encodeBase64URLSafeString(hmacSHA256.doFinal(body.getBytes("UTF-8"))); + } + + @Before + public void setUp() throws Exception { + final Key key = new Key(); + key.setId(1); + key.setIdentity(DEFAULT_IDENTITY); + key.setKey(HMAC_SECRET); + + mockKeyService = Mockito.mock(KeyService.class); + when(mockKeyService.getKey(anyInt())).thenReturn(key); + when(mockKeyService.getOrCreateKey(anyString())).thenReturn(key); + jwtService = new JwtService(mockKeyService); + } + + @After + public void tearDown() throws Exception { + + } + + @Test + public void testShouldGetAuthenticationForValidToken() throws Exception { + // Arrange + String token = VALID_SIGNED_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + assertEquals("Identity", DEFAULT_IDENTITY, identity); + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForInvalidToken() throws Exception { + // Arrange + String token = INVALID_SIGNED_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForEmptyToken() throws Exception { + // Arrange + String token = ""; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForUnsignedToken() throws Exception { + // Arrange + String token = VALID_UNSIGNED_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForMalsignedToken() throws Exception { + // Arrange + String token = VALID_MALSIGNED_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForTokenWithWrongAlgorithm() throws Exception { + // Arrange + String token = VALID_MALSIGNED_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForTokenWithWrongAlgorithmAndNoSignature() throws Exception { + // Arrange + String token = VALID_MALSIGNED_NO_SIG_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Ignore("Not yet implemented") + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForTokenFromUnknownIdentityProvider() throws Exception { + // Arrange + String token = UNKNOWN_ISSUER_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForTokenFromEmptyIdentityProvider() throws Exception { + // Arrange + String token = NO_ISSUER_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForExpiredToken() throws Exception { + // Arrange + String token = EXPIRED_SIGNED_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test(expected = JwtException.class) + public void testShouldNotGetAuthenticationForImposterToken() throws Exception { + // Arrange + String token = IMPOSTER_SIGNED_TOKEN; + + // Act + String identity = jwtService.getAuthenticationFromToken(token); + logger.debug("Extracted identity: " + identity); + + // Assert + // Should fail + } + + @Test + public void testShouldGenerateSignedToken() throws Exception { + // Arrange + + // Token expires in 60 seconds + final int EXPIRATION_MILLIS = 60000; + LoginAuthenticationToken loginAuthenticationToken = new LoginAuthenticationToken("alopresto", + EXPIRATION_MILLIS, + "MockIdentityProvider"); + logger.debug("Generating token for " + loginAuthenticationToken); + + final String EXPECTED_HEADER = DEFAULT_HEADER; + + // Convert the expiration time from ms to s + final long TOKEN_EXPIRATION_SEC = (long) (loginAuthenticationToken.getExpiration() / 1000.0); + + // Act + String token = jwtService.generateSignedToken(loginAuthenticationToken); + logger.debug("Generated JWT: " + token); + + // Run after the SUT generates the token to ensure the same issued at time + // Split the token, decode the middle section, and form a new String + final String DECODED_PAYLOAD = new String(Base64.decodeBase64(token.split("\\.")[1].getBytes())); + final long ISSUED_AT_SEC = Long.valueOf(DECODED_PAYLOAD.substring(DECODED_PAYLOAD.lastIndexOf(":") + 1, + DECODED_PAYLOAD.length() - 1)); + logger.trace("Actual token was issued at " + ISSUED_AT_SEC); + + // Always use LinkedHashMap to enforce order of the keys because the signature depends on order + Map<String, Object> claims = new LinkedHashMap<>(); + claims.put("sub", "alopresto"); + claims.put("iss", "MockIdentityProvider"); + claims.put("aud", "MockIdentityProvider"); + claims.put("preferred_username", "alopresto"); + claims.put("kid", 1); + claims.put("exp", TOKEN_EXPIRATION_SEC); + claims.put("iat", ISSUED_AT_SEC); + logger.trace("JSON Object to String: " + new JSONObject(claims).toString()); + + final String EXPECTED_PAYLOAD = new JSONObject(claims).toString(); + final String EXPECTED_TOKEN_STRING = generateHS256Token(EXPECTED_HEADER, EXPECTED_PAYLOAD, true, true); + logger.debug("Expected JWT: " + EXPECTED_TOKEN_STRING); + + // Assert + assertEquals("JWT token", EXPECTED_TOKEN_STRING, token); + } + + @Test(expected = IllegalArgumentException.class) + public void testShouldNotGenerateTokenWithNullAuthenticationToken() throws Exception { + // Arrange + LoginAuthenticationToken nullLoginAuthenticationToken = null; + logger.debug("Generating token for " + nullLoginAuthenticationToken); + + // Act + jwtService.generateSignedToken(nullLoginAuthenticationToken); + + // Assert + // Should throw exception + } + + @Test(expected = JwtException.class) + public void testShouldNotGenerateTokenWithEmptyIdentity() throws Exception { + // Arrange + final int EXPIRATION_MILLIS = 60000; + LoginAuthenticationToken emptyIdentityLoginAuthenticationToken = new LoginAuthenticationToken("", + EXPIRATION_MILLIS, "MockIdentityProvider"); + logger.debug("Generating token for " + emptyIdentityLoginAuthenticationToken); + + // Act + jwtService.generateSignedToken(emptyIdentityLoginAuthenticationToken); + + // Assert + // Should throw exception + } + + @Test(expected = JwtException.class) + public void testShouldNotGenerateTokenWithNullIdentity() throws Exception { + // Arrange + final int EXPIRATION_MILLIS = 60000; + LoginAuthenticationToken nullIdentityLoginAuthenticationToken = new LoginAuthenticationToken(null, + EXPIRATION_MILLIS, "MockIdentityProvider"); + logger.debug("Generating token for " + nullIdentityLoginAuthenticationToken); + + // Act + jwtService.generateSignedToken(nullIdentityLoginAuthenticationToken); + + // Assert + // Should throw exception + } + + @Test(expected = JwtException.class) + public void testShouldNotGenerateTokenWithMissingKey() throws Exception { + // Arrange + final int EXPIRATION_MILLIS = 60000; + LoginAuthenticationToken loginAuthenticationToken = new LoginAuthenticationToken("alopresto", + EXPIRATION_MILLIS, + "MockIdentityProvider"); + logger.debug("Generating token for " + loginAuthenticationToken); + + // Set up the bad key service + KeyService missingKeyService = Mockito.mock(KeyService.class); + when(missingKeyService.getOrCreateKey(anyString())).thenThrow(new AdministrationException("Could not find a " + + "key for that user")); + jwtService = new JwtService(missingKeyService); + + // Act + jwtService.generateSignedToken(loginAuthenticationToken); + + // Assert + // Should throw exception + } +} http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/resources/logback-test.xml ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/resources/logback-test.xml b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/resources/logback-test.xml new file mode 100644 index 0000000..fe5d27e --- /dev/null +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-security/src/test/resources/logback-test.xml @@ -0,0 +1,36 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. +--> + +<configuration> + <appender name="CONSOLE" class="ch.qos.logback.core.ConsoleAppender"> + <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder"> + <pattern>%-4r [%t] %-5p %c - %m%n</pattern> + </encoder> + </appender> + + <appender name="FILE" class="ch.qos.logback.core.FileAppender"> + <file>./target/log</file> + <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder"> + <pattern>%date %level [%thread] %logger{40} %msg%n</pattern> + </encoder> + </appender> + + + <logger name="org.apache.nifi" level="TRACE"/> + <root level="INFO"> + <appender-ref ref="CONSOLE"/> + </root> +</configuration> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/pom.xml ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/pom.xml b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/pom.xml index 195f14b..a4ef516 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/pom.xml +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/pom.xml @@ -32,6 +32,7 @@ <templates.filter>templates.properties</templates.filter> <users.filter>users.properties</users.filter> <bulletin.board.filter>bulletin-board.properties</bulletin.board.filter> + <login.filter>login.properties</login.filter> <provenance.filter>provenance.properties</provenance.filter> </properties> <build> @@ -54,6 +55,7 @@ <filter>src/main/resources/filters/${templates.filter}</filter> <filter>src/main/resources/filters/${users.filter}</filter> <filter>src/main/resources/filters/${bulletin.board.filter}</filter> + <filter>src/main/resources/filters/${login.filter}</filter> <filter>src/main/resources/filters/${provenance.filter}</filter> </filters> <plugins> @@ -89,7 +91,8 @@ **/cluster.jsp, **/templates.jsp, **/users.jsp, - **/bulletin-board.jsp + **/bulletin-board.jsp, + **/login.jsp </excludes> </configuration> </execution> @@ -209,6 +212,14 @@ </includes> <filtering>true</filtering> </resource> + <resource> + <directory>src/main/webapp/WEB-INF/pages</directory> + <targetPath>WEB-INF/pages</targetPath> + <includes> + <include>login.jsp</include> + </includes> + <filtering>true</filtering> + </resource> </webResources> </configuration> </plugin> @@ -229,6 +240,7 @@ <templates.filter>templates-min.properties</templates.filter> <users.filter>users-min.properties</users.filter> <bulletin.board.filter>bulletin-board-min.properties</bulletin.board.filter> + <login.filter>login-min.properties</login.filter> <provenance.filter>provenance-min.properties</provenance.filter> </properties> <build> @@ -263,11 +275,10 @@ <include>${staging.dir}/js/nf/canvas/nf-canvas-utils.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> <include>${staging.dir}/js/nf/nf-shell.js</include> - <include>${staging.dir}/js/nf/canvas/nf-storage.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/canvas/nf-snippet.js</include> <include>${staging.dir}/js/nf/canvas/nf-canvas-toolbox.js</include> <include>${staging.dir}/js/nf/canvas/nf-custom-ui.js</include> - <include>${staging.dir}/js/nf/canvas/nf-registration.js</include> <include>${staging.dir}/js/nf/canvas/nf-controller-service.js</include> <include>${staging.dir}/js/nf/canvas/nf-reporting-task.js</include> <include>${staging.dir}/js/nf/canvas/nf-processor-configuration.js</include> @@ -317,6 +328,7 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/history/nf-history.js</include> <include>${staging.dir}/js/nf/history/nf-history-table.js</include> <include>${staging.dir}/js/nf/history/nf-history-model.js</include> @@ -329,6 +341,7 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/provenance/nf-provenance.js</include> <include>${staging.dir}/js/nf/provenance/nf-provenance-table.js</include> </includes> @@ -340,6 +353,7 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/nf-processor-details.js</include> <include>${staging.dir}/js/nf/nf-connection-details.js</include> <include>${staging.dir}/js/nf/summary/nf-summary.js</include> @@ -354,6 +368,7 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/counters/nf-counters.js</include> <include>${staging.dir}/js/nf/counters/nf-counters-table.js</include> </includes> @@ -365,6 +380,7 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/templates/nf-templates.js</include> <include>${staging.dir}/js/nf/templates/nf-templates-table.js</include> </includes> @@ -376,6 +392,7 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/cluster/nf-cluster.js</include> <include>${staging.dir}/js/nf/cluster/nf-cluster-table.js</include> </includes> @@ -387,6 +404,7 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/users/nf-users.js</include> <include>${staging.dir}/js/nf/users/nf-users-table.js</include> </includes> @@ -398,11 +416,23 @@ <include>${staging.dir}/js/nf/nf-client.js</include> <include>${staging.dir}/js/nf/nf-common.js</include> <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> <include>${staging.dir}/js/nf/bulletin-board/nf-bulletin-board.js</include> </includes> </aggregation> <aggregation> <insertNewLine>true</insertNewLine> + <output>${project.build.directory}/${project.build.finalName}/js/nf/login/nf-login-all.js</output> + <includes> + <include>${staging.dir}/js/nf/nf-client.js</include> + <include>${staging.dir}/js/nf/nf-common.js</include> + <include>${staging.dir}/js/nf/nf-dialog.js</include> + <include>${staging.dir}/js/nf/nf-storage.js</include> + <include>${staging.dir}/js/nf/login/nf-login.js</include> + </includes> + </aggregation> + <aggregation> + <insertNewLine>true</insertNewLine> <output>${project.build.directory}/${project.build.finalName}/css/nf-canvas-all.css</output> <includes> <include>${staging.dir}/css/reporting-task.css</include> @@ -418,7 +448,6 @@ <include>${staging.dir}/css/connection-configuration.css</include> <include>${staging.dir}/css/connection-details.css</include> <include>${staging.dir}/css/shell.css</include> - <include>${staging.dir}/css/registration.css</include> <include>${staging.dir}/css/dialog.css</include> <include>${staging.dir}/css/new-processor-dialog.css</include> <include>${staging.dir}/css/new-controller-service-dialog.css</include> @@ -517,6 +546,16 @@ <include>${staging.dir}/css/bulletin-board.css</include> </includes> </aggregation> + <aggregation> + <insertNewLine>true</insertNewLine> + <output>${project.build.directory}/${project.build.finalName}/css/nf-login-all.css</output> + <includes> + <include>${staging.dir}/css/main.css</include> + <include>${staging.dir}/css/banner.css</include> + <include>${staging.dir}/css/dialog.css</include> + <include>${staging.dir}/css/login.css</include> + </includes> + </aggregation> </aggregations> </configuration> </execution> @@ -556,6 +595,8 @@ css/nf-users-all.css.gz, css/nf-bulletin-board-all.css, css/nf-bulletin-board-all.css.gz, + css/nf-login-all.css, + css/nf-login-all.css.gz, js/*, js/d3/**/*, js/codemirror/**/*, @@ -584,6 +625,8 @@ js/nf/users/nf-users-all.js.gz, js/nf/bulletin-board/nf-bulletin-board-all.js, js/nf/bulletin-board/nf-bulletin-board-all.js.gz, + js/nf/login/nf-login-all.js, + js/nf/login/nf-login-all.js.gz, images/*, resources/*, images/*, @@ -615,7 +658,6 @@ the application classpath or the maven jetty plugin classpath defined above. --> - <dependency> <groupId>commons-io</groupId> <artifactId>commons-io</artifactId> @@ -651,6 +693,5 @@ <artifactId>javax.servlet.jsp.jstl-api</artifactId> <scope>provided</scope> </dependency> - </dependencies> </project> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/META-INF/LICENSE ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/META-INF/LICENSE b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/META-INF/LICENSE index 40d0725..6769105 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/META-INF/LICENSE +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/META-INF/LICENSE @@ -351,6 +351,28 @@ For details see http://jqueryui.com OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +This product bundles 'jquery.base64.js' which is available under an MIT style license. + + Copyright (c) 2013 Yannick Albert (http://yckart.com/) + + Permission is hereby granted, free of charge, to any person obtaining + a copy of this software and associated documentation files (the "Software"), + to deal in the Software without restriction, including without limitation + the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be + included in all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE + LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION + OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION + WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + This product bundles 'SlickGrid v2.2' which is available under an MIT style license. Copyright (c) 2010 Michael Leibman, http://github.com/mleibman/slickgrid http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/bulletin-board.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/bulletin-board.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/bulletin-board.properties index 55df244..96a550f 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/bulletin-board.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/bulletin-board.properties @@ -16,6 +16,7 @@ nf.bulletin.board.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/bulletin-board/nf-bulletin-board.js?${project.version}"></script> nf.bulletin.board.style.tags=<link rel="stylesheet" href="css/reset.css?${project.version}" type="text/css" />\n\ <link rel="stylesheet" href="css/main.css?${project.version}" type="text/css" />\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/canvas.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/canvas.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/canvas.properties index fd2bc17..bf61846 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/canvas.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/canvas.properties @@ -19,11 +19,10 @@ nf.canvas.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js? <script type="text/javascript" src="js/nf/canvas/nf-canvas-utils.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-shell.js?${project.version}"></script>\n\ -<script type="text/javascript" src="js/nf/canvas/nf-storage.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/canvas/nf-snippet.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/canvas/nf-canvas-toolbox.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/canvas/nf-custom-ui.js?${project.version}"></script>\n\ -<script type="text/javascript" src="js/nf/canvas/nf-registration.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/canvas/nf-controller-service.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/canvas/nf-reporting-task.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/canvas/nf-processor-configuration.js?${project.version}"></script>\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/cluster.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/cluster.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/cluster.properties index f1481d8..9327be6 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/cluster.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/cluster.properties @@ -16,6 +16,7 @@ nf.cluster.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/cluster/nf-cluster.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/cluster/nf-cluster-table.js?${project.version}"></script> nf.cluster.style.tags=<link rel="stylesheet" href="css/reset.css?${project.version}" type="text/css" />\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/counters.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/counters.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/counters.properties index 8b07e57..be22f55 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/counters.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/counters.properties @@ -16,6 +16,7 @@ nf.counters.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/counters/nf-counters.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/counters/nf-counters-table.js?${project.version}"></script> nf.counters.style.tags=<link rel="stylesheet" href="css/reset.css?${project.version}" type="text/css" />\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/history.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/history.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/history.properties index 818ee58..9bbe640 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/history.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/history.properties @@ -16,6 +16,7 @@ nf.history.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/history/nf-history.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/history/nf-history-table.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/history/nf-history-model.js?${project.version}"></script> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login-min.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login-min.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login-min.properties new file mode 100644 index 0000000..4dafb02 --- /dev/null +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login-min.properties @@ -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. + +nf.login.script.tags=<script type="text/javascript" src="js/nf/login/nf-login-all.js?${project.version}"></script> +nf.login.style.tags=<link rel="stylesheet" href="css/nf-login-all.css?${project.version}" type="text/css" />\n\ +<link rel="stylesheet" href="css/message-pane.css?${project.version}" type="text/css" /> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login.properties new file mode 100644 index 0000000..28ff4b9 --- /dev/null +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/login.properties @@ -0,0 +1,25 @@ +# 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. + +nf.login.script.tags=<script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/login/nf-login.js?${project.version}"></script> +nf.login.style.tags=<link rel="stylesheet" href="css/reset.css?${project.version}" type="text/css" />\n\ +<link rel="stylesheet" href="css/main.css?${project.version}" type="text/css" />\n\ +<link rel="stylesheet" href="css/banner.css?${project.version}" type="text/css" />\n\ +<link rel="stylesheet" href="css/dialog.css?${project.version}" type="text/css" />\n\ +<link rel="stylesheet" href="css/message-pane.css?${project.version}" type="text/css" />\n\ +<link rel="stylesheet" href="css/login.css?${project.version}" type="text/css" /> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/provenance.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/provenance.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/provenance.properties index 655d3bf..daa7c43 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/provenance.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/provenance.properties @@ -16,6 +16,7 @@ nf.provenance.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/provenance/nf-provenance.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/provenance/nf-provenance-table.js?${project.version}"></script> nf.provenance.style.tags=<link rel="stylesheet" href="css/reset.css?${project.version}" type="text/css" />\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/summary.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/summary.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/summary.properties index 90d35d9..2417ade 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/summary.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/summary.properties @@ -16,6 +16,7 @@ nf.summary.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-processor-details.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-connection-details.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/summary/nf-summary.js?${project.version}"></script>\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/templates.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/templates.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/templates.properties index 79c59e7..007bd69 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/templates.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/templates.properties @@ -16,6 +16,7 @@ nf.templates.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/templates/nf-templates.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/templates/nf-templates-table.js?${project.version}"></script> nf.templates.style.tags=<link rel="stylesheet" href="css/reset.css?${project.version}" type="text/css" />\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/users.properties ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/users.properties b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/users.properties index a4e586a..9824a8b 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/users.properties +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/resources/filters/users.properties @@ -16,6 +16,7 @@ nf.users.script.tags=<script type="text/javascript" src="js/nf/nf-namespace.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-common.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/nf-dialog.js?${project.version}"></script>\n\ +<script type="text/javascript" src="js/nf/nf-storage.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/users/nf-users.js?${project.version}"></script>\n\ <script type="text/javascript" src="js/nf/users/nf-users-table.js?${project.version}"></script> nf.users.style.tags=<link rel="stylesheet" href="css/reset.css?${project.version}" type="text/css" />\n\ http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/bulletin-board.jsp ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/bulletin-board.jsp b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/bulletin-board.jsp index 6df0e51..3eaa225 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/bulletin-board.jsp +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/bulletin-board.jsp @@ -28,6 +28,7 @@ <link rel="stylesheet" href="js/jquery/qtip2/jquery.qtip.min.css?" type="text/css" /> <link rel="stylesheet" href="js/jquery/ui-smoothness/jquery-ui-1.10.4.min.css" type="text/css" /> <script type="text/javascript" src="js/jquery/jquery-2.1.1.min.js"></script> + <script type="text/javascript" src="js/jquery/jquery.base64.js"></script> <script type="text/javascript" src="js/jquery/jquery.center.js"></script> <script type="text/javascript" src="js/jquery/combo/jquery.combo.js?${project.version}"></script> <script type="text/javascript" src="js/jquery/modal/jquery.modal.js?${project.version}"></script> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/canvas.jsp ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/canvas.jsp b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/canvas.jsp index 1bf63a6..f9970df 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/canvas.jsp +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/canvas.jsp @@ -40,8 +40,8 @@ <script type="text/javascript" src="js/codemirror/lib/codemirror-compressed.js"></script> <script type="text/javascript" src="js/jquery/jquery-2.1.1.min.js"></script> <script type="text/javascript" src="js/jquery/ui-smoothness/jquery-ui-1.10.4.min.js"></script> + <script type="text/javascript" src="js/jquery/jquery.base64.js"></script> <script type="text/javascript" src="js/jquery/jquery.center.js"></script> - <script type="text/javascript" src="js/jquery/jquery.count.js"></script> <script type="text/javascript" src="js/jquery/jquery.ellipsis.js"></script> <script type="text/javascript" src="js/jquery/jquery.each.js"></script> <script type="text/javascript" src="js/jquery/jquery.tab.js"></script> @@ -73,7 +73,6 @@ <img id="splash-img" src="images/loadAnimation.gif" alt="Loading..."/> </div> <jsp:include page="/WEB-INF/partials/message-pane.jsp"/> - <jsp:include page="/WEB-INF/partials/canvas/registration.jsp"/> <jsp:include page="/WEB-INF/partials/banners-main.jsp"/> <jsp:include page="/WEB-INF/partials/canvas/canvas-header.jsp"/> <jsp:include page="/WEB-INF/partials/canvas/about-dialog.jsp"/> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/cluster.jsp ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/cluster.jsp b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/cluster.jsp index 55ffabe..acf2e55 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/cluster.jsp +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/cluster.jsp @@ -30,6 +30,7 @@ <link rel="stylesheet" href="js/jquery/slickgrid/css/slick.grid.css" type="text/css" /> <link rel="stylesheet" href="js/jquery/slickgrid/css/slick-default-theme.css" type="text/css" /> <script type="text/javascript" src="js/jquery/jquery-2.1.1.min.js"></script> + <script type="text/javascript" src="js/jquery/jquery.base64.js"></script> <script type="text/javascript" src="js/jquery/jquery.center.js"></script> <script type="text/javascript" src="js/jquery/combo/jquery.combo.js?${project.version}"></script> <script type="text/javascript" src="js/jquery/modal/jquery.modal.js?${project.version}"></script> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/counters.jsp ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/counters.jsp b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/counters.jsp index 7362cf2..e3113f9 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/counters.jsp +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/counters.jsp @@ -30,6 +30,7 @@ <link rel="stylesheet" href="js/jquery/slickgrid/css/slick.grid.css" type="text/css" /> <link rel="stylesheet" href="js/jquery/slickgrid/css/slick-default-theme.css" type="text/css" /> <script type="text/javascript" src="js/jquery/jquery-2.1.1.min.js"></script> + <script type="text/javascript" src="js/jquery/jquery.base64.js"></script> <script type="text/javascript" src="js/jquery/jquery.center.js"></script> <script type="text/javascript" src="js/jquery/combo/jquery.combo.js?${project.version}"></script> <script type="text/javascript" src="js/jquery/modal/jquery.modal.js?${project.version}"></script> http://git-wip-us.apache.org/repos/asf/nifi/blob/aaf14c45/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/history.jsp ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/history.jsp b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/history.jsp index 935512a..ac28bb7 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/history.jsp +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/pages/history.jsp @@ -30,6 +30,7 @@ <link rel="stylesheet" href="js/jquery/slickgrid/css/slick.grid.css" type="text/css" /> <link rel="stylesheet" href="js/jquery/slickgrid/css/slick-default-theme.css" type="text/css" /> <script type="text/javascript" src="js/jquery/jquery-2.1.1.min.js"></script> + <script type="text/javascript" src="js/jquery/jquery.base64.js"></script> <script type="text/javascript" src="js/jquery/jquery.center.js"></script> <script type="text/javascript" src="js/jquery/modal/jquery.modal.js?${project.version}"></script> <script type="text/javascript" src="js/jquery/combo/jquery.combo.js?${project.version}"></script>