Patent Description:
Computing functions normally provided by private hardware and/or software are increasingly being provided as publicly available network-based services. Example networks include the Internet. These network-based services are often referred to as cloud-based services. To access these network-based services, computing devices of users connect over the network to computing resources in one or more datacenters that provide the network-based services. Network-based services are attractive to users and organizations as both the initial costs and the total costs of setting up and operating these services are typically lower due to resource-sharing and economies of scale.

<CIT> discloses a system and method for optimized rendering of contact center services in a hybrid operations environment.

Communication services are also transitioning to network-based services. For example, telephony, online meetings, video sharing, screen sharing, and the like. These communication services are typically provided in a communication session which is established at a certain point in time to exchange media (such as audio, video, and the like) and then torn down at a later point in time. Network-based communication client applications on computing devices of users (either a dedicated application or through a browser) interface with the network-based communication service to manage sessions and media to allow users to make and receive phone calls and other communications with other client applications on other client devices. These communication sessions typically take place over a packet-switched network such as the Internet.

Network-based communication services may also allow users on the packet-switched network to make and receive phone calls with traditional telephones by interfacing with one or more telephone networks such as Public Switched Telephone Networks (PSTN). In these examples, the network-based communication service has hardware and/or software to connect with one or more telephone networks. The network-based communication service may translate a packet-based communication protocol such as SIP or HTTP used by the network-based communication client applications to protocols used by the telephone network (e.g., a protocol used by a PSTN - such as Signaling System No. <NUM> (SS7)). In some examples, the network-based communication service may also translate media from a format not supported by the telephone network (such as a PSTN) and used by the client applications to a format supported by the telephone network and back again.

Besides the aforementioned benefits of scale and resource sharing, the network-based communication services offer users the ability to communicate using the network-based service anywhere they have a connection to the network-based servers - which in many examples, will be anywhere they have an internet connection. Network-based communication services thus provide not only increased value in the centralization and management of the telephony equipment, but also in the flexibility to allow users to communicate from anywhere they have a network connection.

Some organizations want the flexibility of the network-based communication service; however, they may have agreements with a telephone carrier (such as a PSTN) which are more favorable to the organization than a network-based communication service can provide. In these examples, network-based communication services may provide a feature called direct routing. That is, client computing devices make calls by contacting servers of the network-based communication service (e.g., using a Hypertext Transfer Protocol Representational State Transfer (HTTP REST)). The network-based communication service initiates a signaling connection (usually using a Session Initiation Protocol (SIP)) with the organization's telephony equipment (typically a Session Border Controller (SBC)) which interfaces with the telephone network (e.g., PSTN) using the organization's agreements. Once the communication session is setup, the media may also travel through the network-based server which may process the media and send it to the organization's SBC which passes it along to the telephone network (PSTN). This ensures that users can still obtain the convenience of the network-based call service, but still uses the organization's preferred method of making and receiving calls.

As can be appreciated, sending the media across the Internet to the network-based communication service, only to send the media back to an organization's network may utilize additional network resources and may lead to increased latency. In some examples, once the communication is setup, rather than sending the media to the network-based communication service, the media may be sent directly from the client computing device to the organization's SBC. This is termed media bypass.

<FIG> illustrates a diagram <NUM> of a basic direct routing scenario with media bypass of a communication session between a client computing device <NUM> associated with a network-based communication service <NUM> and a second device <NUM> over a telephone network <NUM> according to some examples of the present disclosure. <FIG> shows the signaling and media flow for a communication between the client computing device <NUM> and a second device <NUM> over the telephone network <NUM>. The second device <NUM> may be a telephone, computing device, or other device that is configured to establish a communication session over the telephone network <NUM>. Client computing device <NUM> is a computing device (such as a desktop, laptop, smartphone, or the like) that executes a network-based communication service client application. Client computing device <NUM> exchanges messages (e.g., signaling messages) with the network-based communication service <NUM>. In some examples, the signaling uses a REST architecture over a Hypertext Transfer Protocol (HTTP). The signaling may be call setup signaling, user presence signaling or the like. Based upon these signaling messages, the network-based communication service <NUM> exchanges SIP signaling messages with the SBC <NUM>. Example SIP messages may include INVITE, RE-INVITE, OK, or other communication session setup, tear-down, or maintenance messages. SBC <NUM> exchanges any necessary signaling (not shown for clarity) with one or more devices of telephone network <NUM>.

Traditionally, media generated by the client computing device <NUM> would flow from the client computing device <NUM> to the network-based communication service <NUM>, to the SBC <NUM>, to the telephone network <NUM> and to second device <NUM>. Media generated by the second device would flow from the second device, to the telephone network <NUM>, to the SBC <NUM>, to the network-based communication service <NUM>, to the client computing device <NUM>.

In a bypass configuration, media flows directly between the client computing device <NUM> and the SBC <NUM>. The SBC <NUM> then forwards this to the telephone network <NUM> and to the second device <NUM>. During the call setup signaling, the client computing device <NUM> and the SBC provide IP addresses with which to establish a media session (e.g., such as a Real Time Protocol (RTP) session) and over which media associated with the communication session is sent. Media generated by the client computing device <NUM> is sent to the media IP address of the SBC <NUM> (and to the telephone network <NUM> and second device <NUM>) and media generated by the second device <NUM> arrives at the SBC <NUM> over the telephone network <NUM> and is sent to the media address of the client computing device <NUM>.

In many organizations, the SBC may be within a private network of the organization. Thus, media bypass directly to an organization's SBC requires the organization to open their firewall in their private network to allow traffic from any IP address (as user's may be anywhere in the world). If an organization is not comfortable opening their firewall up and allowing all connections to their SBC, the user's software application may default back to the traditional way of using the network-based communication service.

Media bypass is often preferred by organizations (e.g., businesses, groups, or other collections of individuals that setup a private network) to reduce latency and network resource usage. Despite this, in addition to the problem of opening up the SBC to outside traffic, various private network setups of these organizations also create issues. As used herein, an organizations private network refers to a private extranet or intranet that may be accessed only by authorized devices of the organization. These private networks allow for communication between these authorized devices and often utilize routing, protocols, and equipment similar to that of a publicly accessible networks such as the Internet. Communications between devices inside the private network and devices outside the private network are possible, but tightly controlled by firewalls and other access restrictions. Private networks of organizations may be organized into a plurality of sites. As used herein, a site is a network subdivision. Each network site may be a particular network subnet, network segment, or portion of either a private or a public network and may correspond to a particular geographic area. For example, a site in Germany for a private network may have a subnet of <NUM>. <NUM>/<NUM> and a site in France for a private network may have a subnet of <NUM>. <NUM>/<NUM>. A device on the Internet may be considered to be on a different network site than a device on the France site of the private network. In addition, while the private organizational network is connected to public networks, such as the Internet, they may be referred to herein as different networks and devices within the private network may be considered to be on a different site than devices on a public network (such as the Internet).

As noted previously, the organization may prefer that certain communication sessions utilize certain telephone network (e.g., PSTN) connections. These telephone network connections may be managed by an SBC in a particular network site. For example, an SBC in a network site in Germany may interface with a German telephone network and handle calls to/from German numbers. For security and other reasons, the organization may not want to make all of these SBCs publicly reachable from public networks. For those SBCs without publicly addressable IP addresses the network-based communication service may not be able to route the media and/or signaling through those SBCs and to their associated telephone networks.

Disclosed in some examples are methods, systems, and machine-readable mediums that allow a network-based communication service to control a signaling path and media flow within non-public networks for direct-routed network-based communication sessions (e.g., telephony). The signaling and media flow may be controlled by using SIP protocol extensions to specify both the signaling route and the media route.

When the communication session originates from the client computing device of the network-based communication service, the client computing devices communicate signaling information with the network-based communication service. The network-based communication service determines-based upon, for example, one or more of the phone number of the client computing device, the network location of the client computing device, or the phone number of the other party to the communication session-a primary SBC within the private network of the organization to handle the communication session. The network location may include whether the client computing device is in a public or private network and/or in what network site the client computing device is within.

