This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
wilcomega's profile picture

Bluenet v1.1 - A simple and powerfull Networking Layer, UPDATE!

Started by wilcomega, 14 April 2013 - 02:22 AM
wilcomega #1
Posted 14 April 2013 - 04:22 AM
so i have been busy this week with bluenet. bluenet is a working version of the real internet in computercraft.



READ THIS:
for the time being i have been taking a large break from computer craft. i gave TorakTu permission to continue the development for as long as i am having the break
this means that this post will be outdated and he will make a new one with the updated version soon. i will update bluenet myself once PDA's come out for the
wireless stuff. till then he will take care of the project and i hope he will implement alot of you guys's ideas. and be very active with the community.



the parts:

main bluetide network indentification server:
this server will handle new networks. you can also remotely update all network hosts/routers

network host/router:
this will handle incomming and outgoing packets. the source of incomming packets will be checked if its banned or on the whitelist.
you can enable and disable the whitelist. only from the network side of the router you can remotely change settings in the router.
i am planning on adding ftp file checking on viruses.

bluenet api:
this is a simple interface for programs to use. it has all the features

DNS:
it does what is it supposed to do, i am planning on addind in more securety on unregistereing.

interface:
this is a program that can be used by the user itself to use the bluenet api whithout needing to go into LUA

ftp server
this is a program that you save as startup. it will connect, tell the ip and start an ftp server with the choosen password

web host startup:
will connect to bluenet, tell you the ip and start a web server on the choosen domain. the first time it runs it will register itself at the dns server

web host:
this programs hosts a web server.

web browser:
a simple webbrowser. right now it only supports plain text, no buttons, no colors, no links
this will make a lookup request to the DNS and then send the requested file to the returned ip address

layout:

ingame:



Download:
read all of the information that has been told to you in the installer!

pastebin get JDXM9i2P install


planning on making/suggestion:


wireless support. this means that any wireless device will be able to connect to any network in range - 0% done
installer. this will allow you to choose what packet you want to downlaod - suggested by superaxander - 100% done - v1.0
dynamic DNS service. this basicly means that a dns server can register itself at the main host. so the dns doesnt has to be ip 1.1 - 100% done - v1.1

changelog:
Spoilerv1.1:
- dynamic DNS service
download: pastebin get JDXM9i2P install

v1.0:
- initial release
download: pastebin get 8g1hChHF install

i hope you find this usefull and please report any bugs and suggestions! :)/>

to be honest:
all of this was inspired by lyqyd. he made the official lyqydnet api.

thx for reading,
wilcomega
Mads #2
Posted 14 April 2013 - 07:35 AM
I suggest that you put it all in one package. E.g. you have all of those programs in one folder, and then one main program. Then a user would run a command like this:
bluenet ftp
Which would then run .bluenet/bluenet_ftp.lua or something. Just a suggestion.
superaxander #3
Posted 14 April 2013 - 09:42 PM
This could use a installer.
This

If http then
  shell.run("pastebin", "get", "code", "file name")
  ...
  shell.run("pastebin", "get", "code12", "file name12")
else
  print "Http must be enabled"
end
Or use http.get and such
wilcomega #4
Posted 14 April 2013 - 11:05 PM
i was planning on adding an installer. but could you give me some feedback on how it works and if you like it and such?
superaxander #5
Posted 15 April 2013 - 12:50 AM
Well I really like the way you adopted the real http system. Good job!
Lyqyd #6
Posted 15 April 2013 - 10:52 AM
Moved by request.
FuuuAInfiniteLoop(F.A.I.L) #7
Posted 15 April 2013 - 11:42 AM
Can you add a screenshot in minecraft, because i dont understand that image
wilcomega #8
Posted 16 April 2013 - 05:11 AM
i have added an ingame screenshot for those who need it.
i think you will be able to make up what computer does what. if not, tell me
Left4Cake #9
Posted 16 April 2013 - 06:12 AM
i have added an ingame screenshot for those who need it.
i think you will be able to make up what computer does what. if not, tell me

Tell me if I did it wrong


Also thanks for the inspiration. I added some sort of DNS functionally to Firebox after seeing this.
wilcomega #10
Posted 16 April 2013 - 06:27 AM
that is exactly right, i have notices that people are asking me questions and stuff but not really telling me if it works or if they like it, could you tell me what you think?
Left4Cake #11
Posted 16 April 2013 - 07:36 AM
that is exactly right, i have notices that people are asking me questions and stuff but not really telling me if it works or if they like it, could you tell me what you think?

Some time when I get a change to play Minecraft.
Left4Cake #12
Posted 18 April 2013 - 04:47 AM
The ftp sever has a nil value error on line 4.

Haven't tried alot else of it. Really this is just a lot of stuff and is kind of overwhelming.

First it would help if the pastebin were listed like "pastebin get Wffc9xRZ bluenet" and not just "Wffc9xRZ bluenet"

Great work so far but you should try a clean world and set it up and see where the bugs are.
wilcomega #13
Posted 18 April 2013 - 05:01 AM
yeah, i posted it as a wip in general at first. because i didnt know all the bugs and stuff. then i thougth that it would be stable enough to release. so i did. and now i am waiting for bug reports.
ow and when this post has got 500 views i will be releasing an update with less bugs and wireless connections. wich will be usefull for the PDA's
wilcomega #14
Posted 18 April 2013 - 10:00 AM
i have added an ingame screenshot for those who need it.
i think you will be able to make up what computer does what. if not, tell me

Tell me if I did it wrong


Also thanks for the inspiration. I added some sort of DNS functionally to Firebox after seeing this.

thx for the picture by the way! :D/>
JGreen1996 #15
Posted 23 April 2013 - 09:05 AM
does this allow for more clients than are in the screenshot?
wilcomega #16
Posted 23 April 2013 - 09:06 AM

does this allow for more clients than are in the screenshot?

yes, infinite clients
wilcomega #17
Posted 24 April 2013 - 05:04 AM
i see the amount of views has been raised over 500 so that means in the next few day i will be releasing an update that will include wireless connections and more fail-safes also. you can suggest things right now until the update. if its good i will include it
Patey #18
Posted 04 May 2013 - 03:24 PM
Love this idea, currently playing around trying to set it up (with very little luck -.-) but I'll need wireless connections before it'll work for my server.

I've followed the picture for the most part, I've just compacted it into a small room ontop of a tower for best coverage with wireless, and I've removed one router and the clients attatched to it for testing purposes. dns server wired into one side of a router while the nameserver is wired to the other side and extends to a router between the clients.
my problem comes when setting up the software, I've used the installer for dns and routers and the pastebin for the nameserver specifically (didn't see it in the installer) but tried installing it in many different orders but the dns seems to freeze up, eventually the second router finally registered a network but it doesn't seem to have any effect :S

also incase you haven't already got it planned, when you add the wireless feature would it also be possible to add a wireless extension feature? a completely wireless router that extends the network, simply set it up and connect to the wireless network and users near the router can connect.

also, take a look at firewolf. you could use that as a webbrowser
wilcomega #19
Posted 05 May 2013 - 07:12 AM
well i would have to rewrite alot of it for it to work….
Patey #20
Posted 05 May 2013 - 11:26 AM
well i would have to rewrite alot of it for it to work….

I'm assuming you mean firewolf, I figured as much but thought it might be helpful to mention.

im only just learning lua, but if you need help with testing or somone to do some basic code to save you time I'll pitch in if I can simply to see it released faster :)/>
TorakTu #21
Posted 06 May 2013 - 04:43 PM
I had a dream of making this last night. Hahahaha..


Nice work !!!
Asdramelesh #22
Posted 08 May 2013 - 04:34 AM
Nice, and fun =p
Shazz #23
Posted 08 May 2013 - 08:15 PM
Very nice, I was thinking of something like this too. Although my idea was a little different than yours. Maybe some day I'll do it if I'm not lazy.
Anyway, I agree you should add an installer. You can use ccPackager to do it if you want.
TorakTu #24
Posted 08 May 2013 - 11:21 PM
Wanted to give you all an idea of what I am doing…

Welcome to the building of Toogle.. My version ( TorakTu ) of google – :P/>

Spoiler

Keep in mind, I am still peacing all this together. But the idea here is a city. The lights are actually running off of the Nuclear Power plant off in the distance. There are power lines that are carrying high voltage lines from the plant all the way to this building. The network cable and power lines are in the back of this building. They go to each building in my city. If the power plant dies for any reason, then the whole city could go dark and that is when the emergency backup solar power plant kicks in and takes over.

Toogle is obviously my way of google.. but I am setting up this building to be the head quarters of it and people from all over the city can use the "internet" and make webpages etc etc. At least, this is what has been planned. Most of the building has been made, I am setting up the computers now. Once I get this running, i'll make a youtube video of this so you can see it all in action. :D/>

