clerezza-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@apache.org
Subject [3/5] git commit: CLEREZZA-918: key stored in user dir and update ssh version to the latest version not cause AccessControlException
Date Mon, 19 May 2014 13:10:46 GMT
CLEREZZA-918: key stored in user dir and update ssh version to the latest version not cause
AccessControlException


Project: http://git-wip-us.apache.org/repos/asf/clerezza/repo
Commit: http://git-wip-us.apache.org/repos/asf/clerezza/commit/89e83af0
Tree: http://git-wip-us.apache.org/repos/asf/clerezza/tree/89e83af0
Diff: http://git-wip-us.apache.org/repos/asf/clerezza/diff/89e83af0

Branch: refs/heads/master
Commit: 89e83af0c8bc5ad4512c64f9d4dd4d1092491f02
Parents: 1fa81e8
Author: Reto Bachmann-Gmür <reto@apache.org>
Authored: Mon May 19 15:05:54 2014 +0200
Committer: Reto Bachmann-Gmür <reto@apache.org>
Committed: Mon May 19 15:05:54 2014 +0200

----------------------------------------------------------------------
 parent/pom.xml                                  |  7 +-
 platform.launcher.tdb/nbactions.xml             |  5 +-
 provisioning/security/pom.xml                   | 80 ++++++++++++++++++++
 sshshell/pom.xml                                |  2 -
 .../org/apache/clerezza/sshshell/SshShell.java  | 11 ++-
 5 files changed, 97 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/clerezza/blob/89e83af0/parent/pom.xml
----------------------------------------------------------------------
diff --git a/parent/pom.xml b/parent/pom.xml
index 5a2a7f1..9859a60 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -525,19 +525,18 @@
             <dependency>
                 <groupId>org.apache.mina</groupId>
                 <artifactId>mina-core</artifactId>
-                <version>2.0.3</version>
+                <version>2.0.7</version>
             </dependency>
             <dependency>
                 <groupId>org.apache.sshd</groupId>
                 <artifactId>sshd-core</artifactId>
-                <version>0.5.0</version>
+                <version>0.8.0</version>
             </dependency>
             <dependency>
                 <groupId>org.apache.sshd</groupId>
                 <artifactId>sshd-pam</artifactId>
-                <version>0.5.0</version>
+                <version>0.8.0</version>
             </dependency>
-            
             <dependency>
                 <groupId>org.jsslutils</groupId>
                 <artifactId>jsslutils</artifactId>

http://git-wip-us.apache.org/repos/asf/clerezza/blob/89e83af0/platform.launcher.tdb/nbactions.xml
----------------------------------------------------------------------
diff --git a/platform.launcher.tdb/nbactions.xml b/platform.launcher.tdb/nbactions.xml
index 5a222ce..3fc4ab5 100644
--- a/platform.launcher.tdb/nbactions.xml
+++ b/platform.launcher.tdb/nbactions.xml
@@ -8,6 +8,9 @@
             <goal>antrun:run</goal>
             <goal>-o</goal>
         </goals>
+        <properties>
+            <vm.args>-Dclerezza.shell.disable=true</vm.args>
+        </properties>
     </action>
     <action>
         <actionName>debug</actionName>
@@ -18,7 +21,7 @@
             <goal>-o</goal>
         </goals>
         <properties>
-            <vm.args>-Xdebug -Xrunjdwp:transport=dt_socket,server=n,address=${jpda.address}</vm.args>
+            <vm.args>-Xdebug -Xrunjdwp:transport=dt_socket,server=n,address=${jpda.address}
-Dclerezza.shell.disable=true</vm.args>
             <jpda.listen>true</jpda.listen>
         </properties>
     </action>