For example, the primary SBC may be specified by a calling plan that specifies the SBC that interfaces with the preferred telephone network given the devices involved. If this primary SBC is not accessible to the network-based communication service, the network-based communication service determines a second SBC (called an intermediate SBC) that is both accessible to the network-based communication service and to the primary SBC (e.g., by the second SBC being in the private network, but accessible to the public network). In some examples, it may be said that the intermediate SBC is in both the private and public network. The network-based communication service exchanges signaling and session setup information (e.g., SIP signaling) with the intermediate SBC. The signaling and setup information informs the second SBC that the signaling should be forwarded to the primary SBC that is reachable by the second SBC but not the network-based communication service. For example, the primary SBC may be reachable via a private network connection between the first and second SBCs but may not have a public IP address and not reachable over a public network by the network-based communication service.

For calls originating via a telephone network, the primary SBC receives signaling related to the communication and is configured to forward it to an intermediate SBC. The network-based communication service determines the primary SBC from the signaling messages.

The network-based communication service determines a preferred media path and communications it via signaling information. The preferred media path may be determined based upon a network location of the primary SBC (including whether the network site is in a private or public network), a network location of the client computing device, and settings of the organization. The media may flow either directly between the primary SBC and the client computing device or between the primary SBC and the client computing device via the intermediate SBC.

<FIG> illustrates a diagram <NUM> of direct call routing with media bypass and media flow control where the client computing device is located in a same network site as the primary SBC according to some examples of the present disclosure. As used herein, a primary SBC is an SBC that interfaces with the telephone network and an intermediate SBC forwards signaling and/or media from the network-based communication service to the primary SBC.

This figure illustrates signaling and media flow for a communication between the client computing device <NUM> and a second device <NUM> through the telephone network <NUM>. First network site <NUM> and second network site <NUM> are different sites of a private network. Client computing device <NUM> exchanges signaling with the network-based communication service <NUM>. In some examples, the signaling uses an HTTP REST architecture. This signaling may travel across one or more network sites of the private network to reach the network-based communication service <NUM> which is in a public network (e.g., the Internet). Client computing device <NUM> is located within (e.g., connected with and reachable in) the second network site <NUM>. The signaling may be call setup signaling, user presence signaling or the like.

Network-based communication service <NUM> uses a network address of the client computing device <NUM> to determine that client computing device <NUM> is within the second network site <NUM>. An administrator of the organization may provide one or more network address ranges that identify particular network sites. For communications originating with the client computing device, the network-based communication service <NUM> may determine where to route the signaling for completing the communication based upon one or more of the phone number of the client computing device, the network location of the client computing device, or a phone number of the other party to the communication session. In <FIG>, it is determined that the signaling for the communication session is to be routed to the second SBC <NUM> (called the primary SBC) via first SBC <NUM> (an intermediate SBC) in a first network site <NUM>.

The network-based communication service <NUM> then sends SIP messaging to first SBC <NUM> with instructions (e.g., in the form of SIP protocol extensions) informing the first SBC <NUM> to forward the SIP signaling to the second SBC <NUM>. In some examples, the signaling is simply forwarded by the first SBC <NUM>, but in other examples, the first SBC <NUM> terminates the SIP session with the network-based communication service <NUM> and establishes a concurrent session with the second SBC <NUM>. The second SBC <NUM> then exchanges any necessary signaling (not shown for clarity) with one or more devices of telephone network <NUM>.

For calls originating with a device associated with the telephone network, the SBC which receives the call from the telephone network takes the role of the primary SBC. In <FIG>, this is second SBC <NUM>. The organization configures one or more intermediate SBCs for each of the primary SBCs. The second SBC <NUM> notifies the network-based communication service <NUM> of the communication (based upon the phone number of the client computing device <NUM> being associated with the network-based communication service <NUM>) via the assigned intermediate SBC (first SBC <NUM>). The network-based communication service <NUM> then identifies the primary and intermediate SBCs based upon this signaling sent by the intermediate SBC.

During the call setup signaling, the client computing device <NUM> is provided an IP address to send outgoing media to and likewise the client computing device <NUM> provides an IP address that will receive incoming media to the primary SBC. The media address provided to the client computing device <NUM> depends on the reachability of the second SBC <NUM> to client computing device <NUM> as well as settings of the private network. In the example of <FIG>, since the client computing device is within a same private network site as the second SBC <NUM>, the media is directly sent to the second SBC <NUM> from the client computing device <NUM>. Second SBC <NUM> then forwards the media to the telephone network <NUM> which forwards the media to the second device <NUM>. Likewise, media from the second device <NUM> is sent to the second SBC <NUM> over the telephone network <NUM> which forwards it to the client computing device.

<FIG> illustrates a diagram <NUM> of direct call routing with media bypass and media flow control where the client computing device is located in a different private network site than the primary SBC according to some examples of the present disclosure. The figure illustrates signaling and media flow for a communication between the client computing device <NUM> and a second device <NUM> over the telephone network <NUM>. First network site <NUM>, second network site <NUM>, and third network site <NUM> are different sites of a private network. Client computing device <NUM> exchanges signaling with the network-based communication service <NUM>. In some examples, the signaling uses a HTTP REST architecture. This signaling may travel across one or more private network sites owned by the organization to reach the network-based communication service <NUM>. Client computing device <NUM> is located within (e.g., connected with and reachable in) a third network site <NUM>. The signaling may be call setup signaling, user presence signaling or the like.

Network-based communication service <NUM> uses a network address of the client computing device <NUM> to determine that client computing device <NUM> is within the third network site <NUM>. For example, the network-based communication service may utilize a network address of the client computing device <NUM> identified during the signaling. An administrator of the organization may provide one or more network address ranges that identify particular private network sites. For communications originating with the client computing device, the network-based communication service <NUM> may determine where to route the signaling for completing the communication based upon one or more of the phone number of the client computing device, the network location of the client computing device, or a phone number of the other party to the communication session. In <FIG>, it is determined that the signaling for the communication session is to be routed to the second SBC <NUM> (called the primary SBC) via first SBC <NUM> (an intermediate SBC) in a first network site <NUM>.

The network-based communication service <NUM> then sends SIP messaging to the first SBC <NUM> with instructions (e.g., protocol extensions) informing the first SBC <NUM> to forward the SIP signaling to the second SBC <NUM>. In some examples, the signaling is forwarded by the first SBC <NUM>, but in other examples, the first SBC <NUM> terminates the SIP session with the network-based communication service <NUM> and establishes a concurrent session with the second SBC <NUM>. The second SBC <NUM> then exchanges any necessary signaling (not shown for clarity) with one or more devices of telephone network <NUM>.

For incoming calls, the SBC which receives the call from the telephone network takes the role of the primary SBC and the organization configures intermediate SBCs for each of the primary SBCs. In <FIG>, the primary SBC is the second SBC <NUM> and the intermediate SBC is first SBC <NUM>. The second SBC <NUM> notifies the network-based communication service <NUM> of the communication via first SBC <NUM>. The second SBC <NUM> knows that the client computing device <NUM> is associated with the network-based communication service based upon the phone number of the client computing device <NUM> being associated with the network-based communication service <NUM>. The network-based communication service <NUM> then identifies the primary and intermediate SBCs based upon this signaling sent by first SBC <NUM>.

During the call setup signaling, the client computing device <NUM> is provided an IP address to send outgoing media to and likewise the client computing device <NUM> provides an IP address that will receive incoming media to the second SBC <NUM>. The media address provided to the client computing device <NUM> depends on the reachability of the second SBC <NUM> to client computing device <NUM> as well as settings of the private network. In the example of <FIG>, while the client computing device <NUM> is not within the same private network site, the client computing device <NUM> is still within the private network and thus the second SBC <NUM> may be reachable (e.g., addressable) by the client computing device <NUM>. In <FIG>, the media settings of the private network allow a direct connection between devices in the third network site <NUM> and the second network site <NUM>. In these examples, the network-based communication service <NUM> provides the network address (e.g., an internal or external IP address) of the second SBC <NUM> to the client computing device <NUM>. Client computing device <NUM> sends media directly to the second SBC <NUM>. SBC <NUM> then forwards the media to the telephone network <NUM> which delivers it to second device <NUM>. Likewise, media from the second device <NUM> is sent to the primary SBC which forwards it to the client computing device.