The reason I post this here, is because I am going to attempt to use Wilcomega's Bluenet software. I'll keep you all posted.
wilcomega #25
Posted 09 May 2013 - 03:17 AM
Wanted to give you all an idea of what I am doing…

Welcome to the building of Toogle.. My version ( TorakTu ) of google – :P/>

Spoiler

Keep in mind, I am still peacing all this together. But the idea here is a city. The lights are actually running off of the Nuclear Power plant off in the distance. There are power lines that are carrying high voltage lines from the plant all the way to this building. The network cable and power lines are in the back of this building. They go to each building in my city. If the power plant dies for any reason, then the whole city could go dark and that is when the emergency backup solar power plant kicks in and takes over.

Toogle is obviously my way of google.. but I am setting up this building to be the head quarters of it and people from all over the city can use the "internet" and make webpages etc etc. At least, this is what has been planned. Most of the building has been made, I am setting up the computers now. Once I get this running, i'll make a youtube video of this so you can see it all in action. :D/>

The reason I post this here, is because I am going to attempt to use Wilcomega's Bluenet software. I'll keep you all posted.
very cool, cant wait
if you need any help. just ask me
TorakTu #26
Posted 09 May 2013 - 09:22 AM
I sent you a PM. I will add you to my white list as soon as you can PM me back with your In Game Name. I got the thing to work.. with the only problem being that it wont let me download a file from one to the other. The browser works as it tells me there is a server there, or that it sees it as offline.. depending on what I am doing at the time. So this thing is working.. but it is buggy.

Hope to get some feedback from you.

EDIT UPDATE : I should have said .. Website not found.. Here is a picture for clarity.. The FTP and WEBSERVER are both online though.. so I am confused by this.

Spoiler

I'm uploading a youtube video. Once its done ( in a couple hours ) I'll post the link here.
tonkku107 #27
Posted 09 May 2013 - 02:03 PM
seems nice
TorakTu #28
Posted 09 May 2013 - 02:18 PM
Ok guys, here is a video.. Hopefully wilcomega can point out whats wrong for me. Heck I'm not even sure if I was supposed to create the HTML pages or anything yet. Anyhow, here is the video.

Spoiler[media]http://www.youtube.com/watch?v=3SEsd1knGmc[/media]
TorakTu #29
Posted 10 May 2013 - 03:21 PM
OK update. I got the server and ftp to register and it now shows that they are registering. NOW the problem is the browser hangs. Once it does what it does, boom.. locks up. Not sure why yet, but I think there is something wrong in the code since it won't pull the files from the webserver.. UNLESS.. I am supposed to have files there that I might be missing. So either way, the DNS now shows its connecting as well as well as the other servers. And the website "Hello.com" is now finally registering itself.. Before this, they were all hanging. This was do to the fact that I used more then one router. It only requires one.

So now I am working out the issues with the bluebrowser.

Once wilcomega can come check it out, maybe he can see what I might be missing.
TorakTu #30
Posted 10 May 2013 - 08:25 PM
WOO HOOO !!! I GOT IT WORKING.. Since I never saw wilcomega log in.. I just kept at it. until I figured out where I went wrong. What it was doing is registering all wrong when it came to the routers. I needed to setup a router to EACH device.. but I had to set the first Bluenet server first with its own router. I had to get that running first. I was running the others wrong becaue they couldn't establish their own IP address. Once I figured this out, I now can have as many web server and web browsers as I want all running at once. Well.. at least up to 64K in routers with 64K web browsers each.. if that makes any sense to any of ya.. lol

And YES I did have to create the index file and put my own "Toogle" text in it.

Here is a picture of Toogle.com.. :D/>

Spoiler
TorakTu #31
Posted 10 May 2013 - 08:55 PM
OK, found a bug.. When you type in something that doesn't match any server, the router that the client is attached too errors out saying that startup in line 66 needs a number instead of a string. Then the router goes back to the prompt. The browser does say that No server Found though. So that part seems to be working.

Torak
dangranos #32
Posted 23 May 2013 - 06:31 AM
Can somebody add guide?
wilcomega #33
Posted 26 May 2013 - 11:13 AM
Update! :D/>
changelog included
TorakTu #34
Posted 06 June 2013 - 08:24 PM
Here is my last youtube video I had of bluenet before I had to take my server down. Hardware limits forced me to take my server down. But I do explain a little bit on how I got bluenet working.

