Windows Telephony Services: 2025 Patch Diffing & Analysis Part 1

A complete Guide on LLM Jacking. What is it, risks, prevention strategies and real-world examples
Understanding LLMjacking: A Complete Guide
January 31, 2025
Effective Reconnaissance Techniques for Red Teaming Engagements
Effective Reconnaissance Techniques for Red Teaming Engagements
February 7, 2025

February 6, 2025

Introduction

At the start of 2025, on Jan­u­ary 14th, Mi­crosoft re­leased over 20+ CVEs ad­dress­ing Re­mote Code Ex­e­cu­tion (RCE) vul­ner­a­bil­i­ties in Mi­crosoft Tele­pho­ny Ser­vices, pri­mar­i­ly caused by heap-based buffer over­flows. See­ing more than 20 RCE vul­ner­a­bil­i­ties in one ser­vice is nor­mal when it comes to Microsoft because you could find the same pat­terns for the vul­ner­a­bil­i­ty every­where in the code. The fol­low­ing table lists these CVEs: 


CVE Num­berVul­ner­a­bil­i­ty TypeAf­fect­ed Com­po­nent
CVE-2025-21417Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21413Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21411Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21409Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21339Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21306Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21305Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21303Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21302Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21286Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21282Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21273Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21266Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21252Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21250Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21248Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21246Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21245Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21244Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21243Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21241Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21240Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21239Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21238Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21237Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21236Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21233Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice
CVE-2025-21223Re­mote Code Ex­e­cu­tionWin­dows Tele­pho­ny Ser­vice

Ac­cord­ing to the Mi­crosoft Se­cu­ri­ty Re­sponse Cen­ter (MSRC), near­ly all of these vul­ner­a­bil­i­ties are heap-based buffer over­flows. This in­sight guides us in de­cid­ing what to fo­cus on dur­ing patch diff­ing and analy­sis.

Be­fore, we dive into the tech­ni­cal de­tails of patch analy­sis, let’s take a mo­ment to un­der­stand the fun­da­men­tals of Mi­crosoft Tele­pho­ny Ser­vices and how they op­er­ate.


Mi­crosoft Tele­pho­ny

Mi­crosoft Tele­pho­ny, in this con­text, refers to Mi­crosoft’s Tele­pho­ny Ap­pli­ca­tion Pro­gram­ming In­ter­face (TAPI), a frame­work that al­lows de­vel­op­ers to build ap­pli­ca­tions ca­pa­ble of con­trol­ling tele­pho­ny ser­vices in Win­dows. By us­ing TAPI, an ap­pli­ca­tion can place, re­ceive, and man­age calls, re­gard­less of whether these calls are rout­ed over tra­di­tion­al phone lines, PBX sys­tems, or VoIP ser­vices.

TAPI is avail­able in dif­fer­ent ver­sions: TAPI 2.x uses a pro­ce­dur­al C-style API, while TAPI 3.x is based on the Com­po­nent Ob­ject Mod­el (COM). Re­gard­less of the ver­sion, the main goal is the same: to pro­vide an ab­strac­tion lay­er be­tween the ap­pli­ca­tion and the un­der­ly­ing tele­pho­ny hard­ware or ser­vice. This is achieved through Tele­pho­ny Ser­vice Providers (TSPs)—dri­vers or mod­ules that in­ter­face di­rect­ly with the phys­i­cal or vir­tu­al tele­pho­ny de­vice. When an ap­pli­ca­tion wants to make a call, it will use TAPI func­tions (for TAPI 2.x) or COM ob­jects (for TAPI 3.x) to ini­ti­ate the re­quest. TAPI then com­mu­ni­cates with the TSP as­so­ci­at­ed with the spe­cif­ic hard­ware or ser­vice, which han­dles the ac­tu­al call set­up. Through­out the call life­cy­cle, TAPI no­ti­fies the ap­pli­ca­tion of sta­tus changes—such as ring­ing, con­nect­ed, on hold, or dis­con­nect­ed—us­ing event call­backs or COM events. This al­lows de­vel­op­ers to build rich tele­pho­ny fea­tures, in­clud­ing call hold, trans­fer, con­fer­ence, and more ad­vanced me­dia con­trol were sup­port­ed.