<FIG> illustrates a diagram <NUM> of direct call routing with media bypass and media flow control where the client computing device is located in a different network site than the primary SBC and the primary SBC is either not reachable or media settings of the private network do not allow media bypass according to some examples of the present disclosure. The figure illustrates signaling and media flow for a communication between the client computing device <NUM> and a second device <NUM> connected to the telephone network <NUM>. First network site <NUM>, second network site <NUM>, and third network site <NUM> are different sites of a private network. Client computing device <NUM> exchanges signaling with the network-based communication service <NUM>. In some examples, the signaling uses a HTTP REST architecture. This signaling may travel across one or more network sites owned by the organization. Client computing device <NUM> is located within (e.g., connected with and reachable in) a third network site <NUM>. The signaling may be call setup signaling, user presence signaling or the like.

Network-based communication service <NUM> uses a network address of the client computing device <NUM> to determine that client computing device <NUM> is within the third network site <NUM>. An administrator of the organization may provide one or more network address ranges that identify particular private network sites. For communications originating with the client computing device, the network-based communication service <NUM> may determine where to route the signaling for completing the communication based upon one or more of the phone number of the client computing device, the network location of the client computing device, or a phone number of the other party to the communication session. In <FIG>, it is determined that the signaling for the communication session is to be routed to the second SBC <NUM> (called the primary SBC) via first SBC <NUM> (an intermediate SBC) in a first network site <NUM>.

The network-based communication service <NUM> then sends SIP messaging to the first SBC <NUM> with instructions (e.g., in the form of SIP protocol extensions) informing the first SBC <NUM> to forward the SIP signaling to the second SBC <NUM>. In some examples, the signaling is forwarded, but in other examples, the first SBC <NUM> terminates the SIP session with the communication service <NUM> and establishes a concurrent session with the second SBC <NUM>. SBC <NUM> then exchanges any necessary signaling (not shown for clarity) with one or more devices of telephone network <NUM>.

For incoming calls, the SBC which receives the call from the telephone network takes the role of the primary SBC and the organization configures intermediate SBCs for each of the primary SBCs. In <FIG>, the primary is the second SBC <NUM> and the intermediate SBC is the first SBC <NUM>. The second SBC <NUM> notifies the network-based communication service <NUM> of the communication (based upon the phone number of the client computing device <NUM> being associated with the network-based communication service <NUM>) via the first SBC <NUM>. The network-based communication service <NUM> then identifies the primary and intermediate SBCs based upon this signaling sent by the intermediate SBC.

During the call setup signaling, the client computing device <NUM> is provided an IP address to send outgoing media to and likewise the client computing device <NUM> provides an IP address that will receive incoming media to the second SBC <NUM>. The media address provided to the client computing device <NUM> depends on the reachability of the second SBC <NUM> to client computing device <NUM> as well as organizational settings.

In the example of <FIG>, the second SBC <NUM> is either not reachable by the client computing device <NUM> or media settings do not allow the bypass connection between the two private network sites. In these examples, the network-based communication service <NUM> provides the network address (e.g., an internal or external IP address) of the first SBC <NUM> to the client computing device <NUM>. Client computing device <NUM> sends media to the first SBC <NUM> (e.g., over a public network), who forwards it to the second SBC <NUM>. Second SBC <NUM> then forwards the media to the telephone network <NUM> which forwards it to the second device <NUM>. Likewise, media from the second device <NUM> is sent to the second SBC <NUM> which forwards it to the first SBC <NUM>, which forwards it to the client computing device <NUM>.

<FIG> illustrates a diagram <NUM> of direct call routing with media bypass and media flow control where the client computing device is located on a network site outside the private network of the organization according to some examples of the present disclosure. The figure illustrates signaling and media flow for a communication between the client computing device <NUM> and a second device <NUM> connected to the telephone network <NUM>. First network site <NUM> and second network site <NUM> are different sites of a private network. Client computing device <NUM> is on a public network and exchanges signaling with the network-based communication service <NUM>. In some examples, the signaling uses a HTTP REST architecture. Client computing device <NUM> is not located within (e.g., connected with and reachable in) a network site of the private network of the organization, but is within a public network site. The signaling may be call setup signaling, user presence signaling or the like.

Network-based communication service <NUM> uses a network address of the client computing device <NUM> to determine that client computing device <NUM> is not within a network site of the private network of the organization. An administrator of the organization may provide one or more network address ranges that identify particular private network sites of the organization. If the client computing device's IP address is not within a designated site, the network-based communication service <NUM> determines that the client computing device <NUM> is external to the organization. For example, on the public Internet. For communications originating with the client computing device, the network-based communication service <NUM> may determine where to route the signaling for completing the communication based upon one or more of the phone number of the client computing device, the network location of the client computing device, or a phone number of the other party to the communication session. In <FIG>, it is determined that the signaling for the communication session is to be routed to the second SBC <NUM> (called the primary SBC) via first SBC <NUM> (an intermediate SBC) in a first network site <NUM>.

The network-based communication service <NUM> then sends SIP messaging to the first SBC <NUM> with instructions (e.g., protocol extensions) informing the first SBC <NUM> in a first network site <NUM> to forward the SIP signaling to the second SBC <NUM>. In some examples, the signaling is forwarded, but in other examples, the first SBC <NUM> terminates the SIP session with the network-based communication service <NUM> and establishes a concurrent session with the second SBC <NUM>. The second SBC <NUM> then exchanges any necessary signaling (not shown for clarity) with one or more devices of telephone network <NUM>.

For incoming calls, the SBC which receives the call from the telephone network takes the role of the primary SBC and the organization configures intermediate SBCs for each of the primary SBCs. In <FIG> the primary SBC is the second SBC <NUM> and the intermediate SBC is the first SBC <NUM>. The second SBC <NUM> notifies the network-based communication service <NUM> of the communication (based upon the phone number of the client computing device <NUM> being associated with the network-based communication service <NUM>) via the first SBC <NUM>. The network-based communication service <NUM> then identifies the primary and intermediate SBCs based upon this signaling sent by the intermediate SBC.

During the call setup signaling, the client computing device <NUM> is provided an IP address to send outgoing media to and likewise the client computing device <NUM> provides an IP address that will receive incoming media to the second SBC <NUM>. The media address provided to the client computing device <NUM> depends on the reachability of the second SBC <NUM> to client computing device <NUM> as well as organizational settings. In the example of <FIG>, the second SBC <NUM> is either not reachable by the client computing device <NUM> or media settings do not allow the direct connection. In these examples, the network-based communication service <NUM> provides the network address (e.g., an internal or external IP address) of the first SBC <NUM> to the client computing device <NUM>. Client computing device <NUM> sends media to the first SBC <NUM>, who forwards it to the second SBC <NUM>. Second SBC <NUM> then forwards the media to the telephone network <NUM> which forwards it to the second device <NUM>. Likewise, media from the second device <NUM> is sent to the second SBC <NUM> which forwards it to the first SBC <NUM>, which forwards it to the client computing device <NUM>.

Media sent by the client computing device may include media captured by a microphone of the client computing device, media captured by a video camera of the client computing device, screen sharing data of the client computing device, previously recorded media stored by the client computing device, or the like. Likewise, media sent to the client computing device may include media captured by a microphone of the second device, media captured by a video camera of the second device, screen sharing data of the second device, previously recorded media of the second device, or the like.

As noted above, the organization's private network media settings may impact the route media takes during a communication session. In particular, a media path mode setting may determine the media path of a particular communication. A first mode is an "always bypass" mode. In this mode, if the client computing device is on the private network of the organization, media will be sent to media address provided by the primary SBC. This is shown in <FIG> and <FIG>. If the client computing device is on an external site (e.g., a public network), media is sent to the intermediate SBC and then forwarded to the primary SBC (e.g., sent to the primary SBC). This is shown in <FIG>. A second mode is "OnlyForLocalUsers" which means that if the client computing device is in a same private network site of the organization as the primary SBC, media will be sent directly to the primary SBC. This is shown in <FIG>. In this mode, if the client computing device is either in a different private network site of the organization, or an external network site (e.g., a public network), media is sent to the intermediate SBC and then forwarded to the primary SBC. This is shown in <FIG> and <FIG>.

To set a media path optimization mode, in some examples, an administrator enters a command to set a flag in each SBC in the private network. That is, the media path optimization mode may be specific to each SBC and specific to network sites. Thus, in some examples, if the administrator of the private network believes that the internal connection between two different network sites is strong enough, the administrator may set the media path optimization to "always bypass. " If the administrator feels that the internal connection between two other sites is less strong, the administrator may set the media path optimization to "OnlyForLocalUsers. " These settings may be communicated to the network-based communication service.