http://www.youtube.com/watch?v=wCJJga74rWY
TorakTu #35
Posted 09 June 2013 - 11:38 PM
Giving you a heads up. I was working on your UPDATED version. And I am finding out that there is a fail on ( pastebin get n8A8T3Ypa startup ) for the webserver. I have tried it sevral times and it FAILED every time. So far everything else seems to be working.

Try running INSTALL and then choose webserver. You will find that the "startup" is the one that fails.

files.webserverboot = { "startup", "n8A8T3Ypa" } <—– FAILED


I also tried to get he browser and it FAILED here too.

files.webbrowser = { "bluebrowser", "Lhfzne" } <—– FAILED

I am also making a tutorial based on this updated 1.1 version. But I can't go further with it until this is fixed.


EDIT UPDATE : I have reverted back to the 1.0 Code. You can use ( pastebin get 8g1hChHF install ) in its place of the one shown in the OP until the two files that are missing, are fixed. I am currently making a tutorial based on the working 1.0 code.
TorakTu #36
Posted 10 June 2013 - 07:02 AM
Bluenet 1.0 tutorial


Note : Make sure to edit ComputerCraft.cfg file and set HTTP access to true.

B:enableAPI_http=true



http://www.youtube.com/watch?v=Xw2L8CknAaw
ETHANATOR360 #37
Posted 10 June 2013 - 07:18 PM
how are you using IC when its latest build is for 1.4.5
TorakTu #38
Posted 10 June 2013 - 07:45 PM
how are you using IC when its latest build is for 1.4.5

In this tutorial there is no IC mod installed. And no, you can use IC2 for 1.5.2. now. Been this way since 1.5. In fact today its up to version #348 as of today.

Just in case you can't find it.. : http://ic2api.player...080/job/IC2_lf/
ETHANATOR360 #39
Posted 10 June 2013 - 08:54 PM
thanks and btw it a really cool town you built there
TorakTu #40
Posted 10 June 2013 - 11:02 PM
thanks and btw it a really cool town you built there

Thanks. Appriciate that.
wilcomega #41
Posted 13 June 2013 - 09:58 AM
i fixed the installer so you can setup your own web hosts and browse them
TorakTu #42
Posted 13 June 2013 - 10:46 AM
i fixed the installer so you can setup your own web hosts and browse them

Trying out the code now.

EDIT UPDATE : Ok the updated 1.1 files work. Thanks for fixing that. Still the problem of the multiple webservers on one router still doesn't work right. When you setup first webserver it runs, you setup another one on the same router, it crashes the first webserver. I then ran the first one again and sure enough, you can access both webservers with the browser. The problem is, now both webservers are showing that they are failing because they both are looking for missing files that do not exist. BUT, as soon as I log out of minecraft and back in again, it works just fine. It's the oddest bug I have seen with bluenet.
TorakTu #43
Posted 29 July 2013 - 09:03 AM
Giving you a heads up here. Couple of us worked on the code and we actually got all of bluenet working on floppy disks. The main issue was the host file. It has a problem when it comes to loading the index file. We think we solved it in mc 1.5.2.. but then in mc 1.6.2.. boom.. now it doesn't work.. so we are still working on that one file problem. But line 35 of the host file seems to be a problem.

I'll keep you posted on any further developments.

Also, are you still updating this code ? Or should I form my own thread and take over the project ? I hadn't seen any progress from you so I wasn't sure if your still working with bluenet or not. It needs a lot of attention. It needs code in it to detect errors and it needs to smoothly allow more then one computer on each router. Things like this. As it stands, it just too buggy to be used as a stable software.

EDIT UPDATE : Solved.. it is the SHELL COMMAND… it doesn't like you running startup from the floppy disk if your not in the root. I will have to find a way to change directory within the program to know where it is when it SHELL's out to HOST.
wilcomega #44
Posted 30 July 2013 - 07:02 AM
well i am taking a large break from CC i am planning on updating bluenet once PDA's come out so you can have wireless connections. but if you want you can keep making it more awesome
TorakTu #45
Posted 30 July 2013 - 12:13 PM
well i am taking a large break from CC i am planning on updating bluenet once PDA's come out so you can have wireless connections. but if you want you can keep making it more awesome

Sweet.. i'll update it and post the alternate version on another thread so that it doesnt' disrupt your version. Thanks man. :D/>
TorakTu #46
Posted 02 August 2013 - 09:24 PM
For those who can't find the updated version, here is the link…

TorNet - The Forked version of Bluenet.
http://www.computerc...ion-of-bluenet/