TAPI is par­tic­u­lar­ly rel­e­vant in sce­nar­ios like call cen­ters or cus­tomer re­la­tion­ship man­age­ment (CRM) in­te­gra­tions, where “screen-pops” (cus­tomer in­for­ma­tion dis­played when a call ar­rives) or au­to­mat­ed out­bound di­al­ing can sig­nif­i­cant­ly im­prove pro­duc­tiv­i­ty. It also sup­ports lega­cy tele­pho­ny en­vi­ron­ments where on-premis­es PBX sys­tems re­main crit­i­cal to busi­ness op­er­a­tions. Al­though many mod­ern tele­pho­ny so­lu­tions now rely heav­i­ly on cloud-based APIs and SIP-based sys­tems, TAPI is still an im­por­tant so­lu­tion for those who need tight in­te­gra­tion with Win­dows ap­pli­ca­tions and ex­ist­ing tele­pho­ny in­fra­struc­tures. In prac­ti­cal terms, get­ting start­ed in­volves in­stalling and con­fig­ur­ing the ap­pro­pri­ate TSP for the hard­ware or ser­vice you plan to use. From there, de­vel­op­ers can ref­er­ence TAPI’s func­tions and data struc­tures (for 2.x) or COM in­ter­faces (for 3.x) in their code to open a “line,” place a call, han­dle events, and tear down the con­nec­tion when done. Com­pre­hen­sive test­ing is es­sen­tial to en­sure call qual­i­ty, han­dle po­ten­tial er­rors, and pro­vide a seam­less user ex­pe­ri­ence.

Over­all, Mi­crosoft Tele­pho­ny through TAPI re­mains a pow­er­ful means of in­te­grat­ing voice com­mu­ni­ca­tion ca­pa­bil­i­ties di­rect­ly into Win­dows-based ap­pli­ca­tions. While mod­ern cloud tele­pho­ny so­lu­tions may dom­i­nate new de­ploy­ments, TAPI’s es­tab­lished ar­chi­tec­ture con­tin­ues to be a re­li­able choice for on-premis­es and hy­brid en­vi­ron­ments that re­quire close con­trol over tele­pho­ny hard­ware and lega­cy sys­tems.

From a high-lev­el per­spec­tive, the di­a­gram shows how TAPI 2.x and TAPI 3.x fit into the over­all Mi­crosoft Tele­pho­ny ar­chi­tec­ture by con­nect­ing var­i­ous tele­pho­ny ser­vice providers (TSPs) and me­dia ser­vice providers (MSPs) to un­der­ly­ing hard­ware and net­work pro­to­cols. At the top, you see TAPI 2.x and TAPI 3.x, each han­dling call con­trol, call cen­ter con­trol, and me­dia con­trol fea­tures in Win­dows. Both TAPI ver­sions com­mu­ni­cate with a cen­tral com­po­nent called the TAPI Serv­er, typ­i­cal­ly via RPC (Re­mote Pro­ce­dure Call).

Be­low the TAPI Serv­er, you find dif­fer­ent TSPs (Tele­pho­ny Ser­vice Providers). These TSPs are spe­cial­ized dri­vers or mod­ules that han­dle spe­cif­ic types of tele­pho­ny con­nec­tions. Ex­am­ples in­clude:

  • Uni­mo­dem TSP for tra­di­tion­al modems con­nect­ed to PSTN/ISDN lines.
  • Re­mote TSP for re­mote tele­pho­ny con­nec­tions over a net­work.
  • H.323 TSP for H.323-based VoIP com­mu­ni­ca­tions.
  • IP Con­fer­ence TSP for IP-based con­fer­enc­ing.
  • KMDD TSP (Ker­nel-mode de­vice dri­ver TSP) for low­er-lev­el de­vice ac­cess.

Each TSP can com­mu­ni­cate with rel­e­vant net­work or hard­ware in­ter­faces, such as Win­dows Sock­ets 2 (Winsock) for IP traf­fic, NDIS (Net­work Dri­ver In­ter­face Spec­i­fi­ca­tion) for net­work adapters, or a di­rect PSTN/ISDN con­nec­tion for ana­log or dig­i­tal tele­pho­ny.