For example, consider a company that has a centralized SBC in an Amsterdam network site. This SBC serves <NUM> countries and has good connectivity between all these <NUM> network sites and local users of the organization. Also, there is a branch in Hungary where a local SBC is deployed. In this case the SBCs in Hungary can configured in "Always Bypass" mode for all other private network sites. Regardless of the location of the client computing device within the private network, the computing devices can connect to the SBC directly (for example from Germany to Hungary). On the other hand, if the Hungarian site does not have a good connection with the German location, the administrator can use the flag "OnlyForLocalUsers" for that connection. The media flows via the Amsterdam SBC if the user happens to be in Germany when connecting to the Hungarian SBC.

As noted, when using one SBC as an intermediate for another SBC, the intermediate SBC is informed of the primary SBC of the signaling and the media path through signaling messages. On example method of informing the intermediate SBC is through SIP protocol extensions. These extensions are added by the network-based communication service to SIP Invites and Re-Invite messages for calls originating with the client computing devices and <NUM> OK messages for calls originating from the telephone network. The first extension (e.g., X-MS-UserLocation) specifies whether the client computing device is located on a private network of the organization or an external network. There are two possible values that are represented - one is "internal" the other is "external. " The Request-URI for the invite and re-invite messages are overloaded to include the fully qualified domain name (FQD) of the primary SBC even if the SBC is not directly connected to the network-based communication service. The intermediate SBC knows from the FQD to forward the message to the primary SBC. The next extension is an indication of an order of SBC that should be used for the media path (X-MS-MediaPath). The third extension is an identification of the user's home private network site as defined by the organization's administrator (X-MS-UserSite).

<FIG> illustrates a method <NUM> performed by a network-based communication service according to some examples of the present disclosure. At operation <NUM> the network-based communication service may determine that a communication is to be setup between a first computing device (a client computing device) executing a client application of the network-based communication service and a second device, the communication session routed partially over a telephone network. The first computing device may be associated with the network-based communication service such that communications for that device are routed to the network-based communication service. Determining that the communication is to be set up may be based upon one or more signaling messages. In some examples, this may be a communication initiated by the first computing device - e.g., an outgoing call. That is, the first computing device may send a request to the network-based communication service to initiate the communication. In other examples, this may be determined based upon a message received from an SBC indicating that the second device is attempting to setup a communication session with the first computing device - e.g., an incoming call. For example, the network-based communication service may receive a SIP INVITE message for the phone number associated with the first computing device.

At operation <NUM> the network-based communication service may determine a network location where the first computing device is located. As previously noted, the network location may include a network site and/or whether the first computing device is within an organization's private network or whether the first computing device is within a public network. For example, the network site may be determined based upon a network address such as an IP address of the first computing device. In some examples, the network site may be in a first network or a second network. For example, a first network such as the Internet or a second network - such as an organization's private network. The network-based communication service may store records that indicate sites within an organization's private network and IP address ranges that belong to those sites. If the IP address of the first computing device is within one of those locations, the network site is identified as a private network site based upon the IP address. If the IP address of the first computing device is not within one of those locations, the location is an external site to the organization.

At operation <NUM>, the network-based communication service may identify a primary session border controller to interface with the telephone network during the communication session, the primary SBC not reachable directly by the network-based communication service. That is, the primary SBC may not be setup to accept connections from the network-based communication service. For example, the first SBC is not reachable over a first network (e.g., the Internet). As an example, the primary SBC may not have an address in the first network (e.g., a publicly routable IP address), but instead may have an organization specific address in a second network. In other examples, a firewall may prevent connections to the primary SBC. For inbound calls to the first computing device, the primary SBC may be identified based upon the invite message sent by an intermediate SBC that is reachable by the network-based communication service.

For outbound calls from the first computing device to the second device, the primary SBC may be selected by the network-based communication service based upon the network location of the first computing device, a phone number of the first computing device and the phone number of the second device. For example, a call policy specified by an administrator of the organization may specify a signaling route for particular combinations of network sites and phone number. An example row of a call policy for the network of <FIG> when client computing device <NUM> is one of the calling parties (with a phone number of +<NUM><NUM><NUM><NUM>) and the phone number of the second device is +<NUM><NUM><NUM><NUM>:.

By first selecting all the rows with matching network sites of the first computing device determined at operation <NUM>, then selecting, from those results, the row that matches both the second device phone number and the first computing device phone number, the communication routing policy may be returned. There may be multiple routes listed with an indication as to which to try first. For example, priority <NUM> routes are tried first. If the communication cannot be setup on that route, then priority <NUM> routes are tried, and so on. The communication routing policy includes a SIP address that contains the called parties phone number and the fully qualified domain name of the primary SBC.

By allowing for granular control of which SBCs handle the communication session based upon the user network location, the user's network address, and the second device's phone number, the system may allow for greater flexibility in allowing the organization to specify the correct primary SBCs (and thus the correct telephone network connection) to most optimally handle communication sessions as an organization may have contracts with multiple telephone networks that may have different fee arrangements depending on the calling party and the called party. For example, a telephone network (e.g., PSTN) in Vietnam may charge less for handling communication sessions for local numbers than another telephone may charge for those numbers. Thus, the organization may wish to route those calls to the Vietnamese telephone network by routing them to a particular SBC that terminates the connection with the telephone network.

At operation <NUM>, the network-based communication service may identify an intermediate SBC as the primary SBC may not be reachable by the network-based communication service. That is, the primary SBC is not reachable by the network-based communication service e.g., it is not reachable over a first network - such as the Internet - on which the network-based communication service resides. For example, the primary SBC may not have a publicly addressable IP address. Instead the primary SBC may have an IP address that is internal to an organization (e.g., a private network or Intranet) and/or the organization's private network structure may not permit outsiders to access this address. For inbound calls, the intermediate SBC may be identified in the SIP invite message sent by the intermediate SBC. For outgoing calls, prespecified network configurations allow identification of an intermediate SBC that is addressable to the network-based communication service and is also capable of addressing the primary SBC (e.g., over a second network such as the organization's private network). In some examples, the intermediate SBC is reachable over the first network by the network-based communication service and the primary SBC is reachable by the intermediate SBC over a second network (e.g., a private network).

At operation <NUM> a media path for the communication session is determined. The determination may be made based upon one or more of the network location of the first computing device, the primary SBC (and in particular the network site of the primary SBC), or a media mode of the primary SBC. For example, the following table may be utilized:.

At operation <NUM>, the network-based communication service may cause establishment of the communication session by transmitting one or more signaling messages between the network-based communication service and the first SBC through the second SBC, the signaling instructing the first and second SBCs to use the determined media path. For example, for outbound calls, the network-based communication service may send a SIP invite request to the intermediate SBC with the second device's phone number with an additional tag indicating a fully qualified domain name of the primary SBC - for example, "+<NUM>@sbc1. " This instructs the intermediate SBC that the intermediate SBC is to act as a relay and send the SIP signaling to the primary SBC (SBC1).

Additionally, the SIP invite may include one or more protocol extensions to specify whether the first computing device is internal or external to the organization's network; the media path of the media; and a site that the user is currently connected to. In other examples, for inbound calls, the SIP message OK may include the network site of the first computing device, the media path, and a network address to send media to the first computing device.

<FIG> illustrates a flowchart of a method <NUM> of an intermediate SBC handling a communication session originated by a first computing device associated with the network-based communication service and to a second device through a telephone network connected to the primary SBC according to some examples of the present disclosure. At operation <NUM> the SBC may receive a signaling message from a network-based communication service. The signaling message may be a request to setup a communication session between a first computing device associated with the network-based communication service and a second device. In some examples, the signaling message may be a SIP invite message. The SIP invite message may include a phone number of the first computing device (e.g., phone number), an identifier of a primary SBC that is to process the communication session, an indication of whether the first computing device is within a same network as the SBC, a media path, an identifier of a network site of the first computing device and a media address of the first computing device.

At operation <NUM> the SBC may determine that the signaling message includes an indication to establish signaling with a primary SBC. That is, the SBC is communicating with a primary SBC on behalf of the network-based communication service. At operation <NUM> the SBC may establish signaling with the primary SBC. This may comprise forwarding the signaling between the network-based communication service and the primary SBC, including the message received at operation <NUM>. In other examples, the SBC may setup a first signaling session (e.g., a SIP session) between the SBC and the network-based communication service and a second separate signaling session (e.g., a SIP session) between the SBC and the primary SBC. Messages received from the second SBC on the second signaling session are sent to the network-based communication service over the first signaling session and messages received from the network-based communication service over the first signaling session are sent to the primary SBC over the second signaling session. If the SBC is in the media path, then a media session is established with the first computing device and the second SBC. At operation <NUM> the SBC may forward media packets between the primary SBC and the first computing device.

