- got too cute with the package names, needed to bring everything into one package, except for packer.
- system is passing traffic now, ran a load test generating 1000 connections, seems ok.
- removed a lot of message logging since traffic is passing.
- it does not look like the client is limiting the amount of traffic coming in, and it does not look like it is chunking.
- need to know the max chunk.
- increased to 64K
- unpacker code v1
- fixed packer logging.
- I anticipated having to bring up new listeners as tunnel-clients connect allowing different port use for a single domain
- completed the code, however did not see any port information coming back from WSS client.
- opened an issue with AJ.
- all listeners are now dynamically generated. The run method takes an initial port, once functioning, the runner send down the channel a registration for the initial port.
- added support for PeekAll…still not working 100%.
- passing important values inside the context, no longer on arguments
- stream handler now detects wss_client, validates the token to make sure.
- then passes to was handler which invokes http.Server with oneConnListener
- removing listener wedge, going to stay with oneConnListener. It is working.
- added support for context passing between the various functions
- support for withCancel, allowing administrative canceling, and a clean up of Go Routines.
- generic listener now supports a single port for both encrypted and clear text protocols.
- employee the buffered wedge connection for peaking into the protocol
- implementation of the oneListener.
- when TLS, leveraged the NewListener which uses oneListener as n inner lister.
- once the stream is decrypted, or if it was already clear text it is passed to handleStream which performs application detection.
- connectionWedge supports reading from a connection without consuming bytes (peeking)
- allowing protocol detection
- was still connections to 3502, it will support any port (443), admin follows this port.
- matches RVPN.DAPLIE.INVALID and redirects to admin — AJ to provide authentication framework.
- api/servers is also served by this path as we’ll.
- listener_generic is the beginngins of protocol detections.
- listener_wedge is an matches the net.Listener interface, and allows passing to other processes an already accepted connection
- this does not work for HTTP for some reason.
- spent a lot of time trying to figure out why. Posted to go-nuts
- I was never able to get delve and visual studio code to work properly with this project.
- not sure if it is too complex, however a simple application could be debugged just fine.
- I’ve implemented godebug, and resolved the vendor dependancies
- now able to debug in development, and build self-contained code into QA/STAGING.
- this resolves the issues at this point.
- when testing streams to WSS client, I caused tunnel.js to abort in xfer.
- this caused a panic in go.
- found that connection was reaped and garbage collected during send routines.
- placed synchronize around a connection states.
- moved connection creation into connection table.
- allowed connections to hang around while in a false state…
- will have a go routine remove them after some idle time and connections being false.
- add support for domain_api container for JSON encoding
- separated server api containers out of the listener_admin
- added domain track to connection
- add extension to the send channel to identify domain associated to send bytes
- helper function for adding tracked domain
- implemented outbound byte counter for domain (inbound will come when we resolve the packer issues)
- collects a list of WSS servers, and the connection structure
- calculates a connection duration
- collects the bytes in/out
- encodes to JSON and sends response.
- added support for ConnByDomain which looks up existing WSS and registered domain
- passed connection table to External Listener
- on request, obtained hostname and map to domain, split the remote address and port (will go into an table eventually)
- look up the domain and find the WSS connection
- packed up the frame.
- sent down the channel.
- debugging issues (not resolved) attempting to move the main executable into the base directory, this did not solve the issue, keeping it here. A main.go and the executable.
listener_client — the WSS client
- removed support for anything admin
- injected the domains from the claim
- domains are now included as initialDomains
- registration performans as normal but includes adding the domains to a map of domains, and a collection of domains on the connection.
- the system now supports look up fast in either direction, not sure if it will be needed.
- reads a chan during registration before allowing traffic, making sure all is well.
- registration returns a true on the channel if all is well. If it is not, false. Likely will add some text to pass back.
Connection
- added support for boolean channel
- support for initial domains in a slice, these are brought back from the JWT as a interface and then are type asserted into the map
- removed all the old timer sender dwell stuff as a POC for traffic counts.
ConnectionTable
- added support for domain announcement after the WSS is connection. Not sure if we will need these. They have not been implemented.
- I assume all domains are registered with JWT unless I hear differently which would require a new WSS session
- expanded NewTable constructor
- populating domains into the domain map, and into the connection slice.
- added support for removing domains when a connection is removed.
- each listener has its own MUX and handlers that are separate from global.
- the external handler will take a request from an external client destine for a WSS.
- the request is output on stdio.
My Questions are this point is this:
- do I just send the request down towards the WSS, or do I have to pack it?
- what is the response I will get back from the tunnel client? That seems it must be in a packer.
- I’ve been going though the source I need to be pointed in the right direction.
- altered code to support a client bound interface
- altered code to support an admin bound interface
- added configurations and defaults.
- removed timeout function at the end of main.
- the final go routine was converted to a foreground routine.