On the TAPI 3.x side, there is an ad­di­tion­al lay­er for MSPs (Me­dia Ser­vice Providers). These MSPs work in tan­dem with the TSPs to han­dle me­dia stream­ing. Com­mon MSPs in the di­a­gram in­clude:

  • Wave MSP for tra­di­tion­al au­dio streams.
  • H.323 MSP for han­dling me­dia in H.323-based VoIP.
  • IP Con­fer­ence MSP for con­fer­ence-spe­cif­ic me­dia con­trol.
  • RCA MSP (Re­source Con­nec­tion and Ad­dress­ing MSP) for call cen­ter sce­nar­ios.
  • Third Par­ty MSP for ven­dor-spe­cif­ic or cus­tom me­dia ser­vices.

These MSPs rely on the Di­rect­Show Stream­ing Fil­ter Graph to process the in­com­ing and out­go­ing au­dio/video data. The di­a­gram shows links to RTP (Real-time Trans­port Pro­to­col), codecs for au­dio/video com­pres­sion, and even more spe­cial­ized com­po­nents if need­ed.

On the far right, you see ref­er­ences to LDAP (Light­weight Di­rec­to­ry Ac­cess Pro­to­col) and Win­dows 2000 Ac­tive Di­rec­to­ry, in­di­cat­ing how di­rec­to­ry ser­vices can be in­te­grat­ed for user lookup, au­then­ti­ca­tion, or en­ter­prise tele­pho­ny man­age­ment. This in­te­gra­tion is par­tic­u­lar­ly rel­e­vant for en­ter­prise de­ploy­ments where user in­for­ma­tion and call rout­ing might be cen­tral­ly man­aged.

Over­all, the high­lights are about how TAPI 2.x pro­vides a pri­mar­i­ly call-con­trol fo­cus (es­pe­cial­ly for lega­cy and stan­dard tele­pho­ny sce­nar­ios), while TAPI 3.x lay­ers in me­dia man­age­ment, con­fer­enc­ing, and rich­er call cen­ter con­trols. Both rely on the TAPI Serv­er to in­ter­face with var­i­ous TSPs, which in turn con­nect to ei­ther hard­ware de­vices like modems and NICs or soft­ware-based pro­to­cols like TCP/IP and H.323.


TAPI Files

In this di­a­gram, It shows how dif­fer­ent ver­sions of the Tele­pho­ny Ap­pli­ca­tion Pro­gram­ming In­ter­face (TAPI) co­ex­ist and in­ter­act with­in a Win­dows en­vi­ron­ment. On the far left are var­i­ous TAPI-based ap­pli­ca­tions (in both 16-bit and 32-bit forms), in the cen­ter are core TAPI li­braries (the DLL files), and on the right are the com­po­nents that man­age tele­pho­ny ser­vices sys­tem-wide (TAPISRV.EXE, Tele­pho­ny Ser­vice Providers, and ker­nel-mode dri­vers).


Ap­pli­ca­tions and Their TAPI Ver­sions

On the left, you can see three dis­tinct ap­pli­ca­tion types. The first is a 16-bit TAPI 1 ap­pli­ca­tion us­ing TAPI.DLL and a 16-bit “thunk” lay­er to com­mu­ni­cate with the 32-bit TAPI32.DLL. This in­di­cates back­ward com­pat­i­bil­i­ty mech­a­nisms for old­er soft­ware. Next, you have a 32-bit TAPI 2 ap­pli­ca­tion that di­rect­ly ac­cess­es TAPI32.DLL. Fi­nal­ly, there’s a TAPI 3 ap­pli­ca­tion, which uses both TAPI3.DLL for call con­trol log­ic and an MSP (Me­dia Ser­vice Provider) for man­ag­ing au­dio and video streams. This arrange­ment high­lights that Win­dows sup­ports old­er and new­er TAPI ap­pli­ca­tions run­ning si­mul­ta­ne­ous­ly, each us­ing the li­braries ap­pro­pri­ate for its gen­er­a­tion.


Core TAPI Li­braries (DLLs)

The mid­dle por­tion shows how the ap­pli­ca­tions con­nect to the rel­e­vant TAPI li­braries.

  • TAPI32.DLL: Han­dles the func­tion­al­i­ty for both TAPI 1.x and TAPI 2.x ap­pli­ca­tions. It in­cludes the fun­da­men­tal pro­ce­dures for ini­tial­iz­ing tele­pho­ny ser­vices, enu­mer­at­ing de­vices, and han­dling call states (e.g., call set­up, ring, con­nect).
  • TAPI3.DLL: Pow­ers the COM-based TAPI 3.x mod­el, al­low­ing more ad­vanced sce­nar­ios such as IP tele­pho­ny, me­dia-rich con­fer­enc­ing, and more so­phis­ti­cat­ed call han­dling.
  • Me­dia Ser­vice Provider (MSP): Works along­side TAPI3.DLL to man­age me­dia streams—this can in­volve cap­tur­ing and play­ing au­dio/video or in­te­grat­ing with Di­rect­Show for ad­vanced pro­cess­ing and con­fer­enc­ing.

