Bug 178201 - New telnet subsystem added to target management
Summary: New telnet subsystem added to target management
Status: RESOLVED FIXED
Alias: None
Product: Target Management
Classification: Tools
Component: RSE (show other bugs)
Version: 2.0   Edit
Hardware: All All
: P2 enhancement (vote)
Target Milestone: 2.0   Edit
Assignee: Martin Oberhuber CLA
QA Contact: Martin Oberhuber CLA
URL:
Whiteboard:
Keywords: contributed
Depends on:
Blocks: 186536 186564 186568 186570 187301
  Show dependency tree
 
Reported: 2007-03-20 05:02 EDT by Sheldon CLA
Modified: 2011-05-25 10:10 EDT (History)
0 users

See Also:


Attachments
This contains the source for telnet enhancement (22.14 KB, patch)
2007-03-20 05:05 EDT, Sheldon CLA
no flags Details | Diff
the telnet plugin source for RSE (22.14 KB, application/zip)
2007-03-20 05:09 EDT, Sheldon CLA
no flags Details
Cleaned up telnet contribution v2 (34.69 KB, application/x-zip-compressed)
2007-03-20 11:43 EDT, Martin Oberhuber CLA
no flags Details
modification to the telnet source as per request (39.89 KB, application/zip)
2007-03-21 07:16 EDT, Sheldon CLA
no flags Details
Modification for Copyright headers (42.14 KB, application/zip)
2007-03-21 09:42 EDT, Sheldon CLA
mober.at+eclipse: iplog+
Details
Cleaned up telnet contribution v5 (41.95 KB, application/x-zip-compressed)
2007-03-21 12:41 EDT, Martin Oberhuber CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sheldon CLA 2007-03-20 05:02:40 EDT
The current TM source supports protocols like SSH, FTP, but there is no support for Telnet. The following plugins provide the functionality for telnet protocol. Its implemented using the jakarta.commons.net library. The telnet subsystem uses the existing FTP file subsystem.
Comment 1 Sheldon CLA 2007-03-20 05:05:48 EDT
Created attachment 61365 [details]
This contains the source for telnet enhancement

This attachment contains the source i have written as an enhancement to RSE, it supports the telnet protocol which currently doesnot exist in RSE
Comment 2 Sheldon CLA 2007-03-20 05:09:13 EDT
Created attachment 61366 [details]
the telnet plugin source for RSE

This attachment contains the source i have written as an enhancement to RSE, it
supports the telnet protocol which currently doesnot exist in RSE
Comment 3 Martin Oberhuber CLA 2007-03-20 11:43:23 EDT
Created attachment 61408 [details]
Cleaned up telnet contribution v2

Cleaned-up contribution:
* Added missing .project, .classpath, .settings, about.html, build.properties
* Added missing plugin.xml file, plugin.properties
* Added missing icons/ directory
* Specified J2SE-1.4 Execution Environment; Removed Java5 @Override annotation
* Organized imports, updated code to RSE HEAD for ConnectorService
* Removed unused org.eclipse.rse.subsystems.files.telnet plugin
* Removed obsolete jsch dependency
* Externalized Strings from Manifest, added 1.0.0.qualifier version
* Added some //$NON-NLS-1$ comments

There is still more work to do
Comment 4 Martin Oberhuber CLA 2007-03-20 11:48:45 EDT
First of all, thanks for this contribution. On the DSDP PMC's behalf, I'll be
happy to accept it once a few additional tasks are completed - see below.

I looked at this contribution, and over all it looks OK but there are some necessary cleanup tasks you must do before I can pass this to the Eclipse Foundation's Legal review:

1. We need a clear statement that you are contributing this under EPL.
   This statement can be entered as a comment here on bugzilla.

2. You MUST add copyright headers to ALL the source files. Quite apparently, 
   you copied most of the code from the RSE SSH plugins -- there are still some
   traces to SSH e.g. in TelnetServiceResources.java.
   Whenever you copy EPL'd code you MUST keep the original Copyright headers, 
   adding yourself on the "Contributors" list. Whenever you created new 
   headers, you MUST add your own copyright header.

