# Websockets and AWS

**URL:** <https://forums.digi.com/t/websockets-and-aws/12896>\
**Category:** Embedded Devices\
**Tags:** websockets, aws\
**Created:** [May 2, 2014, 4:25am UTC](https://forums.digi.com/t/websockets-and-aws/12896 "2014-05-02T04:25:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![steved2](https://avatars.discourse-cdn.com/v4/letter/s/a698b9/32.png) [@steved2](https://forums.digi.com/u/steved2)\
**Post date:** [May 2, 2014, 4:25am UTC](https://forums.digi.com/t/websockets-and-aws/12896/1 "2014-05-02T04:25:19Z")

</div>

I wondered whether anyone had looked at implementing WebSockets on Net+O/S under AWS. I’m guessing it would require the CGI-mode, if its possible at all.

---

<div class="post-metadata">

**Author:** ![dakotas\_dad](https://avatars.discourse-cdn.com/v4/letter/d/a88e57/32.png) [@dakotas\_dad](https://forums.digi.com/u/dakotas_dad)\
**Post date:** [May 2, 2014, 7:27am UTC](https://forums.digi.com/t/websockets-and-aws/12896/2 "2014-05-02T07:27:57Z")

</div>

Hello

```
A couple of things and I'll preface this by stating that all I know about WebSockets, I read in the past five minutes.

WebSockets are part of HTML5. NET+OS's web server (AWS) is based on HTML4.01. 

I do not find the term WebSocket in the code base meaning that in NET+OS's AWS implementation, tehre are no HTML headers for dealing with WebSockets.

In NET+OS if you start the web server, it opens a passive TCP port 80 socket, so all TCP port 80 messages will go to it.

```

If you set up a CGI page, all TCP port 80 messages still go though the web server before being passed to the user defined function have handling CGI pages. Mow I believe you can get the incomming headers when in CGI mode, but I believe you have no control over outgoing headers. I believe this would be an issue with communicating back to the client.

The only thing I could imagine would be that you’d have to not run the NET+OS web server and instead write your own  
thread, sitting on TCP port 80 to act as the WebSocket web server.

---

<div class="post-metadata">

**Author:** ![steved2](https://avatars.discourse-cdn.com/v4/letter/s/a698b9/32.png) [@steved2](https://forums.digi.com/u/steved2)\
**Post date:** [May 2, 2014, 12:12pm UTC](https://forums.digi.com/t/websockets-and-aws/12896/3 "2014-05-02T12:12:21Z")

</div>

Much as I suspected, unfortunately - thankyou for confirming it.

I guess it might be time to look at embedded Linux, although I don’t think webSockets are directly supported there either.