In some examples, communications between the SBC and the network-based communication service may be over a different network or network portion than communications between the SBC and the primary SBC. For example, the communications between the SBC and the network-based communication service may be over the Internet (to an external network site), whereas communications between the SBC and the primary SBC may be within an organization's private network (an internal network site). In some examples, the communications between the SBC and the network-based communication service may utilize Internet accessible IP addresses. In some examples, the communications between the SBC and the primary SBC may be over an intranet or other private network and may involve private network addresses such as private IP addresses. That is, the SBC may have both a public, internet accessible IP address, and a network address on the private network. The public, internet accessible IP address is used with communications to the network-based communication service and the private network address (e.g., private IP address) may be used with communications between devices within the private network (such as communications between the primary SBC and the SBC).

<FIG> illustrates a flowchart of a method <NUM> of an intermediate SBC handling a communication session originated by a second device through a telephone network (e.g., PSTN) associated with a primary SBC and to a first computing device associated with a network-based communication service according to some examples of the present disclosure. At operation <NUM> the intermediate SBC may receive a signaling message from a primary SBC. For example, a SIP INVITE message with a phone number of the first computing device. The invite may also include a domain name of the primary SBC and a media address to send media to. The primary SBC may indicate that the signaling message is for the first computing device and that the first computing device is associated with the network-based communication service. In other examples, the intermediate SBC may determine from the phone number of the first computing device that was received with the signaling message at operation <NUM> and from one or more location registers or other databases that the first computing device is associated with the network-based communication service.

At operation <NUM>, the intermediate SBC may determine that the signaling message includes an indication to establish a signaling connection with a network-based communication service on behalf of the primary SBC. The intermediate SBC may be configured to act as the intermediate SBC on communication sessions between one or more primary SBCs and the network-based communication service. For example, an administrator of the organization may indicate that particular SBCs are to act as intermediate SBCs for other SBCs (primary SBCs) for communication sessions involving computing devices associated with the network-based communication service. These settings may be stored in a setting data structure on one or more SBCs (e.g., intermediate SBCs and/or primary SBCs).

At operation <NUM>, the SBC may establish a signaling connection with the network-based communication service on behalf of the second SBC. As previously noted, this may involve simply forwarding the messages or may involve two separate signaling sessions. If the intermediate SBC is part of the media path, then at operation <NUM> the intermediate SBC forwards media packets to and from the second SBC and the first computing device.

<FIG> illustrates a flowchart of a method <NUM> of a primary SBC handling a communication session originated by a first computing device associated with the network-based communication service and to a second device through a telephone network (e.g., PSTN) connected to the primary SBC according to some examples of the present disclosure. At operation <NUM>, the primary SBC receives a signaling message from an intermediate SBC. For example, the intermediate SBC may be passing signaling messages from a network-based communication service to the primary SBC. The signaling message may be a SIP invite message including a phone number of the caller (first computing device) and a media address of the caller. The primary SBC may contact the telephone network and forward the communication session request to the called device over the telephone network. Once a response is received from the telephone network, at operation <NUM>, the primary SBC may respond to the network-based communication service via the intermediate SBC. For example, by transmitting a SIP message confirming the connection (e.g., a <NUM> OK or a <NUM> Ringing message) to the second SBC, which then retransmits that message to the network-based communication service. The SBC may provide a media address to the network-based communication service within the response. At operation <NUM> the SBC may finish establishing the communication session between the first computing device and the second device. Media from the communication session being sent and received over the media path.

<FIG> illustrates a flowchart of a method <NUM> of a primary SBC handling a communication session originated by a second device through a telephone network and to a first computing device associated with a network-based communication service according to some examples of the present disclosure. At operation <NUM>, the remote SBC identifies an incoming communication session setup request for a first computing device. For example, a message may be received over a telephone network indicating that a communication session is desired between a second device on the telephone network and the first computing device serviced by the network-based communication service.

At operation <NUM>, the primary SBC may determine that the first computing device is serviced by a network-based communication service that is not reachable by this SBC but may be reached by an intermediate SBC. For example, the primary SBC may have access to a list of phone numbers associated with the network-based communication service. Based upon the phone number of the first computing device, the primary SBC may determine that the phone number is associated with the network-based communication service. Additionally, the primary SBC may be configured to forward communication session setup and signaling for client computing devices of the network-based communication service to a particular intermediate device by one or more SBC settings.

At operation <NUM> the primary SBC may setup a signaling connection between the primary SBC and the network-based communication service via the intermediate SBC. For example, the primary SBC may send a SIP invite message with a "from" field set to the second device's phone number with a domain name of the primary SBC appended to the end. Additionally, the primary SBC may provide a media address to the network-based communication service through the intermediate SBC. The media address may be provided in one or more signaling messages sent to the network-based communication service via the intermediate SBC.

At operation <NUM> the communication session may be established between the first computing device and the second device. Media from the communication session may be sent over the media path, which includes the primary SBC. In some examples, where the first computing device is on a same network site as the primary SBC, the first computing device may directly send the media to the primary SBC. In other examples, where the first computing device is external to the organization's private network, the first computing device may send media to the intermediate SBC which may forward the media to the primary SBC. In yet other examples, where the first computing device is within a different network site of the organization's private network than the primary SBC, whether the media is sent directly to the primary SBC or sent via the intermediate SBC depends on the settings of the primary and/or intermediate SBC.