TAPIS­RV.EXE and Tele­pho­ny Ser­vice Providers (TSPs)

On the right, you see TAPIS­RV.EXE, com­mon­ly re­ferred to as the TAPI Ser­vice/Serv­er. It com­mu­ni­cates with each TAPI DLL via RPC (Re­mote Pro­ce­dure Call). Its role is to cen­tral­ize and man­age tele­pho­ny op­er­a­tions for the en­tire sys­tem. Ap­pli­ca­tions may re­quest ac­tions like plac­ing a call or query­ing de­vice sta­tus, but TAPISRV.EXE de­ter­mines which Tele­pho­ny Ser­vice Provider (TSP) to use and or­ches­trates those low-lev­el in­ter­ac­tions.

A TSP is a dri­ver or com­po­nent specif­i­cal­ly de­signed to in­ter­face with a par­tic­u­lar type of tele­pho­ny hard­ware or pro­to­col. It could be an ana­log mo­dem TSP, an H.323 (VoIP) TSP, or some­thing more spe­cial­ized. Each TSP in­ter­acts with the op­er­at­ing sys­tem at a deep­er lev­el—of­ten us­ing a ker­nel-mode dri­ver for di­rect hard­ware ac­cess or pro­to­col sup­port. This lay­ered ap­proach lets TAPI be de­vice-ag­nos­tic: from the ap­pli­ca­tion’s stand­point, plac­ing a call is the same whether the un­der­ly­ing mech­a­nism is a tra­di­tion­al tele­phone line or a VoIP chan­nel.


Reg­istry and Tele­pho­ny Con­trol Pan­el

Also con­nect­ed to TAPISRV.EXE is the Win­dows Reg­istry, which holds tele­pho­ny-re­lat­ed set­tings such as di­al­ing rules, lo­ca­tion prop­er­ties, and user pref­er­ences. The Tele­pho­ny Con­trol Pan­el or Di­al­ing Prop­er­ties in­ter­faces let users con­fig­ure these set­tings in a GUI rather than edit­ing the Reg­istry di­rect­ly. TAPIS­RV.EXE reads and writes these con­fig­u­ra­tions, en­sur­ing all TAPI ap­pli­ca­tions and TSPs share a con­sis­tent set of tele­pho­ny rules.


Putting It All To­geth­er

When a TAPI-based ap­pli­ca­tion per­forms an ac­tion (like mak­ing a call), it calls into the cor­re­spond­ing TAPI li­brary (e.g., TAPI32.DLL or TAPI3.DLL). That li­brary uses RPC to com­mu­ni­cate the re­quest to TAPIS­RV.EXE, which then del­e­gates the re­quest to the ap­pro­pri­ate TSP. The TSP, in turn, works with any re­quired ker­nel-mode dri­vers to in­ter­act with the phys­i­cal (or vir­tu­al) tele­pho­ny hard­ware. Through­out this process, sta­tus changes—like ring­ing, con­nect­ed, or dis­con­nect­ed—are sent back up to the ap­pli­ca­tion via the same chain of com­mu­ni­ca­tion. This mod­u­lar de­sign en­sures mul­ti­ple ap­pli­ca­tions, TAPI ver­sions, and tele­pho­ny tech­nolo­gies can co­ex­ist while re­ly­ing on a uni­fied un­der­ly­ing ser­vice to man­age all call-re­lat­ed ac­tiv­i­ties.


Incoming Calls Flow

Let’s dis­cuss the high-lev­el flow of an in­com­ing call with­in the TAPI 3 ar­chi­tec­ture on Win­dows. Mov­ing from bot­tom to top, you can see how a call en­ters through tele­pho­ny hard­ware or a net­work in­ter­face (cloud icon), is de­tect­ed by the Tele­pho­ny Ser­vice Provider (TSP), and then pro­ceeds up­ward through TAPIS­RV, TAPI3.DLL, and ul­ti­mate­ly to the ap­pli­ca­tion. The di­a­gram also shows how the Me­dia Ser­vice Provider (MSP) in­te­grates with TAPI3.DLL to han­dle au­dio and video stream­ing.


