Skip to main content
richard_anacion
Participant
February 28, 2015
Question

Allowed subnet mask IP

  • February 28, 2015
  • 1 reply
  • 1148 views

hi,

i have a code which is restrict publish from specified IP., if publisher is not 123.123.123.123 IP he cannot publish stream.

Now i want Subnet mask IP to allowed like 123.123.123.0/16.

application.onPublish = function(p_client, streamname){

     if (p_client.ip != "123.123.123.123"){

        application.disconnect(p_client);

    }

}

    This topic has been closed for replies.

    1 reply

    kglad
    Community Expert
    Community Expert
    February 28, 2015

    are you using flex?

    richard_anacion
    Participant
    March 1, 2015

    no. it is server side action script file main.asc in media server

    how do make a code for only alowed ip is from 123.123.123.0/24

    kglad
    Community Expert
    Community Expert
    March 2, 2015