3. Two files are missing and need to be added: 
      TelnetConnectorServiceResources.properties
      TelnetServiceResources.properties

Please base your additional work on this on the "Cleaned up telnet contribution v2" attachment I made.

Thanks!
Comment 5 Martin Oberhuber CLA 2007-03-20 11:50:17 EDT
When exporting your modified plugins, please do as follows:
1. Select the plugins to export
2. File > Export > General > Archive File
3. For each plugin to export, make sure it is checked; then, expand its node
   and deselect the "bin" folder below it.
4. Export into a ZIP archive.
Comment 6 Sheldon CLA 2007-03-21 04:40:42 EDT
I am contributing this source under the EPL license to be used as part of the DSDP TM project.
Comment 7 Martin Oberhuber CLA 2007-03-21 05:41:38 EDT
(In reply to comment #6)
Thanks for contributing this under the EPL. Before I can proceed, there is more questions I need to ask - please answer by commenting here on Bugzilla:

    * Did you write the contribution yourself?
    * Did you reference any 3rd party material?
    * If yes, under what terms (license) did you receive this material?
    * Are you authorized by your employer to make the contribution?

I know you referenced the RSE ssh plugin which is under EPL, so questions 2 and 3 above are about any other material you might have referenced. For a single sample answer to all of these, see
http://www.eclipse.org/dsdp/tm/development/committer_howto.php#external_contrib

When this is done, you'll need to add the missing copyright headers to the source files, and the two missing .properties files, then we can proceed.

Thanks!
Comment 8 Sheldon CLA 2007-03-21 07:16:22 EDT
Created attachment 61521 [details]
modification to the telnet source as per request

modification to the telnet source 
Copright headers attached
Comment 9 Martin Oberhuber CLA 2007-03-21 07:32:22 EDT
Thanks for adding back the Copyright headers, but this is neither sufficient nor correct. 

For instance, in TelnetShellService, you added a copyright header stating Wind River as Copyright owner. But this is not correct, since you apparently copied from SshShellService, which was created from LocalShellService, which is Copyright by IBM. The SshShellService copyright header told you that.

You are messing up the ancestor information and pedigree of the code, which is not compliant with the license, and I thus cannot possibly accept it.

You MUST, for each source file that you contribute, go back to the original source where you contributed from, take the original copyright header from there, and do the following:
 - add yourself as modifier together with the kind of modification you made.
 - if "..and others" is not yet in the first line, add it
 - if the copyright-to year is not 2007, change it e.g. 2005, 2007
This may be tedious, but only because you removed the original copyright headers. It would have been better to keep them in place when you took the original code and modified it. In fact you should NEVER remove copyright headers when taking code from Open Source and modifying it -- many licenses actually REQUIRE you to always keep copyright headers intact or you are not allowed to work with the code.

For example, I believe that the header of TelnetShellService should look like this:

/**************************************************************************
 * Copyright (c) 2006, 2007 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Initial Contributors:
 * The following IBM employees contributed to the Remote System Explorer
 * component that contains this file: David McKnight, Kushal Munir, 
 * Michael Berger, David Dykstal, Phil Coulthard, Don Yantzi, Eric Simpson, 
 * Emily Bruner, Mazen Faraj, Adrian Storisteanu, Li Ding, and Kent Hawley.
 * 
 * Contributors:
 * Martin Oberhuber (Wind River) - Adapted from LocalShellService.
 * Sheldon Dsouza (Celunite) - Adapted from SshShellService.
 **************************************************************************/
Comment 10 Martin Oberhuber CLA 2007-03-21 07:33:10 EDT
Comment on attachment 61521 [details]
modification to the telnet source as per request

Marking attachment as invalid since it contains incorrect copyright headers, giving wrong companies credit or missing ancestor information.
Comment 11 Sheldon CLA 2007-03-21 07:42:25 EDT
I, Sheldon Dsouza, declare that I developed attached code using  jakarta.commons.net api for the Telnet implementation and material licensed under the EPL. {I am authorized by my employer to make this contribution under the EPL.}
Comment 12 Sheldon CLA 2007-03-21 09:42:13 EDT
Created attachment 61538 [details]
Modification for Copyright headers

made the necessary modification for the copyright headers
Comment 13 Martin Oberhuber CLA 2007-03-21 12:41:38 EDT
Created attachment 61566 [details]
Cleaned up telnet contribution v5

(In reply to comment #12)
Thanks. This looks really good now already.

I made some more minor cleanups, please verify that you are ok with these:
- The worst one was that your connectorservice.telnet/Activator was 
  apparently a copy of connectorservice.ssh/Activator, since it contained 
  my tracing code, but you had not given me credit in the Copyright header.
  Fixed it -- PLEASE ensure proper use of copyright headers in the future
- Copyright comments - removed spaces around ( Celunite )
- Copyright comments - made consistent use of "Celunite, Inc. and others."
- Copyright comments - fixed to-year ,2007 on TelnetServiceResources
- Copyright comments - added "and others" on TelnetShellWriterThread
- Copyright comments - made consistent use of contributor on new files:
     * Sheldon D'souza (Celunite) - initial API and implementation
- Added missing connectorservice.telnet/.options file for tracing
- Removed obsolete references to FTP externalized strings
- Replaced obsolete references to Ssh on Tracing code and Activator comment
- Changed System.out.println() into trace() in order to do it for debugging
  only; otherwise, plaintext passwords would have been printed

In my opinion, the code is good for submitting to Eclipse Legal Review now. I can submit it as soon as I get your OK that this is what you want.

There are still functional problems which can be adressed later by patches:
1. TelnetConnectorService needs to set arm_flag=false for Open Source,
   or - better yet - come up with a generic solution for handling different
   kinds of prompts, i.e. make them user configurable
2. TelnetConnectorService runs internalConnect() in the dispatch thread,
   so the whole UI freezes up when the server does not respond as expected
   i.e. with arm_flag=true, trying to connect a UNIX server freezes up all
   of Eclipse

More issues may be detected later, but as I said these can be fixed later with
patches which won't require full Eclipse Legal Review.
Comment 14 Sheldon CLA 2007-03-21 15:16:32 EDT
Ok its fine with me, you can go ahead and submit the code for eclipse legal review. 
Comment 15 Martin Oberhuber CLA 2007-03-21 17:24:42 EDT
Submitted to Eclipse Legal Review,
https://dev.eclipse.org/ipzilla/show_bug.cgi?id=1393
Comment 16 Martin Oberhuber CLA 2007-05-10 05:16:26 EDT
EMO Legal Review accepted the contribution. Scheduling for addition to RSE.
Comment 17 Martin Oberhuber CLA 2007-05-11 11:06:37 EDT
Telnet contribution committed to CVS, added to features, mapfiles, nightly builds and download page. ISV Docs updated to reference the public package.

Verified in N20070511-0818 that the Telnet feature is properly there, with all aboutfiles and other license and feature stuff. Tested that it basically works in the N-build and source plugins are correctly available in the SDK.

I labelled the runtime download as "Experimental" for now since there are still two major bugs to sort out before I consider this ready for general consumption:
  Bug #186564 - Multiple telnet connections influence each other
  Bug #186570 - Telnet should handle invalid user id more gracefully

If these can not be resolved in time for 2.0, I'd disable the contribution in the Runtime and SDK by commenting out the subsystemConfigurations extension point, thus making the contribution installed but unavailable unless an extender writes his own extension point.

Marking the contribution itself as FIXED though since the bugs mentioned will be tracked separately.

Thanks again for this great contribution!
Comment 18 Martin Oberhuber CLA 2008-08-13 13:18:28 EDT
[target cleanup] 2.0 M7 was the original target milestone for this bug
Comment 19 Martin Oberhuber CLA 2011-05-25 10:10:52 EDT
Comment on attachment 61538 [details]
Modification for Copyright headers

Contribution ended up being used.