1. Call Ar­rival and TSP No­ti­fi­ca­tion

An in­com­ing call is first re­ceived by the TSP (Tele­pho­ny Ser­vice Provider). The TSP is re­spon­si­ble for in­ter­fac­ing with the ac­tu­al tele­pho­ny hard­ware or VoIP stack. When a new call ar­rives, the TSP sends a LINE_NEWCALL mes­sage to TAPIS­RV, sig­ni­fy­ing that a call is be­ing of­fered. TAPIS­RV is the Tele­pho­ny API ser­vice that co­or­di­nates all tele­pho­ny re­quests sys­tem-wide, man­ag­ing com­mu­ni­ca­tion be­tween TSPs and high­er-lev­el TAPI clients.


2. TAPIS­RV In­forms TAPI 3

Upon re­ceiv­ing the LINE_NEWCALL mes­sage, TAPIS­RV no­ti­fies any in­ter­est­ed clients or TAPI lay­ers (in this case, TAPI 3). This al­lows TAPI 3 to be­come aware of the new, in­com­ing call. TAPI 3 then cre­ates its own high-lev­el Call ob­ject in the ap­pli­ca­tion’s con­text.


3. Cre­at­ing the Call Ob­ject and MSP Call

Af­ter TAPI 3 learns of the new call, it calls the method ITMSPAddress::CreateMSPCall on the MSP (Me­dia Ser­vice Provider). The MSP is in charge of ac­tu­al au­dio/video me­dia stream­ing for a call. Dur­ing this step, the MSP:

  1. Cre­ates an MSP Call ob­ject, which en­cap­su­lates the log­ic need­ed to han­dle me­dia streams (e.g., set­ting up au­dio, video, or oth­er data chan­nels).
  2. Cre­ates de­fault streams based on the me­dia types re­quired for the in­com­ing call.

The MSP then re­turns an Unknown point­er to the new­ly cre­at­ed MSP Call ob­ject back to TAPI 3.

4. Ag­gre­ga­tion and Ap­pli­ca­tion No­ti­fi­ca­tion

TAPI 3 ag­gre­gates the MSP Call ob­ject into its own TAPI Call ob­ject, ef­fec­tive­ly merg­ing tele­pho­ny con­trol and me­dia han­dling into one co­he­sive in­ter­face. This ag­gre­ga­tion is what en­ables the ap­pli­ca­tion to use in­ter­faces like ITStreamControl to man­age au­dio/video streams. Once the call ob­ject is ready, TAPI 3 no­ti­fies the ap­pli­ca­tion of the new call, typ­i­cal­ly by rais­ing an event or call­back in­di­cat­ing that a call is of­fer­ing.


5. Ap­pli­ca­tion Pre­pares the Call

At this point, the ap­pli­ca­tion can per­form any pre-call set­up need­ed be­fore an­swer­ing. For ex­am­ple, it might:

  • Se­lect a par­tic­u­lar au­dio or video de­vice (us­ing ITStream::SelectTerminal).
  • Con­fig­ure codecs or oth­er pa­ra­me­ters.
  • Up­date the user in­ter­face so an agent or user can see there is an in­com­ing call.

6. An­swer­ing the In­com­ing Call

When the ap­pli­ca­tion is ready to con­nect, it calls ITBasicCallControl::Answer on the TAPI Call ob­ject. In­ter­nal­ly, TAPI 3 ex­e­cutes the fol­low­ing steps:

  1. Calls lineAnswer, which is the TAPI 2–style com­mand to an­swer a call.
  2. TAPIS­RV then calls TSPI_lineAnswer, pass­ing the in­struc­tion to the TSP.
  3. The TSP ini­ti­ates call stream­ing, of­ten in­struct­ing the MSP to start send­ing and re­ceiv­ing me­dia. In some im­ple­men­ta­tions, the TSP it­self may trig­ger the me­dia start with­out go­ing back to the MSP if they are tight­ly in­te­grat­ed.

7. On­go­ing Com­mu­ni­ca­tion Be­tween TSP and MSP