<FIG> illustrates a diagram of a SIP message flow <NUM> for a communication session initiated by a first computing device <NUM> associated with the network-based communication service <NUM> to a second device through a telephone network according to some examples of the present disclosure. First computing device <NUM> is in a first network site (either within the private network of an organization or external to the private network in a public network) and sends a call notification message <NUM> (e.g., over a HTTP REST protocol) to the network-based communication service <NUM> with the location of the first computing device indicated as site <NUM> (e.g., either via an explicit indication in the message or the user's location is determinable via an IP address). The network-based communication service <NUM> then determines a primary SBC to handle the communication based upon the phone number of the first computing device, the location of the first computing device, the phone number of the called device (e.g., second device) and a call policy of the organizational network. The network-based communication service <NUM> may identify the organizational network based upon the phone number of the first computing device <NUM> as belonging to the organization and may retrieve the call policy from a database.

In the example of <FIG>, the primary SBC <NUM> is chosen. The network-based communication service <NUM> may determine that the primary SBC <NUM> is not directly reachable. For example, the primary SBC <NUM> may be located on a second network that is different than a first network which the network-based communication service <NUM> is located. Where the first computing device <NUM> is in a private network site of the organization, the first computing device <NUM> also includes a connection to the public network. The network-based communication service <NUM> may consult configuration settings for communications into the organization's network to determine that primary SBC <NUM> is reachable via intermediate SBC <NUM>. The network-based communication service <NUM> then sends a SIP Invite message <NUM> to the intermediate SBC <NUM>. The SIP invite message <NUM> may include the phone number of the second device (the called party), whether the first computing device <NUM> is located on a network that is internal or external to the organization of the SBC, a media path, a user network site, and a media address of the first computing device <NUM>. For example, these fields may be sent as protocol extensions. The network-based communication service may determine the media path based upon the network site of the first computing device (including whether the first computing device is on a network site internal or external to the organization), the primary SBC (and in particular the network site of the primary SBC), and a media mode of the primary SBC. In some examples, the domain address of the primary SBC is included as part of the phone number of the second device. For example, +<NUM>@primarysbc.

Intermediate SBC <NUM> receives the SIP invite message <NUM> and determines from the message (e.g., the phone number of the second device with the domain name of primarysbc. com) that the message is for primary SBC <NUM>. The intermediate SBC <NUM> sends the SIP invite to the primary SBC <NUM>. In some examples, the invite <NUM> may not include all the fields included in the SIP invite <NUM>. For example, the domain address of the primary SBC <NUM> may be stripped from the phone number of the called party, and the location, media path, and user site may not be included in the SIP INVITE.

Primary SBC <NUM> responds with a SIP <NUM> Ringing message, which is forwarded <NUM> by intermediate SBC <NUM> to the network-based communication service <NUM>. In some examples, this may then be relayed to the first computing device <NUM> using message <NUM>.

When the user answers, the primary SBC <NUM> sends a <NUM> OK message <NUM> with the media address of the primary SBC <NUM> to the intermediate SBC <NUM>. Intermediate SBC <NUM> sends a <NUM> OK message <NUM> with the media IP address of the Primary SBC <NUM> to the network-based communication service <NUM>. Network-based communication service <NUM> may send a <NUM> OK message <NUM> with the media address of the primary SBC <NUM> to the first computing device <NUM>. Ack messages <NUM>, <NUM>, and <NUM> are then sent from the first computing device <NUM> to the primary SBC <NUM> through both the network-based communication service <NUM> and intermediate SBC <NUM>.

A Real Time Transfer Protocol (RTP) session may then be established to transfer the media during the communication session. In examples in which the first computing device <NUM> is in a same private network site as (e.g., local to) the primary SBC <NUM>, the RTP session <NUM> may be used which is a direct connection to the primary SBC <NUM>. In examples in which the first computing device <NUM> is not in a same private network site as the Primary SBC <NUM> but within the organization's private network, and the organization has a media path setting allowing bypass always mode, the RTP session <NUM> may be used which is a direct connection to the primary SBC <NUM>. In examples in which the first computing device <NUM> is not in a same private network site as the primary SBC <NUM> but within the organization's private network, and the organization has a media path setting requiring local only mode, the RTP sessions <NUM> and <NUM> may be used which sends media to the intermediate SBC <NUM> which then forwards it to the primary SBC <NUM>. In examples in which the first computing device <NUM> is in an external network site to the organization's private network the RTP sessions <NUM> and <NUM> may be used which sends media to the intermediate SBC <NUM> which then forwards it to the primary SBC <NUM>. In some examples two different RTP sessions are opened (e.g., a first session <NUM> and a second session <NUM>), but in other examples, the intermediate SBC <NUM> merely forwards the RTP messages.

<FIG> illustrates a diagram of a SIP message flow <NUM> for a communication session initiated by a second device through a telephone network to a first computing device <NUM> associated with the network-based communication service <NUM> according to some examples of the present disclosure. Primary SBC <NUM> receives a call request from a telephone network. The primary SBC <NUM> may determine that the phone number of the called party (the first computing device <NUM>) corresponds to the network-based communication service <NUM>. In response, the primary SBC <NUM> sends a SIP invite message <NUM>. The SIP invite message <NUM> may include the phone number of the second device (calling device) and may have the domain (fully qualified domain - FQD) of the primary SBC <NUM> appended to it along with the media address of the primary SBC <NUM>. The primary SBC <NUM> may determine an intermediate SBC <NUM> based upon settings of the organization. For example, the organization may have designated the intermediate SBC <NUM> as the SBC that interfaces with the network-based communication service <NUM>.

Intermediate SBC <NUM> may receive the SIP invite message <NUM> and may generate SIP invite message <NUM> to send to the network-based communication service <NUM>. Intermediate SBC <NUM> may recognize that the message originated from primary SBC <NUM> and is to be forwarded to the network-based communication service <NUM> by examination of the SIP invite message <NUM>. In particular, the appending of the domain of the primary SBC <NUM> in the "from" field. Additionally, the intermediate SBC <NUM> may determine that the destination device (first computing device <NUM>) is associated with the network-based communication service <NUM> based upon the TO: field and settings that identify computing device phone numbers that are associated with the network-based communication service <NUM>. The SIP invite message <NUM> may strip the domain name of the primary SBC <NUM> in the FROM field and insert it into the "Contact" field. The SIP invite message <NUM> may include its domain name in the RECORD-ROUTE field. The media address remains that of primary SBC <NUM>.

Network-based communication service <NUM> generates a call notification <NUM>. In response the first computing device <NUM> sends the network-based communication service <NUM> a message indicating a network site (e.g., a user site id) <NUM>. This message may identify a network site the user is currently connected to. This may be a "site" of an organization or may be external to the organization. In some examples, the "site" may be explicitly identified by the first computing device <NUM>, but in other examples, the site may be determined by the network-based communication service <NUM> through an IP address look-up that matches IP addresses with network sites.

Network-based communication service <NUM> sends a <NUM> ringing message <NUM>, which is forwarded by intermediate SBC <NUM> as <NUM> ringing message <NUM> to primary SBC <NUM>. Network-based communication service <NUM> then sends a <NUM> OK message <NUM> to intermediate SBC <NUM>. The OK message <NUM> includes the first computing device's location, a media path, the network site of the user and the user's media address. The network-based communication service may determine the media path based upon one or more of the network location of the first computing device, the primary SBC (and in particular the network site of the primary SBC), and a media mode of the primary SBC. This message is then sent by the intermediate SBC <NUM> as <NUM> OK message <NUM> to primary SBC <NUM>. The OK message <NUM> may only include the media address of the first computing device and not the user location, media path, and user segment. Acknowledgment messages <NUM>, and <NUM> are then exchanged. In some examples, the network-based communication service <NUM> then informs the first computing device <NUM> of the media address of where to send the media.

In some examples, the intermediate SBC <NUM>, may not know exactly where the first computing device <NUM> is located. By default, the SBC <NUM> may send the message <NUM> with an internal IP address (e.g., the first computing device <NUM> may be either internal or external to the private network). If during the signaling negotiations, the SBC <NUM> learns that the client computing device cannot be reached on an internal address, it sends a re-invite with an external IP address that the client computing device can reach. As such, a re-invite message <NUM> may be sent with a public IP address.

An RTP session is then established to transfer the media. In examples in which the first computing device <NUM> is located in a same private network site as the primary SBC <NUM>, the RTP session <NUM> may be used which is a direct connection to the primary SBC <NUM>. In examples in which the first computing device <NUM> is not in a same private network site as the primary SBC <NUM> but within the same organization's private network, and the organization has a media path setting allowing bypass always mode, the RTP session <NUM> may be used which is a direct connection to the primary SBC <NUM>. In examples in which the first computing device <NUM> is not located in a same private network site as the primary SBC <NUM> but within the organization's private network, and the organization has a media path setting requiring local only mode, the RTP sessions <NUM> and <NUM> may be used which sends media to the intermediate SBC <NUM> which then forwards it to the primary SBC <NUM>. In examples in which the first computing device <NUM> is in a site external to the organization's private network the RTP sessions <NUM> and <NUM> may be used which sends media to the intermediate SBC <NUM> which then forwards it to the primary SBC <NUM>. In some examples two different RTP sessions are opened (e.g., a first session <NUM> and a second session <NUM>), but in other examples, the intermediate SBC <NUM> merely forwards the RTP messages.

<FIG> illustrates a logical diagram of a network-based communication service <NUM>, a client computing device <NUM>, and a session border controller (SBC) <NUM> according to some examples of the present disclosure. Session border controller <NUM> may take roles as either a primary or intermediate SBC. The logical components of network-based communication service <NUM> may be implemented as software or hardware on one or more computing devices (e.g., servers), such as those shown in <FIG>. Network-based communication service <NUM> includes an I/O controller component <NUM> which implements one or more interfaces to one or more client computing devices (such as client computing device <NUM>), to one or more SBCs (such as SBC <NUM>) and to one or more telephone network (e.g., PSTN) interfaces. I/O controller component <NUM> implements one or more protocol stacks, such as a protocol stack based upon an OSI model, a Transmission Control Protocol / Internet Protocol (TCP/IP) model, or the like. Example protocols may include Transmission Control Protocol (TCP), Internet Protocol (IP), Real Time Transport Protocol (RTP), Session Initiation Protocol (SIP), Hypertext Transfer Protocol (HTTP), Representational State Transfer (REST), and the like.

Network-based communication service <NUM> may include a controller <NUM>. Controller <NUM> may setup and manage one or more communication sessions between one or more client computing devices <NUM> and one or more other devices. For example, the controller <NUM> may setup a call between two client computing devices associated with the network-based communication service. In other examples, the controller <NUM> may setup a call between a client computing device and a device associated with a different communication system or network. This may include generating, receiving, processing, handling, and forwarding signaling and media (e.g., through the I/O controller component <NUM>) to and from client computing devices (such as client computing device <NUM>) and SBCs (such as SBC <NUM>) to provide a communication session.

Communication sessions may include voice, video, screen sharing, application sharing, or the like. Communication sessions may be two-party sessions in which two devices communicate, or may include multiple parties (e.g., more than two devices communicating) - for example, an online meeting. In some examples, the communication sessions may be real-time communication sessions in which media (such as voice, video, screen sharing data) is sent as it is captured by a capture device on the client computing device and/or other devices and consumed (e.g., played out) by other devices in the communication session once received. Controller <NUM> may include a signal path component <NUM> and media path component <NUM> that may utilize settings, communication session information (e.g., phone numbers of the participants, network sites of the participants, and the like), and network information stored in database <NUM> to determine a signal path and a media path as previously described.

Settings component <NUM> provides one or more Graphical User Interface (GUI) descriptors to one or more computing devices of an administrator of the network-based communication service <NUM> or an organization with an account with the network-based communication service <NUM>. GUI descriptors include one or more files that, when rendered by an application on the computing device of the administrator render one or more graphical user interfaces. GUI descriptors include one or more hypertext markup language (HTML), Cascading Style Sheets (CSS), scripting files (e.g., JavaScript), code modules (e.g., Java code), or the like. Settings component <NUM> may allow administrators to define network sites, IP addresses belonging to those sites, SBCs that are reachable by the network-based communication service, SBCs that are not reachable and which reachable SBC to use to contact each SBC that is not reachable, call policies, media settings, and the like. In other examples, the settings component <NUM> receives settings and changes using an API. For example, the administrator's computing device may have a command line interface that executes one or more commands that are sent through the API. These commands are processed by the settings component <NUM>. Settings may be saved in a data structure within the database <NUM>.

Media processing component <NUM> may receive audio, video, screen sharing data, and the like and convert, transcode, packetize, process, or otherwise handle media. The media may be received from and sent to the client computing devices (such as client computing device <NUM>), session border controllers (such as SBCs <NUM>), telephone (e.g., PSTN) networks, and the like.

Client computing device <NUM> may include a network-based communication service application <NUM>. Network-based communication service application <NUM> may be an application which may interface with the network-based communication service and provide communications, such as voice, text, video, file sharing, and the like. Example network-based communication service applications may include MICROSOFT® TEAMS®, SKYPE®, SKYPE FOR BUSINESS®, or the like. The logical components of client computing device <NUM> may be implemented as software or hardware on one or more computing devices (e.g., personal computers, tablets, smartphones, and the like), such as those shown in <FIG>.

Network-based communication service application <NUM> may include an I/O controller component <NUM> which implements one or more interfaces to one or more network-based communication services (such as network-based communication service <NUM>) and to one or more SBCs (such as SBC <NUM>). I/O controller component <NUM> implements one or more protocol stacks, such as a protocol stack according to an Open Systems Interconnect (OSI) model, a Transmission Control Protocol / Internet Protocol (TCP/IP) model, or the like. Example protocols may include TCP, IP, RTP, SIP, HTTP, REST, and the like. I/O controller component <NUM> may also authenticate with the network-based communication service, register the location of the client computing device <NUM> with the network-based communication service <NUM>, and the like.

Client computing device <NUM> may include a controller <NUM>. Controller <NUM> may setup and manage one or more communication sessions between the client computing device <NUM> and one or more other devices (e.g., one or more other client computing devices or one or more devices such as a telephone) through network-based communication service (such as a network-based communication service <NUM>). As noted, the network-based communication service may utilize one or more SBCs (such as SBC <NUM>) to complete the communication. Controller <NUM> may generate, receive, process, handle, and forwarding signaling and media (e.g., through the I/O controller component <NUM>) to and from the network-based communication service <NUM> (such as network-based communication service <NUM>) and SBCs (such as SBC <NUM>) to provide a communication session. Controller <NUM> may receive media from media processor component <NUM> and cause that media to be sent in one or more packets over a network to other participants in the communication session.

Network-based communication service application <NUM> may include a media processor component <NUM>. Media processor component <NUM> may receive audio, video, screen sharing data, and the like and convert, transcode, packetize, process, or otherwise handle media. The media may be received from sensors of the client computing device <NUM> (such as a microphone, video camera, or the like) and sent to other devices participating in the communication over the media path, such as by sending the media to the network-based communication service <NUM>, or one or more SBCs (such as SBC <NUM>). Media may also be received from session border controllers (such as SBCs <NUM>), network-based communication service <NUM>, and the like for playback on the client computing device <NUM>. The media may be played out on speakers, displays, and the like of the client computing device <NUM> after receipt.

User interface <NUM> may display media from the media processor component <NUM> and may allow the user to enter text, select functions to allow the user to initiate a communication session, answer an incoming communication session request, change settings, and the like. In some examples, the user interface <NUM> may allow users to select one or more media sources, including recording equipment such as microphones, video cameras, and the like. User interface <NUM> may also allow the user to input one or more text communications, which may be sent as part of a communication session, including real-time communication sessions.

Session border controller (SBC) <NUM> may be either an intermediate SBC or a destination SBC that processes a communication between the client computing device (e.g., client computing device <NUM>) and a second device and that interfaces with one or more servers of a network-based communication service (<NUM>) to setup the communication. The logical components of SBC <NUM> may be implemented as software or hardware on one or more computing devices (e.g., servers), such as those shown in <FIG>. SBC <NUM> may include an I/O controller component <NUM> which implements one or more interfaces to one or more network-based communication services (such as network-based communication service <NUM>) and to one or more client computing devices (such as client computing device <NUM>). I/O controller component <NUM> implements one or more protocol stacks, such as an OSI model protocol stack, a Transmission Control Protocol / Internet Protocol (TCP/IP) Stack, or the like. Example protocols may include TCP, IP, RTP, SIP, HTTP, REST, and the like.

SBC <NUM> may include a controller <NUM>. Controller <NUM> may setup and manage one or more communication sessions between one or more client computing devices <NUM> and one or more other devices. This may include generating, receiving, processing, handling, and forwarding signaling and media (e.g., through the I/O controller component <NUM>) to and from client computing devices (such as client computing device <NUM>), telephone networks, and/or network-based communication services (such as network-based communication service <NUM>) to provide a communication session. Controller <NUM> may provide one or more media IP addresses to which client computing device <NUM> and/or network-based communication service <NUM> sends media.

SBC <NUM> may include a media processor component <NUM>. Media processor component <NUM> may receive and send audio, video, screen sharing data, and the like and convert, transcode, packetize, process, or otherwise handle media. The media may be received from and provided to the client computing device (such as client computing device <NUM>), another session border controller, network-based communication service <NUM>, and the like. SBC <NUM> may include a settings component <NUM>. Settings component may provide one or more GUI descriptors or provide an API for changing settings on the SBC. Settings may include media path options, such as bypass options.

As noted, the administrators of an organization may change the media path based upon one or more settings applied to one or more SBCs. Two media path settings were discussed - bypass only and local only. Additional settings may be used to introduce additional flexibility in media path flows for particular network structures. For example, an administrator may group one or more network sites into a network region. One or more network regions may be well connected to each other and media bypass may be used for communications between network sites in each region. An administrator may define a region link that represents two centralized SBCs that are connected to each other via a Wide Area Network (WAN). Furthermore, an even more granular control may be achieved where two network sites in different regions may have a good network link. In these examples, an administrator may create an inter-site policy that describes direct links between SBCs in two network sites.

<FIG> illustrates a media flow <NUM> for a communication session between a client computing device that is associated with the network-based communication service and a second device through a telephone network with media bypass between two regions with a region link <NUM> according to some examples of the present disclosure. An organizational network includes a first region <NUM> and a second region <NUM>. First region <NUM> includes a first network site <NUM>, a second network site <NUM>, and a third network site <NUM>. Each site includes an SBC, such as first SBC <NUM>, second SBC <NUM>, and third SBC <NUM>. First region <NUM> also includes a connection to a telephone network <NUM>.

Second region <NUM> includes a fourth network site <NUM> with an associated fourth SBC <NUM> and a fifth network site <NUM> and a fifth SBC <NUM>. Second region <NUM> also includes a connection to a telephone network <NUM>. In <FIG>, there is region link <NUM> that links a central SBC between the first and second regions. In the example of <FIG>, the fourth SBC <NUM> and the first SBC <NUM> terminate the region link <NUM>. A client computing device <NUM> in a network segment within the second region <NUM> which participates in a communication session with another device that is to be routed across telephone network <NUM> of the first region <NUM> exchanges signaling with the network-based communication service <NUM>, which exchanges signaling with the fourth SBC <NUM>. Fourth SBC <NUM> utilizes the region link <NUM> to forward that signaling over to the first SBC <NUM>, which forwards the signaling to the second SBC <NUM>, which connects with the telephone network <NUM>. Media flows from the client computing device <NUM> to the fourth SBC <NUM>, over the region link <NUM>, to the first SBC <NUM>, to the second SBC <NUM> and the telephone network <NUM>.

<FIG> illustrates a media flow <NUM> for a communication session between a client computing device that is associated with the network-based communication service and a second device through a telephone network with media bypass between two regions with an intersite link <NUM> according to some examples of the present disclosure. The network includes a first region <NUM> and a second region <NUM>. First region <NUM> includes a first network site <NUM>, a second network site <NUM>, and a third network site <NUM>. Sites in <FIG> each includes an SBC, such as first SBC <NUM>, second SBC <NUM>, and third SBC <NUM>. First region <NUM> also includes a connection to a telephone network <NUM> and second region <NUM> includes a link to telephone network <NUM>.

Second region <NUM> includes a fourth network site <NUM> with an associated fourth SBC <NUM> and a fifth network site <NUM>. Second region <NUM> also includes a connection to a telephone network <NUM>. In <FIG>, there is an intersite link <NUM> that links the fifth network site in the second region <NUM> with the third network site <NUM> in the first region <NUM>. A client computing device <NUM> in the fifth site within the second region <NUM> which makes or receives a communication which is to go out on the telephone network <NUM> of the first region <NUM> exchanges signaling with the network-based communication service <NUM>, which exchanges signaling with the first SBC <NUM>. First SBC <NUM> forwards the signaling to the third network site <NUM> which connects with the telephone network <NUM>. First SBC <NUM> is the publicly addressable SBC within first region <NUM> (e.g., third SBC <NUM> and second SBC <NUM> are not). Media flows from the client computing device <NUM> to the third SBC <NUM> over the intersite link <NUM> and from the third SBC <NUM> to the telephone network <NUM>. Similarly, if the client computing device <NUM> was in the fourth network site <NUM>, the media could be routed over the fifth network site <NUM> and across the intersite link <NUM> to the third network site and third SBC <NUM>.

<FIG> illustrates a media flow <NUM> for a communication session between a client computing device that is associated with the network-based communication service and a second device through a telephone network with media bypass between two regions without a region link or site link according to some examples of the present disclosure. An organizational network includes a first region <NUM> and a second region <NUM>. First region <NUM> includes a first network site <NUM>, a second network site <NUM>, and a third network site <NUM>. Each segment includes an SBC, such as first SBC <NUM>, second SBC <NUM>, and third SBC <NUM>. First region <NUM> also includes a connection to a telephone network <NUM>.

Second region <NUM> includes a fifth network site <NUM>. Second region <NUM> also includes a connection to a telephone network <NUM>. In <FIG>, there are no region links or intersite links. A client computing device <NUM> in a segment within the second region <NUM> which makes or receives a call which is to go out on the telephone network <NUM> of the first region <NUM> exchanges signaling with the network-based communication service <NUM>, which exchanges signaling with the first SBC <NUM>. First SBC <NUM> forwards the signaling to the third SBC <NUM>, which connects with the telephone network <NUM>. Media flows from the client computing device <NUM> to the network-based phone system <NUM>, to the first SBC <NUM>, third SBC <NUM> and the telephone network <NUM>.

As described herein a phone number is used to identify various devices, such as the calling and called devices. Other identifiers may be utilized in a same fashion. For example, any unique identifier that allows the communication session to be routed to a particular user may be utilized. Other example identifiers include a SIP identifier (e.g., a SIP URI), International Mobile Subscriber Identity (IMSI), and the like.

As described herein, a client computing device is associated with a network-based communication service when it is registered to make and/or receive communications using the network-based communication service to setup those communications. Throughout the specification, the communication is shown as being routed over, and the primary SBC connected to, a telephone network. A telephone network may be a communications network that routes telephony traffic and may include a PSTN network, a cellular network, a satellite network, a terrestrial network, and/or the like. The telephone network may be digital and/or analog - for example, certain portions may be digital and certain portions may be analog, or the entire telephone network may be digital and the entire network may be analog. The telephone network may be packet switched in whole or in part and/or circuit switched in whole or in part. The telephone network may be cellular, satellite, terrestrial and/or the like. The network-based communication service, as previously noted, is provided by one or more computing devices, such as computer servers.

As noted, for communications originating with the client computing device, the network-based communication service may determine where to route the signaling for completing the communication based upon one or more of the phone number of the client computing device, the network location of the client computing device, or a phone number of the other party to the communication session. For example, the network-based communication service may use one of the above factors, some of the above factors, or all of the above factors. For example, the network-based communication service may use the phone number of the client computing device, the network location of the client computing device, and a phone number of the other party to the communication session.

<FIG> illustrates a block diagram of an example machine <NUM> upon which any one or more of the techniques (e.g., methodologies) discussed herein may perform. The machine <NUM> may be a SBC, server, personal computer (PC), a tablet PC, a set-top box (STB), a personal digital assistant (PDA), a mobile telephone, a smart phone, a web appliance, a network router, switch or bridge, or any machine capable of executing instructions (sequential or otherwise) that specify actions to be taken by that machine. Machine <NUM> may be configured to implement the client computing devices, such as client computing devices <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>. One or more machines such as machine <NUM> may be configured to implement the network-based communications service, such as network-based communications service <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>. One or more machines such as machine <NUM> may be configured to implement the SBCs (either intermediate or primary SBCs), such as SBCs <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, <NUM>, and <NUM>. Additionally, machine <NUM> may be configured to perform any other functions described herein or to implement any of the devices described herein including the second device. Additionally, machine <NUM> may perform any of the methods of <FIG> and implement the messaging flows of <FIG> and <FIG>.

The term "machine readable medium" may include any medium that is capable of storing, encoding, or carrying instructions for execution by the machine <NUM> and that cause the machine <NUM> to perform any one or more of the techniques of the present disclosure, or that is capable of storing, encoding or carrying data structures used by or associated with such instructions. Non-limiting machine readable medium examples may include solid-state memories, and optical and magnetic media. Specific examples of machine readable media may include: non-volatile memory, such as semiconductor memory devices (e.g., Electrically Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM)) and flash memory devices; magnetic disks, such as internal hard disks and removable disks; magneto-optical disks; Random Access Memory (RAM); Solid State Drives (SSD); and CD-ROM and DVD-ROM disks. In some examples, machine readable media may include non-transitory machine readable media. In some examples, machine readable media may include machine readable media that is not a transitory propagating signal. In some examples, the machine-readable medium may be a non-transitory machine readable medium. The machine-readable medium may be a machine-readable storage device.

