Reply
Thread Tools
Posts: 1,288 | Thanked: 4,316 times | Joined on Oct 2014
#1
Started this new thread, to replace the old one as it is out of date. The information below is in that old thread, but spread around, so here is a recollection to sum up the install procedure for new prey version:

To install recent nodejs build of Prey for SailfishOS:

Add my merproject repository

Code:
$ devel-su
# ssu ar nieldk http://repo.merproject.org/obs/home:/nielnielsen/sailfish_latest_armv7hl/
# pkcon refresh
Install nodejs and sudo

Code:
# pkcon install nodejs
# pkcon install sudo
Alternatively, install the rpm by downloading it from
https://build.merproject.org/package...latest_armv7hl

https://build.merproject.org/package...latest_armv7hl

If you do not want to add my repository.

Then, install prey:
You NEED to do this using devel-su!

Code:
$ devel-su
# npm install -g prey
# prey config hooks post_install
# prey config account setup
now enter your account credentials,
The device is added, and you are ready to track it on panel.preyproject.com
service to start prey on boot is installed and enabled automatically

Last edited by nieldk; 2015-09-14 at 07:06.
 

The Following 15 Users Say Thank You to nieldk For This Useful Post:
Posts: 1,288 | Thanked: 4,316 times | Joined on Oct 2014
#2
So far, this is what is working:

* Get location of device
* Get device hardware information (CPU/memory)
* Get network information (IP, neighbour wlans)
* logged in user (usually nemo or root)

Features missing:
* Screenshot
* Camera
* Sound alerts on device
* Message alerts on device
* Lock device
* Erase device

Allthough the missing features are nice to have (especially the lock device) I believe it is at this point usefull that we can get location reports for a stolen device.

Prey have added the distro 'mer' to the recognized distributions, so, any updates that will be done to enable the missing features should be pushable to them, and as such that will make it much more easy to install, as everything will be part of Prey's 'native' eco system.

A certain well-known developer may look at the Prey sources and hopefully, in a near future we can have a more SailfiishOS-native client, and hopefully Jolla can make this a part of 'standard firmware'.

What needs to be considered, is how to protect de-installation of Prey.
Prefferable Prey as service can be protected from de-installation, and any GUI part that would be de-installed would be for status information only.

Last edited by nieldk; 2015-09-14 at 08:27.
 

The Following 2 Users Say Thank You to nieldk For This Useful Post:
Posts: 2 | Thanked: 2 times | Joined on Sep 2015
#3
Installed prey this morning, and couldn't get it to locate where my Jolla is. Went to terminal and typed Prey and it came up with this. Is there suppose to be that many errors and critical?
 
Posts: 1,288 | Thanked: 4,316 times | Joined on Oct 2014
#4
no.
Did you fllow instructions?

Not sure if it matters. But do try to install sudo.
 
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#5
only i see dbus-monitor not found error in this image?
__________________
Telegram | Openrepos | GitHub | Revolut donations
 
Posts: 2 | Thanked: 2 times | Joined on Sep 2015
#6
So after installing Sudo everything seems to be working. It still reports errors, some the same and some new. However it seems to be working : 'Prey' after installing sudo,

After typing prey it would not let me type any other commands so I had to close the session. When I reconnected and typed prey it was happy
 

The Following 2 Users Say Thank You to hantoo For This Useful Post:
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#7
also i decided to try prey myself, but:
Code:
Running "config activate" as prey
Error! Command failed: /bin/sh -c /usr/bin/node /usr/lib/node_modules/prey/node_modules/ocelot/runner.js prey /usr/lib/node_modules/prey/bin/prey config activate
child_process.js:1162
    throw errnoException(err, 'spawn');
          ^
Error: spawn EACCES
    at exports._errnoException (util.js:746:11)
    at ChildProcess.spawn (child_process.js:1162:11)
    at exports.spawn (child_process.js:995:9)
    at run_command (/usr/lib/node_modules/prey/node_modules/ocelot/runner.js:60:15)
    at Object.<anonymous> (/usr/lib/node_modules/prey/node_modules/ocelot/runner.js:95:1)
    at Module._compile (module.js:460:26)
    at Object.Module._extensions..js (module.js:478:10)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Function.Module.runMain (module.js:501:10)
__________________
Telegram | Openrepos | GitHub | Revolut donations
 
Posts: 1,288 | Thanked: 4,316 times | Joined on Oct 2014
#8
Originally Posted by coderus View Post
also i decided to try prey myself, but:
Code:
Running "config activate" as prey
Error! Command failed: /bin/sh -c /usr/bin/node /usr/lib/node_modules/prey/node_modules/ocelot/runner.js prey /usr/lib/node_modules/prey/bin/prey config activate
child_process.js:1162
    throw errnoException(err, 'spawn');
          ^
Error: spawn EACCES
    at exports._errnoException (util.js:746:11)
    at ChildProcess.spawn (child_process.js:1162:11)
    at exports.spawn (child_process.js:995:9)
    at run_command (/usr/lib/node_modules/prey/node_modules/ocelot/runner.js:60:15)
    at Object.<anonymous> (/usr/lib/node_modules/prey/node_modules/ocelot/runner.js:95:1)
    at Module._compile (module.js:460:26)
    at Object.Module._extensions..js (module.js:478:10)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Function.Module.runMain (module.js:501:10)
Are you using my build of nodejs ?
 
Posts: 1,288 | Thanked: 4,316 times | Joined on Oct 2014
#9
Originally Posted by coderus View Post
only i see dbus-monitor not found error in this image?
Yeah. Prey needs sudo for some access, and to run scripts as a prey user
 
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#10
works after running with devel-su, not root
__________________
Telegram | Openrepos | GitHub | Revolut donations
 

The Following User Says Thank You to coderus For This Useful Post:
Reply

Thread Tools

 
Forum Jump


All times are GMT. The time now is 19:27.