http://git-wip-us.apache.org/repos/asf/clerezza/blob/89e83af0/provisioning/security/pom.xml
----------------------------------------------------------------------
diff --git a/provisioning/security/pom.xml b/provisioning/security/pom.xml
new file mode 100644
index 0000000..9ab4eda
--- /dev/null
+++ b/provisioning/security/pom.xml
@@ -0,0 +1,80 @@
+<?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.
+
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" 
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <artifactId>clerezza</artifactId>
+        <groupId>org.apache.clerezza</groupId>
+        <version>0.5-SNAPSHOT</version>
+        <relativePath>../../parent</relativePath>
+    </parent>
+
+    <groupId>org.apache.clerezza.provisioning</groupId>
+    <artifactId>security</artifactId>
+    <version>0.1-SNAPSHOT</version>
+    <packaging>feature</packaging>
+
+    <name>Clerezza - Provisioning - Security</name>
+    <description>Clerezza - Provisioning: What's needed for authentication and user
manager. 
+        </description>
+
+    <dependencies>
+        
+      
+        <dependency>
+            <groupId>org.apache.stanbol</groupId>
+            <artifactId>org.apache.stanbol.commons.security.core</artifactId>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.clerezza</groupId>
+            <artifactId>platform.usermanager</artifactId>
+            <version>0.14-SNAPSHOT</version>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.clerezza</groupId>
+            <artifactId>platform.usermanager.webinterface</artifactId>
+            <version>0.14-SNAPSHOT</version>
+        </dependency>
+        
+        <dependency> 
+            <groupId>org.apache.clerezza</groupId>
+            <artifactId>permissiondescriptions</artifactId>
+            <version>0.2-SNAPSHOT</version>
+        </dependency>
+        
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.wymiwyg.karaf.tooling</groupId>
+                <artifactId>karaf-sling-maven-plugin</artifactId>
+            </plugin>
+        </plugins>
+    </build>
+    
+</project>

http://git-wip-us.apache.org/repos/asf/clerezza/blob/89e83af0/sshshell/pom.xml
----------------------------------------------------------------------
diff --git a/sshshell/pom.xml b/sshshell/pom.xml
index 5a9ac95..d683933 100644
--- a/sshshell/pom.xml
+++ b/sshshell/pom.xml
@@ -40,12 +40,10 @@
         <dependency>
             <groupId>org.apache.sshd</groupId>
             <artifactId>sshd-core</artifactId>
-            <version>0.5.0</version>
         </dependency>
         <dependency>
             <groupId>org.apache.sshd</groupId>
             <artifactId>sshd-pam</artifactId>
-            <version>0.5.0</version>
         </dependency>
         <dependency>
             <groupId>org.slf4j</groupId>

http://git-wip-us.apache.org/repos/asf/clerezza/blob/89e83af0/sshshell/src/main/java/org/apache/clerezza/sshshell/SshShell.java
----------------------------------------------------------------------
diff --git a/sshshell/src/main/java/org/apache/clerezza/sshshell/SshShell.java b/sshshell/src/main/java/org/apache/clerezza/sshshell/SshShell.java
index f9acbc3..a06d3ad 100644
--- a/sshshell/src/main/java/org/apache/clerezza/sshshell/SshShell.java
+++ b/sshshell/src/main/java/org/apache/clerezza/sshshell/SshShell.java
@@ -20,6 +20,7 @@ package org.apache.clerezza.sshshell;
  *
 */
 
+import java.io.File;
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.OutputStream;
@@ -64,7 +65,15 @@ public class SshShell {
 
     public SshShell() {
         sshd = SshServer.setUpDefaultServer();
-        sshd.setKeyPairProvider(new SimpleGeneratorHostKeyProvider("hostkey.ser"));
+        File clerezzaUserConfigDir = new File(new File(System.getProperty("user.home")),
".clerezza");
+        if (!clerezzaUserConfigDir.exists()) {
+            clerezzaUserConfigDir.mkdir();
+        }
+        File hostKeyDir = new File(clerezzaUserConfigDir, "ssh");
+        if (!hostKeyDir.exists()) {
+            hostKeyDir.mkdir();
+        }
+        sshd.setKeyPairProvider(new SimpleGeneratorHostKeyProvider(new File(hostKeyDir,"hostkey.ser").getAbsolutePath()));
         sshd.setPasswordAuthenticator(new MyPasswordAuthenticator());
     }
 


Mime
View raw message