Claim 1:
A computing device comprising:
a processor; and
a memory, the memory storing instructions, which when executed, cause the processor to:
determine (<NUM>) that a communication session is to be setup between a first device and a second device, the first device being a client computing device that executes a client application of a packet-switched network-based communication service, and the second device being a device configured to establish communication sessions over a telephone network comprising a PSTN or cellular network, the communication session to be routed partially over the telephone network, and partially via a packet-switched protocol using the client application on the first device; and
determine (<NUM>) a network location where the first device is located;
characterized by the instructions further being configured so as when executed to cause the processor to:
identify (<NUM>) a first session border controller, SBC, that is to interface with the telephone network during the communication session, wherein the first SBC is within a private packet-switched network of an organization, behind a firewall of the organization, and is thus not reachable over a public packet-switched network by the packet-switched network-based communication service;
identify (<NUM>) a second, intermediary SBC which is in the private and public packet-switched networks, thereby being reachable over the public packet-based network by the packet-switched network-based communication service, and the first SBC reachable by the second SBC over the private packet-switched network;
determine (<NUM>) a media path for the communication session based upon a media path setting, the network location of the first device, and the first SBC, the media path including the first SBC; and
cause (<NUM>) establishment of the communication session by transmitting a signaling message between the packet-switched network-based communication service and the first SBC through the second SBC and the public packet-switched network, the signaling message instructing the first and second SBCs to use the media path including the first SBC to route a media flow of the communication session.