Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Streamproxy may use config.OpenWebif.auth_for_streaming #6

Closed
anudanan opened this issue Dec 28, 2018 · 5 comments
Closed

Streamproxy may use config.OpenWebif.auth_for_streaming #6

anudanan opened this issue Dec 28, 2018 · 5 comments

Comments

@anudanan
Copy link
Contributor

I have a little feature request for authentication of http transcoding streaming with streamproxy

When a user makes the openwebif config with HTTP auth true and HTTP streaming without auth, than streamproxy makes http streaming with auth instead of without auth. Streamproxy only shows the parameter config.OpenWebif.auth.

So I think it would be a better idea for streamproxy to show not only on Config.OpenWebIf.auth value, because there is a second Parameter config.OpenWebif.auth_for_streaming (default is false) which can be false also if OpenWebif.auth is true. Then a user can set auth for normal http openwebif and can user streaming without auth also for transcoding

@eriksl
Copy link
Owner

eriksl commented Dec 28, 2018

I have difficulty onderstanding this. Do you mean OWIF has a new parameter? What does it do?

@anudanan
Copy link
Contributor Author

Yes, it is a parameter for openwebif which comes up if http auth is true, then you can set http streaming with or without auth

@eriksl
Copy link
Owner

eriksl commented Dec 29, 2018

I still don't understand. I am not familiar with all inside stuff of OWIF. What-does-it-do!?

Beware that if enigma has been configured for authentication on streaming, streamproxy MUST also use authentication, it's a consequence of how it's implememented in enigma.

@anudanan
Copy link
Contributor Author

anudanan commented Dec 29, 2018

The OWIF has two parameters for http authentication

  • config.OpenWebif.auth: false/true (default false) is for authentication to the OWIF http port

  • config.OpenWebif.auth_for_streaming: false/true (default false), if config.OpenWebif.auth is true, here you can set the authentication for the http streaming over the streamingport different ot the OWIF normal port. Here I think that parameter must use by streamproxy to stream over the port for transcoding with the same streaming authentication as OWIF

In streamproxy.cpp

instead of

  if(settings.exists("config.OpenWebif.auth"))
  	if(settings.as_string("config.OpenWebif.auth") == "true")
  		config_map["auth"] = ConfigValue(true);
  	else
  		config_map["auth"] = ConfigValue(option_webifauth);
  else
  	config_map["auth"] = ConfigValue(option_webifauth);

take

  if(settings.exists("config.OpenWebif.auth"))
  	if(settings.as_string("config.OpenWebif.auth") == "true")
  		if(settings.as_string(config.OpenWebif.auth_for_streaming") == "true")
  			config_map["auth"] = ConfigValue(true);
  else
  	config_map["auth"] = ConfigValue(option_webifauth);

An other idea is to set the streamproxy auth identical to the streaming authentication parameter in the enigma settings

config.streaming.authentication

Do you know which parameter is used for http streaming to port 8001? The enigma parameter config.streaming.authentication or the openWBIF parameter config.OpenWebif.auth_for_streaming

I think one of both parameter (config.streaming.authentication oder config.OpenWebif.auth_for_streaming) is better than only use the OpenWebif.auth parameter for streamproxy. It depends on your idea if a user configure streamproxy auth with OWIF parameter or enigma parameter

@anudanan
Copy link
Contributor Author

It is now in the repo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants