Calls/requests to outside the network?

Would your question be answered within this thread?

2 Likes

but what of the other way round?.. a user on SAFEnetwork wants to access capability that is not within the network. mysearchrequest->outsideworld

That might be it … an interface between the Devices and SAFE tempts both ways??

I’m tired and thinking slowly then on how a search engine could be made practical or any other volume of database… there is a balance in any function of cost, where users will look to options for matching that with a balance of what is practical. Also, the transition to use of SAFE perhaps will find cases for partial engagement … providing a slippery slope helps get new capability drawn into the network. If the hurdle to transition was ever a big one, then devs would look for breaking down the problem into smaller pieces - one foot in SAFE and one foot outside.

Well if its an application that needs this then it simply does it the same way it would without safe network. And obviously a “native” application and not a browser application. But I’m sure you knew this.

Otherwise if you want a daemon in the network that accesses the outside world then you need to ask why and can it be done in the application that the user is running.

You need a application that is not the supplied SAFE browser. For example a native APP that provides this or a browser that someone may write that allows “outside” requests and SAFE network functionality/access

Of course you can go the “server” route and run a machine yourself that is always on and does the required requests itself. But the answer is writing an application that either runs on the users computer or in a server that the user’s SAFE browser accesses across the safe network.

2 Likes

This is what my response was intended to answer.

I’m saying that for SAFE users to have access to things outside the network, somebody has to provide a gateway to those services (eg run a server that accesses the external service and provides a gateway to SAFEnetwork).

I think you may be asking if the network can do this in some other way? I’m sure it can’t at this time and I’m finding it hard to imagine any other way.

All in all, it is very hard (to say the least) to do this without compromising security, censorship resistance and privacy, because anything outside, including the gateway, is a sitting duck these days.

2 Likes

Yes, I expect you’re right as it stands and fits with my impression too.

However, my instinct is to challenge the boundaries of what is possible, rather than settle for the normal…and doing that early on perhaps helps too.

If we consider what the internet is used for, perhaps we might expect that people will want the same from anything trying to displace that normal.

So consider what the internet is used for atm and wonder how might SAFE cater for those interests https://en.wikipedia.org/wiki/List_of_most_popular_websites
Some of those I can see are covered off, others where some level of interaction with user is wanted, are more hard to see through.

Given that so much of the web now is interactive, what option for interactivity?..

I don’t know the limits of what is practical with just client side and I’m unsure the costing model that SAFE will employ to understand the cost of a database within the network. Obviously, static data is simple one time problem but it’s the dynamic element of usability, that pushes the use cases.

The more use cases that are practical, the bigger then the potential market and larger the pool of users and engagement.

Yes, but the problem is not solved for a pure safe site. I don’t know if this will be still true with the new safe browser, but XMLHttpRequests were blocked by the one based on Beaker browser.

I agree with the value of your probing. You seen to be taking about two things here:

  1. Things that might be hard to achieve on SAFE. Can you give any examples of things you think might not be possible on SAFE, some websites from that list perhaps?
  2. The value of creating a bridge between a SAFE user and some external service. I can imagine these myself, and I expect people will provide such things (eg an email gateway) even if they defeat the objectives of using SAFEnetwork. I do understand the point that such bridges might help adoption, but I’m not sure about this because of the downside from using them. I’d rather we find a better way, though I’ve not given this much thought.

Yes, but I am interested in the official one provided by Maidsafe. I could develop my own browser or I could develop an app but there are 2 problems:

  • It’s much harder to develop that a simple safe site

  • a lot of people won’t use my app or my browser because they won’t trust them because they don’t execute in a sand box and so are able to do much harm. For example, personally, I won’t trust any app not done by Maidsafe.

1 Like

In my case, it’s not about something that isn’t feasible on safe network, it’s about something that would be too costly, like a rapidly changing database.

Can you give me specific examples?

The reason I’m asking you and @davidpbrown for examples is because then we can see if we can solve these issues with the current SAFEnetwork or not.

Saying “a fast changing database” can’t be done in SAFE skips over the problem that this fast changing database is currently being used to solve. That deprives us of trying to find ways of solving that problem in new ways, using this new SAFEnetwork technology. Do you see what I’m getting at?

It may be that there are some problems that can only be solved outside SAFEnetwork as it is now, in which case it would be good to know what they are and therfore how high a priority any improvements might be to help solve them. But I suspect there are also many problems that SAFEnetwork can solve, even though a change in approach might be needed (from a rapidly changing centralised database to something more distributed, and less rapidly synchronised, for example).

We can only figure this out by looking in more detail at specific examples and the characteristics they require in order to fulfil their particular functions.

2 Likes

Do you mean costly as in too much money ? or as in too much stress on the network ? or as in too much computations ?
From what I understood, the money part is yet to be designed, so I suppose tuning ratios between farming / market / demand could solve this.

One way to do this is to use SAFE as a kind of shared memory for a distributed app.

Let’s say I want to make an app and I make a client for the app which will run in the browser.

I can then also make a “server” side component. This would be another app that I could run for example on a virtual machine on AWS.

Requests could then go through mutable data. Basically the client side app stores the requests on the network, for example by appending it to a mutable data that my “server” app is polling. Eventually with MPID messaging I think this could be done through push instead of polling?

