Jump to content
  • 0

Authentication for RESTful endpoints


Giang Nam
 Share

Question

  • Answers 6
  • Created
  • Last Reply

Top Posters For This Question

6 answers to this question

Recommended Posts

  • 0
Hi giang,
Thank you for your interest. You can access rest service in localhost. You must log in to the server for other connections. You can also delete the rest auth filter according to the below tutorial information.

If you want to remove this rest filtering mechanism please remove the below lines from webapps-> {Application} -> WEBINF -> web.xml

<filter>    <filter-name>RestAuthenticationFiler</filter-name>    <filter-class>io.antmedia.serverapp.pscp.filter.RestAuthenticationFilter</filter-class></filter><filter-mapping>    <filter-name>RestAuthenticationFiler</filter-name>    <url-pattern>/rest/*</url-pattern></filter-mapping>

If you have any question, please feel free to ask us.

Best Regards,
Selim
Link to comment
Share on other sites

  • 0
Sorry Selim, 

I didn't get.. What is the right way to connect through api? Is there any token to get and pass to the request? 

I'm trying to create a broadcast following the documentation `/broadcast/create` but i don't understand the auth since in the documentation I couldn't see any reference to the authentication part. 

Could you elaborate more? 
Link to comment
Share on other sites

  • 0
Hi Denner,

Thank you for your feedback. We solved this situation in the new version. For now, you can remove the REST Filter for the application you are using.

For example; you want to access LiveApp Rest Service.

- You should edit SERVER_FOLDER/webapp/LiveApp/WEB-INF/web.xml

- You need to delete the following lines.

<filter>
    <filter-name>AuthenticationFilter</filter-name>
    <filter-class>io.antmedia.console.rest.AuthenticationFilter</filter-class>
  </filter>
 
  <filter-mapping>
  <filter-name>AuthenticationFilter</filter-name>
<url-pattern>/rest/*</url-pattern>
  </filter-mapping>
    
I'm hoping that I was able to answer your queries. If you have any question, please feel free to ask us. Thanks.

Best Regards,
Selim


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share


×
×
  • Create New...