Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2019-05-28 Thread nickb


NFLnut wrote: 
> I thought I might try (again) to wrap my head around this project but I
> have a maybe naive question: If I decide to try to do the MQTT set up,
> and since I really have no knowledge about AWS, what does it cost to use
> that service with Amazon? Is there a cost? Monthly? Annually? 

Amazon offer a fairly "generous" 'free tier'
(https://aws.amazon.com/free/), and if you're using just Lambdas and
MQTT (as here), I'm fairly confident this should cost you either nothing
or much less than a dollar a month, but I haven't done  an in-depth
analysis

> Thanks for helping an old guy who is probably a little in over my head
> ..
No worries. And in my experience - that's the fastest way to learn!



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] ANNOUNCE: Group Players

2019-03-10 Thread nickb


Great stuff - almost can't believe it hadn't been thought of before!

Thanks for this Philippe



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=108558

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] ANNOUNCE: Alexa voice control (development thread)

2019-01-03 Thread nickb


meep wrote: 
> 
> Those B*std*rds at Amazon keep racing on making new languages available
> and adding features for US skills, but completely fail to extend those
> features to the other languages. There's a slot type available for US
> skills that make searching for album, artist and track titles a breeze.
> (Amazon, after all, have all this info from their product and music
> databases). However, they have for over 12 months now failed to make
> this available to other languages. I know as soon as I roll my own, they
> will come out with it but c'est la vie, as they say.

Welcome back Meep!

FWIW I've spoken in person to two (Amazon) Alexa dev advocates (or
similar) here in London and the response has not been  encouraging. The
first told me to call him some time to chat about the issue (I didn't
bother) and the second a month ago explained that basically Alexa teams
and builds are entirely independent across countries, so the fact that
it's been in the US beta for this long but nowhere else is not
promising. 

He also said, don't worry too much about what built-in intents and in
particular their slots can and can't hold and that home-made slot types
with lots of data are not far off. This implied (to me at least) that
they results from the Music*Intent slots  haven't been as stellar as
perhaps I'd imagined they were, but then I haven't bothered trying to
build a US skill to find out.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=106569

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2019-01-03 Thread nickb

Freddy wrote: 
> Been away for a while and now I see that there has been some great
> progress here, nice work.
> 

Thanks!

> 
> I´m running the version from July (not MQTT), is there any point of
> upgrading and if so, what are the steps?
> 

Probably not much point yet if you've got it working already. Some minor
functional tweaks but most of the work has been in expanding the docs,
the automated build process, supporting more servers, translations and
adding / improving MQTT as a transport. Keep an eye on the 'issues list'
(https://github.com/declension/squeeze-alexa/issues/) and the release
notes I guess.


> 
> A bit afraid to break my setup:eek:

Actually my own build-redeploy-test cycle is down to under 20 seconds,
so it's definitely possible, but only using some of the tooling (as
above) I added in the meantime...



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-11-20 Thread nickb


'squeeze-alexa 2.4'
(https://github.com/declension/squeeze-alexa/releases/tag/v2.4) is now
out.


  
-  Handle old and disconnected players properly
  
-  Handle now playing for tracks / streams with no artist
  
-  Friendly error responses if transport is broken
  
-  Update requests dependency for security
  
-  Improvements to setup scripts
  
-  Big improvements to SSL / howto guides
  
-  Improvements to translations handling for Windows and MacOS
  mainly.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-11-20 Thread nickb


sharper9 wrote: 
> Just ordered echo 2nd Gen and a dot 3rd gen.
> I have a couple of squeeze V3 running wonderfully using my QNAP NAS as
> storage with Flac and MP3 format. 
> Would like to get them hooked up.
> 
> What do I do next?
> 

If you're technical, we've got an extensive 'squeeze-alexa HOWTO'
(https://github.com/declension/squeeze-alexa/blob/master/docs/HOWTO.md).
It's not easy (but I'm automating more and more), and quite a few people
have got this set up now.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-11-15 Thread nickb


Hisma wrote: 
> 
> But I exported my wiki page into a word doc, see here - 
> edit: send me a PM if you want it, just in case there's too much private
> info I didn't want to make it public
> 

Done, thanks.

> 
> Note that I COULD NOT get this working with stunnel. I think your
> instrunctions for setting it up confused me and I just couldn't get it
> working.  The problem I was running in to was that stunnel was trying to
> listen on the same port as my nginx reverse proxy server, so the two
> conflicted.  After spending a few hours trying to figure out what I was
> doing wrong, I gave up, ditched stunnel, and just used straight ssl with
> nginx.  
> 

Yep, setting up tunnels is hard I've found. A lot of ports, a lot of
ways of getting it wrong and not many good tools for debugging.

However if you've got SSL with Nginx working (I'm guessing you looked at
https://github.com/declension/squeeze-alexa/blob/master/docs/SSL.md#with-nginx-19),
then even better. It's newer and perhaps easier to configure for about
the same performance, I'd estimate. 

For security, you should just make sure it uses client certificates so
that not -anyone- (with SSL) can connect to that CLI - this is what my
example config does.

> 
> But perhaps you can try to revise your notes to explain stunnel setup
> more clearly, and especially how to set up the ports correctly so
> nothing conflicts.  
> 

Sure - anything in particular? Obviously no amount of documentation can
let two processes bind to the same port; I guess could be more explicit
about choosing stunnel *or* nginx *or* HAProxy

> 
> Hope my notes can help other newbs like me out.  Haha!
> 

Hopefully!



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-11-11 Thread nickb


Hisma wrote: 
> 
> Thanks for your hard work on this.  This clearly took a lot of time and
> effort.  I will say though it is definitely a "techie only" setup for
> sure.  I'm fairly savvie and it took me about 8 hours to finally get it
> working!  It was mostly due to the quality of documentation though. 
> While you do have pretty much everything covered, there are a lot of
> "holes" in the documentation that the user is expected to fill in and
> really messed me up.  Also, because there are multiple ways to get this
> working (ssl, mqtt, aws iot etc) it was difficult to discern which way
> was specific.  
> 
> I think spending a few hours on improving the documentation would go a
> very long way, and allow more "normal" users to adopt this great
> software.  By the end I didn't find it too entirely difficult to set up
> (though definitely not easy!), but it was just a whole lot of steps.  
> 

Thanks, and yes. Documentation is always hard, and trust me I've spent
quite a few hours on this :). It's made a lot trickier by the diversity
of people's setups (Windows / QNAP / Synology / RPi / other Linux) and
the speed at which Amazon change their mind about Alexa management, and
even AWS Lambda setup. Also, moving to a multi-lingual setup has made
this necessarily more complicated now (-most- of which is hidden in my
release process)

I started spending more time on automating the process as it was clear
that scripting this was better than documenting every single bit, but
I'd *love* some help on improving the docs, seeing as I set mine up ages
ago now and the pain points are lost a little. Perhaps you have some
ideas on how to improve this or at least which bits were harder?


> 
> Otherwise, I hope you continue to update and improve this, you have a
> very good project on your hands here.  I am using ssl and it's lightning
> fast... commands are nearly instanenous, which is quite incredible since
> every other typical alexa command has a noticeable delay.

Great! Yes, I've been quite pleased at the low latency nature,
outperforms all my "native" home automation commands by far.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-10-06 Thread nickb


