3 Replies Latest reply on Jun 12, 2006 4:40 AM by Newsgroup_User

    LocalConnection.allowDomain

    Level 7
      Hi,

      Does anybody know if the 'allowDomain' method of the LocalConnection class
      actually works?
      If I create two movies and host them on different servers, they will not
      communicate even if I return
      true from the allowDomain method. They work fine if they share the same
      domain.

      Any help would be greatly appreciated.

      Thanks!

      Vince


        • 1. Re: LocalConnection.allowDomain
          ufitzi Level 1
          I'm not sure this is applicable, but for my remoting projects I have to create a XML file called crossdomain.xml, and place it in the webroot directory. The file has <allowdomain> tags that specify which domains/IP addresses can access the remoting classes on the server. This may or may not help your apply to your application. Good luck
          bh
          • 2. Re: LocalConnection.allowDomain
            Level 7
            Thanks for the suggestion. Unfortunately this didn't seem to have any
            affect.

            What I find particulary strange is that the allowDomain method doesn't seem
            to be called when the movies are hosted on different domains. I thought the
            whole point of this method was to determine whether or not the movie being
            accessed should grant permission to the movie trying to access it.

            I've tried relaxing all security by setting the allowDomain method of the
            System.security object to "*" and returning true from the allowDomain method
            of the LocalConnection object so that all domains have access however
            nothing
            seems to work.

            Does anybody know if there is something else I need to be doing in order to
            get
            this working? I can post the code I have for a simple test if required.

            Vince

            "ufitzi" <webforumsuser@macromedia.com> wrote in message
            news:e6c9gp$n0o$1@forums.macromedia.com...
            > I'm not sure this is applicable, but for my remoting projects I have to
            > create
            > a XML file called crossdomain.xml, and place it in the webroot directory.
            > The
            > file has <allowdomain> tags that specify which domains/IP addresses can
            > access
            > the remoting classes on the server. This may or may not help your apply
            > to
            > your application. Good luck
            > bh
            >


            • 3. Re: LocalConnection.allowDomain
              Level 7
              Problem solved. I overlooked a paragraph in the help which states that you
              need an underscore
              at the start of the connection id if you're trying to connect between 2 swfs
              across domains.

              "Vince" <webforumsuser@macromedia.com> wrote in message
              news:e6jgkv$ge7$1@forums.macromedia.com...
              > Thanks for the suggestion. Unfortunately this didn't seem to have any
              > affect.
              >
              > What I find particulary strange is that the allowDomain method doesn't
              > seem
              > to be called when the movies are hosted on different domains. I thought
              > the
              > whole point of this method was to determine whether or not the movie being
              > accessed should grant permission to the movie trying to access it.
              >
              > I've tried relaxing all security by setting the allowDomain method of the
              > System.security object to "*" and returning true from the allowDomain
              > method
              > of the LocalConnection object so that all domains have access however
              > nothing
              > seems to work.
              >
              > Does anybody know if there is something else I need to be doing in order
              > to get
              > this working? I can post the code I have for a simple test if required.
              >
              > Vince
              >
              > "ufitzi" <webforumsuser@macromedia.com> wrote in message
              > news:e6c9gp$n0o$1@forums.macromedia.com...
              >> I'm not sure this is applicable, but for my remoting projects I have to
              >> create
              >> a XML file called crossdomain.xml, and place it in the webroot directory.
              >> The
              >> file has <allowdomain> tags that specify which domains/IP addresses can
              >> access
              >> the remoting classes on the server. This may or may not help your apply
              >> to
              >> your application. Good luck
              >> bh
              >>
              >
              >