Anyways, so the client side app stores the request and the server app would read the requests and execute it. The request could for example be to run som query on an SQL database on the virtual machine, the result from the request would be stored as another mutable data or appended at the end of the motable data and the client app would read it.

The server component can in this case actually be hidden and anonymous, because the client only stores requests on the network and never has direct contact with the server and won’t know it’s ip address, so it would be a little bit like a TOR hidden service.

It could even be made to automatically scale. The sever app could look at the amount of incoming messages and automatically scale up new virtual machines if needed.

3 Likes

Sorry for my imprecision: I meant costing too much money (in safecoins).

  • My old safe galaxy site is an example. The states of the sections were reevaluated every minute. This means that some SDs were rewritten every minute. This was free at that time. Now this is not the case anymore with MDs.

  • Another example is a NoSQL database stored in MDs entries. Changing the values too often would cost too much money.

  • Another example would be the data produced by IoT devices

In all these examples, a way too workaround the cost would be to store the data outside the safe network and to get it with XMHttpRequests from pure web pages (not apps for user security as highlighted above). But doing this in a site stored on safe network is not allowed by safe browser.

1 Like

Risk of getting confused by at least three thoughts now:

and as @tfa suggests
3. The cost of managing changes to data.

It was the first I was looking to but those other two are very important.

for 1. I’m wondering any input from the user that is beyond client based javascript or the like, that then see content being dynamic relative to the user’s interest. So, any volume of data that needs to be reduced to be practical for presentation. A search engine is an obvious example of where you don’t present the whole network but only that part of interest, based on user input as indication of the filter usefully applied. Any dataset bigger than a client will host, needs an option on receiving the user’s input and then a location the data can be formed for it to be returned. So, potentially that can be off network if the network itself doesn’t have dynamic capability - though the talk of databases surely tempts an interaction.

Limiting to thoughts above then for each of [1.2.3.]:

  1. How would a user make use of a database within SAFE?
  2. How would a user get to send requests to a resource external to SAFE? Perhaps that’s answered above with idea of browser hack.
  3. What is the limit relative to cost… tempting perhaps a lot of capability where data changes over time might more easily be off the network. Which perhaps is not a problem, if there is an interface available that allows for static location off network to be addressable.

That last point was what I wondered is missing - an option to address a static real world point outside of xor-space. Specifically then, what option is there relative to IP addresses?.. and thought-experiment then : if there is no equivalent to IP addresses, what implications does that suggest for how services are provided?

I think at the base of this is a simpler question of what is possible on SAFE and what is not… and perhaps some of that still to resolve over time.

1 Like

@tfa thanks for the examples. I don’t see these as impractical, though I understand what you are saying.

The galaxy site costs the visitor for the period they view it, so it is still usable, and could be changed to give the user view and control of the cost here. And perhaps there are ways to store this data locally - does it have to be on the network? I may be off a bit here because I may don’t fully understand the example, but do you see my thinking? It doesn’t necessarily require storage off SAFE.

The same with NoSQL. Two things: the database can be local and sync’d rather than always updating the network. Secondly, NoSQL may not be the only approach to solving many problems, just one that people are used to using until they get to know SAFE and its key-value approach, and later who knows.

So I’m not seeing these as definitely things that require off SAFE storage, though perhaps they will. I’m not sure.

This may answer some of @davidpbrown’s questions, but probably not all. I don’t have time now to go through them but will try to come back later.

There is a misunderstanding here: The user just visits the site and doesn’t create any data, so he should not pay anything. It’s the network free gets principle. This is true for any read only site that displays dynamic data that could come from a modified json file, a database, an IoT device, …

Exactly. This could have been a workaround for the cost but the problem is that the safe browser doesn’t allow access to outside network.

To summarize all the possibilities to display dynamic data:

  • Store them in MDs entries, but this has a cost each time the data is modified

  • Make the visitors pay for the cost but most people wouldn’t want to pay

  • Create a safe site that gets data from outside, but this doesn’t work because the safe browser blocks these kind of requests

  • Create an app that gets data from outside the network, but most people wouldn’t trust an app

This is an assumption. It may be true, at least to start with, but that’s the challenge we face - to provide services that users don’t mind paying for because…

  • the cost is small and passive (no work on their part)
  • there’s a benefit: we don’t exploit them with advertising, surveillance and profiling, exposing them to privacy violations etc
  • it feels free because they are able to farm to cover the cost of using your website

So we all have a choice, to either follow the old ways of thinking while waiting until things have been changed… Or set out as early adopter developers to create that change, by thinking differently and showing a different way. :slight_smile:

3 Likes

reminds me of one of the best sentences I have been given to read in the last 10 years , about buisness on the internet : " if it is free, keep in mind you must be the product "

And the reason I said he would need another other than the (official) safe browser. (remember the answer was for the other poster and so not necessarily suitable for your purpose.

You are right though for the safe browser

For this you write a file to your local disk, and another application picks up the info and passes it onto the web server

For the user wanting to view then you have web page for it to be viewed with say firefox.

Or the APP is a native application that read the info from the SAFE network, puts it up on the server and for the user the APP reads the web server and displays it.

If I’m understanding David correctly here, it looks like messaging might also give you an option for temporary storage of frequently changing data:

1 Like