'squeeze-alexa 2.3'
(https://github.com/declension/squeeze-alexa/releases/tag/v2.3) is now
out.


- Stop transport better (#52) and unsubscribe in MQTT on
  disconnect
- Improve long ValueError Alexa reponse when transport goes
  wrong.
- Now Playing: Support multiple artists if LMS is configured for
  these (#90)
- Now Playing: Support composer for classical (#13)
- Update MQTT docs e.g. systemd and Raspberry Pi



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-10-03 Thread nickb


Prog wrote: 
> I'll maybe have another go at the weekend when I have more time.
> Thanks. If I get properly stuck then I'll ask for help in the places you
> suggested. I'm probably missing something obvious when it comes to
> configuring mqtt-squeeze.

I've just updated the 'MQTT HOWTO'
(https://github.com/declension/squeeze-alexa/blob/master/docs/MQTT.md)
with some better explanation of what's going on / needs to be done, some
pointers to Raspberry Pi stuff (especially Python 3), and added a
working systemd startup script which can be used there too.

HTH



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-09-30 Thread nickb


Prog wrote: 
> I think I'm getting too old for all this techie stuff as I've come
> unstuck following the HOWTO guide. :o
> 
It's not -too- hard, I promise, it just takes a lot of time and
reading.

> 
> Is there a step-by-step guide anywhere to getting this all working on a
> Raspbian-based server? I'd prefer the MQTT bridge option as I'm actually
> familiar with MQTT.
> 

Not currently. A few people have asked (and succeeded?). I'll try to add
a few pointers. If you get really stuck try the chatroom or post a
Github issue.

FWIW, for dev I use Ubuntu (i.e. of a common ancestor with Raspbian),
and deploy to a Linux-based Synology (Upstart-based scripting), so
almost all the 'MQTT HOWTO instructions'
(https://github.com/declension/squeeze-alexa/blob/master/docs/MQTT.md)
should work.

I've been using the MQTT bridge (mqtt-squeeze) and once wrapped in a
upstart / systemd it's rock-solid. More than my Alexa's wifi, definitely
:D



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-09-01 Thread nickb


htcheng wrote: 
> 
> I now have a working skill that can select players, change volume, play
> genres, etc. EXCEPT when I ask it to play a Playlist, it acknowledges
> the playlist but it loads an empty playlist. Once it does this, the
> skill forgets all of the players, genres, etc. for a few minutes. If I
> restart LMS, the skill works again, but the playlists are definitely not
> working and cause some kind of weird cascade that removes all the
> discovered items from LMS.
> 

Weird. Sounds like an exception that then invalidates the caches
somehow, but never seen that so far. Please file an issue on Github,
with some CloudWatch logs if possible.


> 
> BTW - for others trying to build squeeze-alexa: After wasting 2hours
> wondering why the Lambda manifest was mismatched, I finally figured out:
> a) Alexa Dev Docs suck; b) Not all AWS hosting sites support Alexa
> Skills Kit; c) the Skill ID that you get when you click on "Skill ID"
> isn't always the same!! (For building the Skill, you need to use the one
> that starts with "ask/" that is generated after you enter the Skill ID
> in the Lambda Management Console in the region that you choose - it
> should begin with "ask/" not "amzn...")
> 

Good work and yes it's definitely confusing especially because
everything's been moving so fast. If you have any ideas for adding to
the FAQ, docs,  or troubleshooting then please let me know and we can
add stuff.

> I'm hoping to figure out the Playlist issue shortly as the skill works
> well otherwise...

Great!



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-08-17 Thread nickb


'squeeze-alexa 2.2'
(https://github.com/declension/squeeze-alexa/releases/tag/v2.2) is now
out.


-  Huge performance improvement for MQTT transport mode (possibly SSL
  too, untested)
-  Use Amazon native Genre
-  Documentation improvements
-  Testing improvements



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-08-13 Thread nickb


reinholdk wrote: 
> There's a typo in the link above. Should be without "t" before "alexa":
> https://github.com/declension/squeeze-alexa/blob/master/docs/MQTT.md

Fixed now. Thanks!



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-08-12 Thread nickb


NFLnut wrote: 
> 
> 
> Main reason being, I don't want to accidentally and unsecurely blow open
> a port on the innerwebz for every script kiddie on the planet to play
> with. 
> 

Sure, understood. Good news then - this isn't necessary now - you can
use 'the new MQTT transport'
(https://github.com/declension/squeeze-talexa/blob/master/docs/MQTT.md)
instead if that takes your fancy. This requires no ports to be opened,
no LMS plugins to be installed, and no security settings to be changed,
though definitely a fair bit of setup still. It's a little "beta" still
(and not as fast) but it's working for me.

> 
> Therefore, and until future notice, I guess I am out. Kudos however to
> meep and nickb for taking the plunge. Maybe someday old geezers like me
> can find our Alexa/Echoes useful.

Thanks :D



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-08-05 Thread nickb


'squeeze-alexa 2.1'
(https://github.com/declension/squeeze-alexa/releases/tag/v2.1) is now
out:


- AWS setup automation (BETA)
- MQTT transport improvements
- SSL hardening
- Nginx / Dockerised nginx tunnel examples
- Various setup / documentation improvements



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-29 Thread nickb


:cool:



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-27 Thread nickb


FYI 

I tried and documented a 'proof-of-concept with Nginx inside Docker'
(https://github.com/declension/squeeze-alexa/blob/https://github.com/declension/squeeze-alexa/blob/master/docs/SSL.md#with-nginx-19aster/docs/SSL.md)
to work. :)



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-26 Thread nickb

Freddy wrote: 
> I´ve now managed to create the certs for MQTT IOT using the cli.
> 
> Stuck on next step though
> -
> Set up permissions for MQTT
> Go to the AWS IoT section (make sure to select the right region), and
> you start the setup.
> 
> You'll need an IAM policy to grant MQTT access to the squeeze-alexa
> Lambda.
> 
> Use the helpful included IAM policy to permission topics - remember to
> make sure these match your MQTT settings.-
> 
> What setup? :confused:
> 

Actually, there's not much setup needed now I think. You might need to
set up an AWS IOT "Thing" to represent the server - I did this, but I
don't think it was needed in the end.

> 
> Also, I need to create the Lambda squeeze-alexa first before the
> transporter (since I should grant MQTT acccess)?
> 
> It might be that this require that you have very good AWS skills


Definitely yes for the MQTT transport version (beta!). I'd recommend
sticking with the SSL transport unless you -need- to use the MQTT
especially if you're new to AWS stuff. 

If you do decide try MQTT though - the IOT homepage is here
https://console.aws.amazon.com/iot, and you can use 'mosquitto'
(https://mosquitto.org/) to test our your MQTT setup before even
starting with squeeze alexa.

Generally it's easier to jump on the Gitter chatroom:
https://gitter.im/squeeze-alexa/Lobby especially if there are other
people trying this too...



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-26 Thread nickb

Freddy wrote: 
> So your plan is to share the same Letsencrypt certs with stunnel in
> docker and use this container only for squeeze-alexa?
> If you succeed please share, I run my NGINX with Letsencrypt on a nuc
> but Docker on a QNAP NAS. So it might be possible for me to use the same
> approach.
> 
> It seems that stunnel is the preferred way to go but I´m really afraid
> to mess up my current NGINX+let´s encrypt setup

In which case personally I'd just leave that as is, 'generate new cert
pairs just for stunnel'
(https://github.com/declension/squeeze-alexa/blob/master/docs/SSL.md#create-certificates)
which you can set to be 10 years or whatever. So long as you keep these
safe of course.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-25 Thread nickb


caplam wrote: 
> thank you for your answer.
> For now my concern is to find out how to treat the incoming traffic from
> amazon. If my understanding is right, it's not http traffic so i can't
> use synology reverse proxy.
> (I have several servers like jeedom which i can join on
> jeedom.mydomain.fr for example ). Probably i need  to open another port
> and cannot proxify this service.

That's right you'll need a raw TCP SSL streaming reverse proxy. Again I
recommend using 'stunnel' (https://www.stunnel.org/) for this - it's how
others have got it working.

If you really don't want to / can't, you could 'try HA Proxy'
(https://github.com/declension/squeeze-alexa/issues/3) or even 'try
newer Nginx' (https://github.com/declension/squeeze-alexa/issues/47)
(might even be possible using the DSM one but i doubt it). This way will
be trickier though



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-24 Thread nickb


Featuring MQTT support, new settings system, French language, and
various fixes:

'squeeze-alexa 2.0'
(https://github.com/declension/squeeze-alexa/releases/tag/v2.0)



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-24 Thread nickb


caplam wrote: 
> Hi,
> My lms is installed in a esxi5.5 debian8 vm. I'd like to use alexa to
> control lms but i'd also like to have echo seen as a regular lms player
> (not with squeeze-alexia i think).
> 

No, but see https://github.com/declension/squeeze-alexa/issues/25

> 
> I already have a mqtt broker on my network (on a synology nas) but
> having read howto i don't know what solution too choose.
> I have domain names and I have lets encrypt certificates for these
> domains on a synology nas.
> 

Sounds perfect - ignore MQTT for now, I'd go for SSL with your existing
certificate, and get stunnel working - it's old but rock-solid and very
lightweight.

The diagnostics (local_test.py) and FAQ should provide quite a lot of
help with this route, just make sure your networking makes sense
internally (LAN-side) and externall (WAN) side, but sounds like you have
most of that working for the cert anyway.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-24 Thread nickb


Freddy wrote: 
> 
> I also run LetsEncrypt, NGINX and a MQTT broker but to my understanding
> the latter is of no use for this setup since we must use Amazons IOT
> broker?

That's right, at least for now. 

Conceptually you've still got an unsolved problem if you use your own
broker - of how to connect to this broker and on what port etc (and
Lambda means no persistent connections of course). The use-case for the
MQTT transport mode was networking / firewalls that -don't allow any
NAT- (so no port mapping etc)

Plus Amazon's one is near-free, always up, close to the Lambda and
relatively easy / consistent to configure, I guess.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-07-24 Thread nickb


Freddy wrote: 
> Hi,
> I was about to give this another try since it seems amazing. But I have
> a really hard time to follow the README/HOWTO from start -> finish. 
> 

Great, please give it a go. Sorry you're finding it difficult - it is
definitely a complex setup. I've been adding to the docs more and more,
but sometimes think the extra detail is making it -more- complicated. 

Definitely the fact there are entirely different networking modes does -
but I had to do that as I've personally switched to 4G internet, and the
existing setup didn't work. -Necessity is the mother of all invention-,
etc

Is there anything in particular?

> 
> I would like to use alexa-squeeze with the MQTT transporter.
> 

That's great. I don't know of anyone else who's tried it yet so please
do, and file issues (or PRs if that's your thing) if there are any
missing sections, or you learned anything.


> 
> Is it worth waiting for 2.0? Will that one be easier to setup?
> 
Not really -- 2.0 is practically what's in master right now. I've just
not got round to the release work, I'll try and do that soon.

But I've been thinking around (more) automation to set this stuff up.
The thing is automation tooling (aws cli, scripts etc) are generally
suited to going through a process many times, which makes the -extra-
setup worth it. But here I suspect most people just want to set it up
once and leave it.

But I'm happy to hear to any ideas here... The self-diagnostics are
quite good on the SSL side, some stuff like this for MQTT would be cool
I guess.


> 
> EDIT; if I want to create an  IAM user just for this, which access
> groups should I apply

I don't use a user, just a role. But so long as the Lambda user has the
right permissions (in addition to the normal Alexa / Lambda ones e.g.
AWSLambdaBasicExecutionRole) it should be fine AIUI. Have a look here:
https://github.com/declension/squeeze-alexa/blob/master/docs/example-config/iot-iam-policy.json

mqtt-squeeze doesn't need any IAMs, as it connects (currently at least)
with TLS cert-based authentication, though I did create an IOT thing to
model the server itself (don't think this was necessary, just part of
the exploratory phase... I think...)

HTH
Nick (aka declension)



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-06-07 Thread nickb


'squeeze-alexa 1.3'
(https://github.com/declension/squeeze-alexa/releases/tag/v1.3) is now
out with various internal improvements. It's now Python 3.x only, for
what it's worth. :)

Also... a 2.0 version is coming soon, with better networking support
using switchable transports depending on what type of Internet
connection you have (or what you prefer setting up).



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-04-15 Thread nickb

'Squeeze Alexa 1.2'
(https://github.com/declension/squeeze-alexa/releases/tag/v1.2) is now
out.



- The skill is now internationalised with en_GB as default, and
  German (de_DE).  American English (en_US) is supported by default now
  too.
- Better timeout handling
- Errors with the skill can now (configurably) be reported back by
  voice / card. It's as English as possible, and due the earlier
  diagnostics work usually contains useful hints about what the problem
  might be e.g. firewall issues / certificate mismatches, etc.
- Various setup HOWTO improvements



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-04-09 Thread nickb

Aidem wrote: 
> Hi nickb, sorry, I realised I was on the wrong thread and felt
> discussion should be switched this thread.
> Thank you your reply.
> 
> In your installation guide, after *clone the repo* the guide has the
> sentence. “Note you will have to run a release process now to get the
> translations “
> What does this mean?
> 

That was updated recently actually now that it's a multilingual app
(currently British English and erm German German). It's aimed mainly at
developer I guess but I'll try and clean that up, plus  add some
automation around this before the next release.

But if you're downloading v1.1 (as I'd recommend) - it predates this
change and you should refer to -that- 'v1.1 README'
(https://github.com/declension/squeeze-alexa/blob/v1.1/README.md)) (also
included in the zip).

> 
> In your reply to me on the other thread, again on this part of the set
> up you wrote ‘The codebase is primarily to build and deploy the Alexa
> skill though.’
> Should I run some form of compiling process involving Python?
> If so, what is the command line routine to do this?
> 

Python doesn't need (ahead-of-time) compilation so no. Either way the
packaging and deployment to AWS is the harder bit, but all this is in
the documentation - I've built scripts (or you can use third-party
tooling, also detailed) to help build and deploy as necessary.

> 
> This would explain why I could not find any src/settings.py file. There
> is no src directory.
> 

Sorry, yes, I meant 'squeezealexa/settings.py'
(https://github.com/declension/squeeze-alexa/blob/master/squeezealexa/settings.py).

> 
> Finally you were correct, my home set up will eventually be: RPi as NAS
> / home server (to install, say, stunnel etc). I have used the RPi  as a
> Home server since they were first introduced. A RPi is easily up to the
> task.
> However, at present I am using a separate RPi for this project so as not
> to interfere with my home server’s daily routines. If I muck it up it is
> easy to start again. :)

Great. That should work fine then.

BTW best way to get detailed support is either via the 'squeeze-alexa
chatroom' (https://gitter.im/squeeze-alexa/Lobby) or filing a Github
issue - it's too hard on forums ;)



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-04-09 Thread nickb

Freddy wrote: 
> Great to see an own thread about this, I totally missed that before.
> 
> I have a question.
> I'm currently running NGINX for connecting secure to Home-Assistant
> (HTTP) and connecting to my MQTT broker (stream)
> Alexa integration works fine with HA using HAASKA + let´s encrypt cert
> 
> I'm a bit confused about this:
> "Nginx doesn't seem to support non-HTTP traffic over TLS."
> 
> So I need to install stunnel anyhow or should it be possible to use
> NGINX?

Stunnel is recommended, or at least documented and tested in detailed. 


Good news though - on searching just now it looks like 'nginx R6
supports SSL termination for TCP protocols'
(https://docs.nginx.com/nginx/admin-guide/security-controls/terminating-ssl-tcp/)
, in theory at least :) The docs make it -look- quite easy (more modern
than stunnel too), and it supports speed-increasing things like SSL
session caching and SSL session tickets (should be fast enough already
though).

You'd need a separate (secret) cert but I've listed the steps on
creating this. If you have issues, try the Github issues, or if you get
it working and fancy documenting...



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2018-04-08 Thread nickb

'squeeze alexa 1.1'
(https://github.com/declension/squeeze-alexa/releases/tag/v1.1) was
released a while ago.

Includes various fixes and minor improvements, plus improved guides and
HOWTOs.

Also, the development version is now internationalised, with UK English
and German as the two translations provided (help wanted...)



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] ANNOUNCE: Alexa voice control (development thread)

2018-04-08 Thread nickb

Aidem wrote: 
> Unfortunately, I agree, this project seems to have stalled and I must
> thank you for providing a link to this alternative option: alexa-squeeze
> - DIY Alexa integration. I am trying to adapt the instructions provided
> to suit my Raspberry Pi environment.
> I have reached the stage where the files are cloned from github. Then,
> unfortunately, I cannot fathom which directory they should located in. 
> 

Hi. You can now just download a release zip
(https://github.com/declension/squeeze-alexa/releases) which is easier.
You can extract it to any directory on your computer really (e.g.
/home/me/projects/squeeze-alexa), so long as you have access to this,
Python, and a command line (so Linux / Mac easiest, but Windows possible
too) and connectivity to your NAS / server / whatever. The codebase is
primarily to -build and deploy the Alexa skill- though.

Aidem wrote: 
> 
> Nor do I understand, “Edit src/settings.py, filling in the details as
> commented there”.
> 

This is how you configure the Alexa skill for your own setup. It will be
under /home/me/projects/squeeze-alexa/src/settings.py in my earlier
example. By design you shouldn't have to edit much, just a few hostnames
/ IP addresses etc.

Aidem wrote: 
> 
> Finally, has any member successfully used this package on a Raspberry
> Pi?
> :confused:

When you say -on- a Raspberry Pi - is the Pi 
  
-  Your PC (unlikely but can be done..)
-  RPi as a Squeezebox (player)?
-  RPi as NAS / home server (to install, say, stunnel etc)
-  RPi as a LMS instance
  

My money's on the third (and fourth perhaps), which shouldn't be too
hard at all as the package manager is decent I'm told.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=106569

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2017-02-22 Thread nickb

meep wrote: 
> 
> The next stage of development for me is to implement pseudo-polling by
> implementing MQTT. This will hopefully eliminate the requirement for an
> open port, though I have some concerns about latency. And of course this
> will only be as secure as mqtt over https can be.
> 

Hi Meep. Interesting. I've played with MQTT and seemed simple / good -
let us know how it goes. Got a bit worried when starting to read 'this
very detailed review'
(http://vasters.com/archive/MQTT-An-Implementers-Perspective.html)
(though biased I guess) pointed out -so- many flaws with MQTT in the
general case.

Probably not so problematic for this/our type of usage I reckon. Note to
self: maybe websockets is worth another look...



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


Re: [SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2017-02-22 Thread nickb

pippin wrote: 
> Hm, how is this more secure than what Meep is doing?
> 

Hi Pippin. Great to open up this discussion. It's not intended as a
replacement / comparison to Meep's... more that there are some (other)
solutions out there which simply open up LMS directly (or use HTTP basic
auth) which is obviously a bad idea.

> 
> I mean... TLS and everything but this still requires you to open up your
> server machine to the internet and as security issues are this should at
> least involve staying up to date with known security issues in e.g. your
> TLS client on a daily basis because, you know, these big security issues
> that made the news in recent years were all about issues in security
> software like OpenSSL...
> 

I agree - patches are important, and yes for OpenSSL, as a key piece of
internet infrastructure it's scary and definitely in the firing line &
press often. To an extent that's why I'm advocating using -any- TLS TCP
proxy most suited to your server (if you can get one working - I've only
really tried stunnel) so you can choose.


> 
> So if such an issue shows up again (or it's not yet fixed on your NAS)
> you can fall victim to port scan attacks with such a setup. Not too
> likely but possible, some such bugs have been around (and used!) for
> years.
> 

Sure. We can guarantee routers / anything in the DMZ are getting
port-scanned anyway - the key is keeping those ports closed or secured
plus a certain (debatable!) level of obscurity, e.g. maybe don't expose
it on 443. The other key advice is to reduce the -impact- of a breach:
here this is not an SSH login, and shares no authentication mechanism
with the server OS - so the impact is limited to the LMS CLI (still bad
though). For further security around that you can enable built-in
user/pass auth on the LMS server - as it's DIY, it's up to the user to
decide.

> 
> I think the only thing being more secure is a solution where LMS only
> does outbound communication, that is: a plugin that connects to Alexa
> (or some intermediate service) and polls.
> 

For better or worse Alexa infra doesn't support incoming connections
(nor do AWS Lambdas), so you'd definitely need an intermediate server.
But traditional polling is probably not viable for a voice-prompted
service (where you want milliseconds of latency): the polling would need
to be too tight. With an intermediate service, a long-standing
connection / websocket might work and might be good to explore some
time, but the load (and cost) then goes up aggressively with the number
of registered users.

But: you still need to trust this intermediate service to control your
LMS... which is something I was uneasy about generally. Remember too -
-that- server is open to the internet on some port(s), probably /
hopefully uses TLS of some sort, and controls -everyone-'s LMS
instances.



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins


[SlimDevices: Plugins] Announce: squeeze-alexa - DIY secure Alexa integration

2017-02-21 Thread nickb

As mentioned a while ago, I've been developing (on and off) a DIY Alexa
Skill for Squeezebox integration and been using it successfully at home
for a while now.

Anyway - it's now improved and open-sourced on Github:

HTTPS://GITHUB.COM/DECLENSION/SQUEEZE-ALEXA

This is a separate approach from Meep's excellent work on hab-tunes (we
have discussed some common areas though). Currently it's definitely
techies only I'm afraid (no actual coding but you'll need to know a bit
of Linux, Networking, SSL... and have Amazon developer accounts). The
pay-off is it's optimised for speed and security I guess.

PS - I'm not on the forums much, so if you want to get in touch best to
do it via Github (or Twitter)



nickb's Profile: http://forums.slimdevices.com/member.php?userid=66261
View this thread: http://forums.slimdevices.com/showthread.php?t=107009

___
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins