## Lua Web Access

Plug-in related stuff can be discussed here.

Moderator: Plugin Moderators

Wekabu city
Inhabitant of a Megalopolis
Reactions:
Posts: 556
Joined: Tue Aug 29, 2017 21:07
Location: Germany, Hessia
Plugins: Show
Version: Beta

### Lua Web Access

So why does

Code: Select all

local loc = "http://geolykt.de/tt/files/update.txt"
local file = assert(io.open(loc,"r"))

not work?
Looking through the Game logs I get this:
...
...
now you May think it's because io.open() is Not meant to be invoked with an url as a argument, but it actually seems Like it does:
with https enforce on the Webserver and Bad internet I get this
...
...
This means that it's Not actually possible to Access Files on distant webservers, but also intedent to be done this way, so how do I use it correctly?

OK, maybe Lobby did never thought Somebody would do that ...
Free & Open Source Software Advocate.
I am also an armchair lawyer when it comes to copyright and I quite enjoy alongside other languages such as C++

JustAnyone
Rip-off engineer
Reactions:
Posts: 3114
Joined: Sun Jul 23, 2017 12:45
Location: Easter Island
Plugins: Show

### Re: Lua Web Access

It is really powerful and could be used for harm.

Wekabu city
Inhabitant of a Megalopolis
Reactions:
Posts: 556
Joined: Tue Aug 29, 2017 21:07
Location: Germany, Hessia
Plugins: Show
Version: Beta

### Re: Lua Web Access

That's a thing, but I think read-only access should be still possible. Maybe it can be used to dain your data capacity, but it seems like Theotown already monitors the time you stay on the internet (probably to keep Threads 'clean'.
Free & Open Source Software Advocate.
I am also an armchair lawyer when it comes to copyright and I quite enjoy alongside other languages such as C++

Lobby
Developer
Reactions:
Posts: 3643
Joined: Sun Oct 26, 2008 12:34
Plugins: Show
Version: Beta

### Re: Lua Web Access

1. Any GET request can be used to transfer data to a server.

2. From a user's point of view connecting to the internet isn't necessarily something you would expect from a plugin.

3. Local regulations would require us/you to include an appropriate data protection declaration for that data transmission, even if nothing is tracked or saved on the server side.

May I ask for what reason you want to connect to a server? The player may be offline and resource files should be bundled with the plugin.
=^._.^= ∫

Wekabu city
Inhabitant of a Megalopolis
Reactions:
Posts: 556
Joined: Tue Aug 29, 2017 21:07
Location: Germany, Hessia
Plugins: Show
Version: Beta

### Re: Lua Web Access

Update checking for plugins.
But I don't want the put data to the webserver, rather retrive data from the webserver, if you misunderstood me.
Free & Open Source Software Advocate.
I am also an armchair lawyer when it comes to copyright and I quite enjoy alongside other languages such as C++