Discussion:
use password protected scripts on LC web server
Todd Fabacher via use-livecode
2018-11-18 02:21:31 UTC
Permalink
Quick question...we have some specific info in LC we need to put in a
LiveCode web script to be run online. But we need to protect the content.
Can we put that in a password protected script, drop it online and add it
in as an "Include"??

Thanks, this would be SUPER helpful,

Todd
Todd Fabacher via use-livecode
2018-11-18 02:26:58 UTC
Permalink
SUPER..I FOUND IT AND THE ANSWER IS YES!!!

This changes my entire concept of using LiveCode online. I can do full
debugging in my app and just take the functionality I want and move it
online.

FANTASTIC!!
Post by Todd Fabacher via use-livecode
Quick question...we have some specific info in LC we need to put in a
LiveCode web script to be run online. But we need to protect the content.
Can we put that in a password protected script, drop it online and add it
in as an "Include"??
Thanks, this would be SUPER helpful,
Todd
Todd Fabacher via use-livecode
2018-11-18 03:30:06 UTC
Permalink
I got the LC Indy web server installed and it can connect to the DB and
return JSON.

But as soon as I reference a password protected script file, it gave me an
error.

<?lc
// Database
include "model.lc"
include "xps_sync.livecode"

--I even tried "start using", but did not help
--was getting: row 6, col 1: Chunk: can't find stack
--start using stack "xps_sync"

put DoesItWork() -- Simple function that returns "It Works"
?>

This is the error I am getting:

REVO7000

file "/var/www/html/model.lc"
file "/var/www/html/xps_sync_delete.lc"
file "/var/www/html/xps_sync.livecode"
row 7, col 6: Function: error in function handler (DoesItWork)
row 7, col 6: put: error in expression


Here is the simple password protected function:

function DoesItWork

return "It Works"

end DoesItWork
Post by Todd Fabacher via use-livecode
SUPER..I FOUND IT AND THE ANSWER IS YES!!!
This changes my entire concept of using LiveCode online. I can do full
debugging in my app and just take the functionality I want and move it
online.
FANTASTIC!!
Post by Todd Fabacher via use-livecode
Quick question...we have some specific info in LC we need to put in a
LiveCode web script to be run online. But we need to protect the content.
Can we put that in a password protected script, drop it online and add it
in as an "Include"??
Thanks, this would be SUPER helpful,
Todd
Todd Fabacher via use-livecode
2018-11-18 04:43:50 UTC
Permalink
I finally got it to work, just don't do "include" the script, but only
do "start using"

<?lc
// Database
include "model.lc"
start using "xps_sync.livecode"
put DoesItWork()
?>
Post by Todd Fabacher via use-livecode
I got the LC Indy web server installed and it can connect to the DB and
return JSON.
But as soon as I reference a password protected script file, it gave me an
error.
<?lc
// Database
include "model.lc"
include "xps_sync.livecode"
--I even tried "start using", but did not help
--was getting: row 6, col 1: Chunk: can't find stack
--start using stack "xps_sync"
put DoesItWork() -- Simple function that returns "It Works"
?>
REVO7000
file "/var/www/html/model.lc"
file "/var/www/html/xps_sync_delete.lc"
file "/var/www/html/xps_sync.livecode"
row 7, col 6: Function: error in function handler (DoesItWork)
row 7, col 6: put: error in expression
function DoesItWork
return "It Works"
end DoesItWork
Post by Todd Fabacher via use-livecode
SUPER..I FOUND IT AND THE ANSWER IS YES!!!
This changes my entire concept of using LiveCode online. I can do full
debugging in my app and just take the functionality I want and move it
online.
FANTASTIC!!
Post by Todd Fabacher via use-livecode
Quick question...we have some specific info in LC we need to put in a
LiveCode web script to be run online. But we need to protect the content.
Can we put that in a password protected script, drop it online and add it
in as an "Include"??
Thanks, this would be SUPER helpful,
Todd
AndyP via use-livecode
2018-11-18 12:38:34 UTC
Permalink
You can also put your LC scripts outside the public web root, then include
them in a calling LC script for extra security.



-----
Andy Piddock


My software never has bugs. It just develops random features.

TinyIDE a Free alternative minimalist IDE Plugin for LiveCode


Script editor Themer for LC http://2108.co.uk

PointandSee is a FREE simple but full featured under cursor colour picker / finder.
http://www.pointandsee.co.uk - made with LiveCode
--
Sent from: http://runtime-revolution.278305.n4.nabble.com/Revolution-User-f278306.html
Matthias Rebbe via use-livecode
2018-11-18 15:46:05 UTC
Permalink
That´s the way i am doing it with the complete script, not only with confidential data.

Most of my scripts in public web root just contain an include command

e.g.
<?lc
include "/home/..../custom-scrpts/domain1/index.lc
?>

The included file, which is stored outside the public web area then contains the complete script.
So in any case the Livecode Server engine is not running, the web visitor just sees the include command and nothing else.

Matthias



Matthias Rebbe

free tools for Livecoders:
https://instamaker.dermattes.de
https://winsignhelper.dermattes.de
Post by AndyP via use-livecode
You can also put your LC scripts outside the public web root, then include
them in a calling LC script for extra security.
-----
Andy Piddock
My software never has bugs. It just develops random features.
TinyIDE a Free alternative minimalist IDE Plugin for LiveCode
Script editor Themer for LC http://2108.co.uk
PointandSee is a FREE simple but full featured under cursor colour picker / finder.
http://www.pointandsee.co.uk - made with LiveCode
--
Sent from: http://runtime-revolution.278305.n4.nabble.com/Revolution-User-f278306.html
_______________________________________________
use-livecode mailing list
http://lists.runrev.com/mailman/listinfo/use-livecode
Loading...