Once the call is ac­tive, the TSP and MSP con­tin­ue to com­mu­ni­cate for tasks such as up­dat­ing call state, ex­chang­ing in-call events, or mod­i­fy­ing me­dia streams. This com­mu­ni­ca­tion flows via opaque data buffers through TAPIS­RV and TAPI 3:

  • The TSP sends data to the MSP by is­su­ing LINE_SENDMSPDATA mes­sages to TAPIS­RV, which are then re­ceived by the MSP through ITMSPAddress::ReceiveTSPData.
  • The MSP sends data or in­struc­tions back to the TSP through a MSP_TSP_DATA event, which TAPI 3 for­wards to the TSP via TSPI_lineReceiveMSPData.

This mech­a­nism al­lows both ser­vice providers (the TSP and MSP) to stay in sync about call progress and han­dle any mid-call ad­just­ments (e.g., hold, trans­fer, codec changes).

The fol­low­ing di­a­gram sum­ma­rize the flaw:

  1. In­com­ing Call (TSP → TAPIS­RV):
    The TSP de­tects an in­com­ing call (from a phone line, VoIP gate­way, etc.) and sends a LINE_NEWCALL mes­sage to TAPIS­RV to in­di­cate a call is be­ing of­fered.
  2. TAPIS­RV No­ti­fies TAPI 3 (TAPIS­RV → TAPI3):
    TAPIS­RV broad­casts the event to any sub­scribed TAPI lay­ers. TAPI3 re­ceives this no­ti­fi­ca­tion, prompt­ing it to set up a TAPI 3 Call ob­ject.
  3. MSP Call Cre­ation (TAPI3 → MSP):
    TAPI3 calls ITMSPAddress::CreateMSPCall on the Me­dia Ser­vice Provider (MSP) to cre­ate the un­der­ly­ing MSP Call ob­ject. This ob­ject will man­age the au­dio/video streams for the call.
  4. Ag­gre­gat­ing MSP Call (MSP → TAPI3):
    The MSP re­turns an IUnknown point­er to its new­ly cre­at­ed MSP Call ob­ject. TAPI3 merges (ag­gre­gates) this with its own TAPI Call ob­ject, then no­ti­fies the ap­pli­ca­tion that a new call has ar­rived.
  5. Ap­pli­ca­tion Pre­pares and An­swers (App → TAPI3):
    The ap­pli­ca­tion can in­spect call pa­ra­me­ters, con­fig­ure ter­mi­nals (e.g., mi­cro­phones, speak­ers), and once ready, calls ITBasicCallControl::Answer to ac­cept the call.
  6. Call An­swer Life­cy­cle (TAPI3 → TAPIS­RV → TSP):
    TAPI3 in­vokes lineAnswer (a TAPI 2–style func­tion) through TAPIS­RV, which in­structs the TSP (TSPI_lineAnswer) to of­fi­cial­ly an­swer the call on the tele­pho­ny de­vice or net­work end­point.
  7. Start­ing Me­dia Stream­ing (TSP → MSP):
    Af­ter the call is an­swered, the TSP ini­ti­ates me­dia stream­ing. In many im­ple­men­ta­tions, the TSP sig­nals the MSP (di­rect­ly or in­di­rect­ly) to be­gin send­ing/re­ceiv­ing au­dio or video. Post-an­swer, the TSP and MSP con­tin­ue to ex­change up­dates and con­trol data (like hold, trans­fer, or codec changes) us­ing opaque data buffers via TAPIS­RV and TAPI3.

Conclusion

The significant number of RCE vulnerabilities discovered in Microsoft Telephony Services, largely caused by heap-based buffer overflows, highlights the importance of thoroughly understanding TAPI and its underlying architecture. While TAPI offers a robust framework for integrating telephony features into Windows-based applications, any flaw in its components can have far-reaching implications. By exploring how TSPs, MSPs, and TAPISRV interact, researchers can better identify potential exploitation paths and implement effective mitigation strategies. Going forward, it is crucial for organizations to apply Microsoft’s patches promptly to protect against these RCE threats. For expert guidance on vulnerability management, penetration testing, or securing telephony systems, contact SecureLayer7 to leverage tailored solutions and stay ahead of evolving security risks.


Ref­er­ences


Discover more from SecureLayer7 - Offensive Security, API Scanner & Attack Surface Management

Subscribe now to keep reading and get access to the full archive.

Continue reading