8000 Connection Manager by davidrg · Pull Request #471 · davidrg/ckwin · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Connection Manager #471

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 62 commits into
base: master
Choose a base branch
from
Draft

Connection Manager #471

wants to merge 62 commits into from

Conversation

davidrg
Copy link
Owner
@davidrg davidrg commented Jun 5, 2025

This is a longer-term project to build a replacement for the K95 dialer which suffers from a number of problems due to the 3rd-party toolkit (zinc) it was built with and its current maintenance status:

  • Not suitable for building with Visual C++ 2002 or newer due to reliance on ctl3d32 for proper "modern" appearance
  • Not compatible with recent Visual C++ releases (and so can't be built for ARM), likely can't be built for IA64 either and may be 64bit-incompatible in general
  • UI resources stored in binary files that must be shipped with the application making them difficult to version control and update

The main advantage of Zinc was portability to OS/2, but its not clear that K95 has any users on OS/2 at this point and at any rate Zinc is less of an issue there. So the old Dialer will remain for OS/2, while its new replacement will be built exclusively for Windows with the following goals:

  • Support for most Windows platforms where K95 currently runs:
    • Windows 95/98/ME
    • Windows NT 3.51 or newer on all CPU architectures
  • Compatible with Visual C++ 4.0 or newer, and ideally Open Watcom and GCC
  • 32bit or 64bit
  • Unicode or ANSI
  • Native look and feel
  • Support for modern shell features such as Jumplists
  • Minimal 3rd-party dependencies for easier long-term maintenance. At this stage just a JSON library.

Right now my primary goal is getting Kermit 95 v3.0 stable out the door. I don't want to delay v3.0 just so that it can include a replacement for the dialer; its already been in development for three years and counting. So for now work on the connection manager is highly intermittent as it isn't a priority right now. Once K95 v3.0 is out (or at least reaches the release candidate stage) then finishing this off will probably be near the top of the priority list.

General requirements look somethig like the following - once all this is done, then perhaps some kind of beta test can happen:

  • Basic GUI stubbed out
  • Toolbar icons
  • App icon
  • Initial storage layer implemented
  • Support multiple configuration levels (app, system, user)
  • Ability to create new connection profiles
  • Delete connection profile
  • Connection properites
    • General
    • Connection - SSH
    • Connection - Serial
    • Connection - IP
    • Connection - RFC2217
    • Telnet protocol options (option negotiation, environment variables, etc)
    • SSH (algorithms, forwarding, etc)
    • FTP (algorithms, encryption, etc)
    • TCP/IP (proxy server, etc)
    • Terminal
    • Terminal Colors
    • Keyboard
    • Mouse
    • File Transfer
    • GUI
    • Colors
    • Login
    • Printer
    • TLS (certificates, etc)
    • Kerberos
    • Logging
  • Script generation
  • Keep script up-to-date on profile change?
  • Create shortcut
  • Make connections
  • Minimise on connect option
  • Track K-95 instances launched by the connection manager
  • Terminate connections
  • Jumplist support
  • Github CI
  • Create Connection Profile Template
  • Create Connection Profile from Template
  • Clone Connection Profile
  • Quick Connect
    • Initiated from the Connection Manager
    • Initiated from K-95
    • Duplicate session?
  • TAPI serial ports
  • Modem definitions
  • Modem connections
  • Network Directories
  • Dialing Directories
  • SKermit connection type?
  • Compatibility
    • Windows 95
    • NT 3.51
    • NT4
    • Alpha
    • Alpha64
    • MIPS
    • PowerPC
    • IA64
    • ARM
    • ARM64
    • x86-64
    • Open Watcom
    • MinGW
  • Dialer to Connection Manager data migration process
  • Option to use either CM or Dialer
  • Startup options (eg, don't load kerberos, etc)
  • Documentation
    • Help file (HLP or CHM)
    • Context-help
    • Rework the K95 manual to cover both the Connection Manager and the Dialer
  • See if Windows 11 UI styling can be easily supported
  • Evaluate storage options to see if there is anything more suitable than JSON

I've been working on this for the past week (since Friday 1 September) in Visual C++ 4.0 Professional.

Current status: Can create a connection, edit its general properties, start a connection, monitor its status and terminate it.

Not done: Most of the properties dialog tabs, some toolbar buttons and their icons, some menu items, cloning profiles, templates and some other things
Visual C++ 5.0 found this. Surprised Visual C++ 4.0 didn't care - it was totally wrong!
So that newer versions don't interfere with it
After a week in late 1995, its time to move into 1997!
Both specific to unicode builds: buffer length was being given to the string copy, rather than number of characters.

Number of characters was being given to malloc rather than the size of the buffer required.

Also: deleting something malloc'd rather than freeing it.
The caller is responsible for freeing the string returned by CMString::toUtf8()
Or at least the important part - loading and saving the config.

It update the config (eg, 7/8bit) based on selected terminal type yet.
Some terminals should default to a particular character set, or character size, etc.

Settings mostly match what the K95 Dialer did. Only changes are: Added ADM-5 and VTNT, Changed Linux defaults (now utf-8, no status line, light gray on black)
New in the connection manager: a button to set colours to defaults based on selected terminal type.

The K95 Dialer set colours based on terminal type automatically whenever you selected a terminal
With two changes from the dialer:
 * We don't give the prompt option due to it being not much more secure than saving a password, and the difficulty of explaining this to the user in the space available
 * The selected login script files contents is not displayed in the script field - too much work loading the file and handling any file encoding issues (unicode builds would need to translate an ASCII or UTF-8 file to UTF-16LE on load) all to display it in a text box thats really too small to be useful. The user is better off just looking at the file in a real text editor if they want to.
(connection manager config files)
The connection tab for all connection types is now done.
The list should now update
Looks better on classic windows, and *much* better on modern windows.
With these two changes the code is compatible with Visual C++ 2022 32bit community edition - though there are plenty of warnings that need to be dealt with
davidrg added 23 commits May 23, 2025 22:22
While it doesn't look as nice at this larger size and its size compared to the main window is a bit off, a couple of the tabs (printer and file transfer especially) were really too cramped at the more compact size and most tabs weren't going to fit any extra settings at all on them, so this really had to be done.

With the extra space now available on the Terminal tab, the terminal type box has been enlarged and it now shows friendly names rather than terminal type keywords.
This comes with color theme support in the storage layer with a handful of default themes defined. No GUI for creating or editing color themes though, but the storage layer does support it if we wanted to implement it someday.

The GUI Colors tab lets you pick an existing theme, or enter RGB values yourself.
And also correct the descriptive name for the wy50 terminal type
Also removed some commented out code from CMString, and fixed up usage of spinboxes everywhere with a new function to set them up.

All tabs for Serial/PTY/LAT/CTERM?DLL/Pipe connections are now implemented. And all tabs currently present in SSH properties are also implemented (the SSH and IP tabs are currently not included in that dialog).
Also added some comments for when modem support is eventually implemented.
Its not perfect, and there are probably bugs, but it does appear to work. Its about time I got back to work on Kermit 95 proper so there probably won't be much more work on the Connection Manager for a few months, but that should give me a good opportunity to test recent changes.
And add a comment for future me to sort something out when I have time to get back to this properly
This fixes the situation where the context menu doesn't appear when the main window is above or to the left of the primary display (one or both coordinates are negative), and also the situation where the context menu is summoned via the keyboard (Shift+F10 or the context menu key).

These changes require Visual C++ 5.0 currently
And add some initial github actions workflow
@davidrg davidrg self-assigned this Jun 5, 2025
@davidrg davidrg added the feature label Jun 5, 2025
davidrg added 2 commits June 5, 2025 17:18
Also: Fix some issues in the about dialog and update the copyright date, fix the keymap field on not allowing more than one line, and maybe fix something that causes a build error on 64bit targets.
@davidrg davidrg linked an issue Jun 5, 2025 that may be closed by this pull request
davidrg added 2 commits July 9, 2025 12:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Build a replacement for the Dialer on Windows
1 participant
0