已阅读5页,还剩13页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
外文原文AStudyofInternetInstantMessagingandChatProtocolsInstantmessaging(IM)andInternetchatcommunicationhaveseenenormousgrowthoverthelastseveralyears.IMistheprivatenetworkcommunicationbetweentwousers,whereasachatsessionisthenetworkcommunicationbetweentwoormoreusers.Chatsessionscaneitherbeprivate,whereeachuserisinvitedtojointhesession,orpublic,whereanyonecanjointhesession.Thereareontheorderof100millionInternetIMusers,whereauserisdefinedasauniquenameononeofthemajorpublicIMnetworksAOLInstantMessenger(AIM),MicrosoftMessenger(MSN),orYahoo!Messenger(YMSG).Todate,littlehasbeendocumentedaboutthenetworkprotocolsusedbythesesystems.Theprotocolsarenotstandardized,manyofthemareproprietary,andtheyareevenseenasacontrolpointinthisbusinessbythecompaniesinvolved.ThisisdemonstratedbytherepeatedattemptsoftheIMservicestolockoutusersofothersystems,inanattempttokeeptheircustomersprivate.However,enoughinformationisavailabletodeterminethebroadcharacteristicsofthesesystems.WehavealsousedpackettracingofIMtrafficinordertogleanfurtherdetailsintotheseprotocolsandsystems.InthisarticlewepresentanoverviewofIMprotocolsasexemplifiedbythethreepopularsystems:AIM,MSN,andYMSG.Whileeachhasbeendesignedandimplementedseparately,theoverallgroupexhibitssimilarcharacteristicswithrespecttonetworkandsystemarchitecture.Forexample,alloftheIMprotocolsallowauthenticatingwithacentralserver,engaginginprivatemessages,andconversinginpublicchatrooms.Inaddition,someIMsystemsallowfiletransfers,Webcamusage,usingprivacycontrols,maintainingbuddylists,voicechatsessions,andotheroptions.Wediscussthesetopicsinmoredetailinthesectionstofollow.WeanalyzethemostrecentIMclientsavailable.However,allofthemajorIMprotocolshaveundergonesignificantrevisionsovertheyears,andchangestotheprotocolsoccuronaregularbasis.Aswithallnetworkedapplications,IMandchatprotocolshavealargepotentialdesignspace.ThissurveyhelpsexposesomeofthedimensionsavailabletoaprotocoldesignerandhowexistingIMsystemschosetodecidethem.Wherepossible,wedescribeadvantagesanddisadvantagesofeachdesignchoice,especiallywhenthechoiceaffectssecurity.FeaturesandFunctionsMostIMsystems,includingthethreethatweanalyzeherein,useaclient-serverarchitecture.IMproviderstypicallyhostasetofserversthatcustomerslogintoandexchangemessageswith.AfundamentalissuefacedbyIMserviceproviders,andthusdesignersoftheprotocols,ishowthesystemswillscalewithlargenumbersofusers.Ideally,eachproviderdesirestohavemillionsofcustomersloggedontotheirsystemsateachtime.Thisinturnrequiresthatorganizationshaveasystemarchitecturethatcanscalewiththenumberofusers.Twoapproachesareavailablehere:symmetricandasymmetric.Inasymmetricarchitecture,eachserverperformsidenticalfunctions,suchthataclientneednotdistinguishwhichserveritcontactstoengageinanactivitywith.Inanasymmetricapproach,eachserverisdedicatedtoaparticularactivitysuchasloggingin,discoveringotherusersonthenetwork,maintainingachatroom,orforwardinganinstantmessage.Theclient-serverarchitectureallowsIMserviceproviderstokeepsomedegreeofcontrolovertheirusers.Onthepositiveside,ithelpsovercomesomeofthetechnicalissuesassociatedwithtraversingthefirewallsthattheclientsareoftenbehind.Onthenegativeside,sincebothcontrolanddatapathsgothroughthecentralservers,scalingtheservicetomillionsofusersisdifficult.Thescalabilityissueisparticularlydifficultforvoicechatsessions.AsIMservicesarebeginningtosupportvoice-chatcommunications,peer-to-peerdatapathsarebeingused.AIMusesaclient-serverarchitecturefornormaloperationsbutusesapeer-to-peerapproachforvoice-chatsessionswheretheinitiatortalksdirectlytotherecipientaftercoordinatingthroughthesystem.Twoclientsthuscommunicatedirectly,withoutusingachatroom,usingaproprietaryvoiceprotocol.YMSGalsousesaclient-serverarchitecturefornormaloperationsaswellasvoice-chatservice.YMSGvoicetrafficisroutedthroughacentralizedvoice-chatserver.Clientsfirstcontactasetupserver“”whichthenredirectstheclienttothevoice-chathostingserver.OnebenefitoftheYMSGcentralizedvoiceserverapproachisthatitcansupportmultipleuserswithinthesamevoice-chatsessionandeachusercanspecifytheirownvoicespecificationwiththecentralvoiceserverbasedontheirnetworkspeed.MSNusesaclient-serverarchitecturefornormaloperationsandpeer-to-peerforvoice-chatcommunication.MSNvoice-chatsessionsarealsolimitedbetweentwousers.Allthreeservicesprovidearangeofadministrativeandmanagementfunctions.MostIMsystemshavemechanismsformaintaininglistsoffriends(andevenenemies).Thesearetypicallycalled“buddylists,”“allowlists,”and“blocklists.”Theselistsaremaintainedaspersistentstateontheserver,whichtheclientssynchronizewithwhentheylogin.Thelistsareusedforseveralpurposes.Buddylistsidentifypeoplethatauserwishestomonitorthepresenceof(forexample,tobenotifiedwhentheylogin).Blocklistsidentifypeoplethatauserwishestobeisolatedfrom,sothattheuserisnotbotheredorharassedbythosepeople.Blocklistsareaformofblacklisting;somesystemshavethecomplementaryfeatureofawhitelistcalledallowlists,whichspecifythatonlypeopleonthelistmaycommunicatewiththeuser.AIM,YMSG,andMSNallhavebuddylistsandblocklists.AIMandMSNalsohaveallowlists.MSNevenhas“reverseforwardlists,”whichinformsyouofthoseusersthathaveyouontheirforward(allow)lists.AIMhasanadditionalfeaturethatspecifiesagranularityofblocking,calledawarning.Warningsaresentinresponsetoreceivedmessagesthattheclientfindsunpleasantorinappropriate.Recipientsofwarningmessagesarepenalizedbyhavingtheirsendingratelowered.Warninglevelsdegradeslowlyovertime.AusabilityfeaturethatsomeIMsystemsprovideismetamessagesthatindicatethattheotheruserinanIMsessionistyping.Thisimprovesinteractivity,allowingtheusertorealizethattheotherpartyisintheprocessofcomposingamessageandpotentiallyholdoffontheirowntyping.The“typing”messagesareconsequentlyamessagetypeintheIMprotocol.AIM,YMSG,andMSNhavesuchmessagetypes.AIMevenhasthreegranularities:typing,nottyping,andtypedbuterased.OneoptionYMSGprovidesthattheothersdonotistheabilitytosendIMstousersthatarenotcurrentlyloggedontothesystem.Thesystemsavesthemessagesonpersistentstorageandthendeliversthemtotherecipientwhenthatpersonlogsontotheservice.AninterestingfeatureofferedbyAIMistheabilitytoengageinsecurecommunicationsbyencryptingtheIMsession.ClientscanobtainpublickeysfromAOL,aswellasthecorrespondingcertificatestoverifythem.SecureinstantmessagesaredoneusingSSLandthetwopeerpublickeys.Securechatroomsarecreatedusingashared256-bitAESsecretkeychosenbythechatroomcreator;invitationstothechatroomincludethesecretkey.YMSGandMSNdonothaveanysimilarcapability.Peer-to-peertextcommunicationisalsoofferedbysomesystemsusingdirectTCPconnectionsbetweenclients,sometimescalled“sidechats.”AIMandYMSGhavethisfeature,butMSNdoesnot.SystemArchitectureAllthreecommercialsystemsuseserverclustersforscalability.AIMandMSNtaketheasymmetricapproach.AIMdefinesseveraltypesofservers:login,BOS(basicOSCARservices),icon,usersearch,chatroomsetup,andchatroomhosting.MSNdefinesthreetypes:dispatch,notification,andswitchboard.Wedescribehowtheseserversareusedinmoredetailbelow.Incontrast,YMSGtakesthesymmetricapproach.Clientsneedonlycontactonetypeofserverandthenrouteallkindsofactivitiesthoughthatparticularserver.Forexample,YMSGconnectstoarandomserverinthecs#.domain,where#isatwo-digitdecimalnumber.Allsubsequentcommunicationisroutedthroughthatserver.SessionDistributionWenowexamineindetailhowthedifferentsystemsdistributesessionsacrosstheserversinresponsetodifferentactions.TheAIMsystemarchitectureisdepictedinFig.1.InAIM,aftertheclientlogsinwiththemainauthenticationserver(step1inFig.1),theclientisdirectedtoaBOSserver.TheclientopensasingleTCPconnectiontotheBOSserver(step2),whichiseffectivelythecontrolchannel.Mostsubsequentcommunicationoccursoverthisconnection,suchasbasicinstantmessages.Persistentconnectionsarealsomadetotheemailserver(step3)andtheuserinterestserver(step4).Newservices(checkingemailstatus,lookingupauser,etc.)requiresendingaservicerequesttotheBOSserver,whichreplieswithanewIPaddressandTCPportnumbertocontactforthatparticularservice.Anewconnectionisthenmadetothatserver.Theexceptioniswhenauserwishestojoinorcreateachatroomsession.Inthiscase,theclientfirstcontactstheBOSservertogetaccesstothechatroomsetupserver(step5),whichgrantspermissiontoachatroom.ThecredentialsfromthechatroomsetupserverarethenpresentedtotheBOSserver(step6),whichthenpointstheclienttoaparticularchatroomserver(step7).EachchatroomsessionismaintainedusingaseparateTCPconnection.Theconnectiontothechatroomsetupserverpersistsuntilseveralminutesafterallchatroomsessionsareended.TheBOSservercanforceaclienttoswitchtoanotherBOSserverthroughamigrationmessage.In1998,AOLpurchasedMirabilisLtd.,thecreatoroftheICQinstant-messagingsoftware,andconvertedtheAIMnetworktouseaversionoftheICQOSCARprotocol.OSCAR,whichstandsforOpenSystemforCommunicationinRealtime,issomewhatmisleading,sinceAOLhasneverpublishedthespecificationsoftheprotocol.TherearesomedifferencesbetweenfeaturessupportedbyICQandAIMbutoveralltheunderlyingprotocolisthesame.Figure1.AIMsystemarchitecture.TheMSNsystemarchitectureisshowninFig.2.MSNalsohasanasymmetricarchitecture,butwithonlythreetypesofservers:dispatch,notification,andswitchboard.Aclientinitiallycontactsthewell-knowndispatchserver(step1inFig.2)ifitdoesnotknowofanynotificationservers.Thedispatchserverthenredirectstheclienttoanotificationserver.Theclientthenopensasingleconnectiontothenotificationserver(step2)andmaintainsthisconnectionaslongastheclientisloggedintothesystem.ThisisthecontrolchannelintheMSNarchitecture.Thenotificationservermaintainsthepresenceofusersinthesystem,andpointstheclienttoindividualswitchboardserverswhenanewinstantmessageorchatsessioniscreated(step4);step3willbediscussedinthenextsubsection.Theswitchboardserverisusedbothforchatsessionsandinstantmessagestootherclients;thisdiffersfromtheotherservicesinthatMSNtreatsinstantmessagesandprivatechatroomsidentically.Instantmessagesareactuallychatroomssetupbetweentwouserswhereadditionaluserscanbeinvitedtothechatroom.TheTCPconnectiontotheswitchboardisopenforthelifetimeofthechatorIMcommunicationtotheotherclient.Theswitchboardserveralsohandlesinvitationsforfiletransfers,video,andvoice.WhileMSNdoesnothaveanexplicitmigrationmechanism,thenotificationservercanclosetheclientconnection,forcingtheclienttostartover.YMSG,ontheotherhand,isverysimpleduetoitssymmetricarchitecture,andisshowninFig.3.Thesameconnectionisusedforallinstantmessagesandchatsessions.Manycorporateenvironmentsemployfirewallstoscreenunwantedtraffic,withacommondefaulttoallowHTTPtraffic.Becauseofthis,manyIMsystemsallowtunnelingoverHTTPasawayaroundthesefirewalls.Interestingly,thethreecommercialIMsystemsallusethesamesymmetricarchitecturewhentunneledoverHTTP;namely,theclientonlyinteractswithasingleHTTPfront-endserver.ThenativeIMprotocoliseffectivelyencapsulatedontopofHTTP,withcommandsandresponsesbeingmultiplexedoverHTTPconnections.AIMusestwoHTTPconnections;oneforsubmittingrequestsasynchronously,andtheotherthatblockswaitingfortheresponses.YMSGusesasinglesynchronousconnection,suchthateachrequestblocksuntilaresponseisreceivedfromthenetwork.MSNalsousesasingleconnection,butsubmitsrequestsasynchronouslyandeitherreceivesaresponseorpollsforaresponsedependinguponthetypeofrequest.UserAuthenticationThefirstthingusersdowhentheylogontoanIMnetworkisauthenticatethemselvestothesystem.Again,severalapproachesarepossiblehere,withclearimplicationsforsecurity.SomeIMsystemsdonotgothroughthefullauthenticationprocessthatisdoneinothercontexts(e.g.,SSL/TLS1),sinceboththeuserandthesystemshareasecretkeyknownonlytothetwoofthem:theusersnameandpassword.Whiletheinitialsystemsign-upistypicallydoneusingHTTPsecuredbySSL/TLS,oncethenameandpasswordaredecided,loginauthenticationistypicallydonebyexchanginghashesofthesharedsecret.Inthisway,thepasswordisnevertransmittedintheclearoverthenetwork,althoughtheusernameis.BothAIMandYMSGworkthisway.Theadvantagetothisapproachisthatexpensivecryptooperationsareavoided,suchasRSApublickeyorAESsharedkeyencryption.Instead,relativelycheaperauthenticationalgorithmsbasedonMD5and/orSHAareused.Thedisadvantageisthatconfidentialityisnotprovided;observerscanmonitorthepacketexchangesanddeterminewhohasloggedin,eveniftheycannotdeterminethepassword.Sincethehashalgorithmsarewellknown,andthechallengeandhashresultaresentintheclear,thesystemsarevulnerabletodictionaryattacks.Usersmustthereforeusepasswordsthataredifficulttocrack.Inaddition,performingtheexchangeintheclearcouldleadtoconnectionhijacking;forexample,AIMusesthecookiereturnedbythelogonserverasacredentialsentinthecleartotheBOSserver.Thiscredentialmustbeusedwithin30secondsortheconnectionwillbeterminatedbytheBOSserver.Thissuggeststhatthereisawindowofopportunitywhereanadversarycouldmonitortheconversation,capturethecookie,anduseittoimpersonatethevictimtotheBOSserver.Figure2.MSNsystemarchitecture.MSNusestheMicrosoftPassportsystem.AfteraclientidentifiesitselftotheMSNnotificationserver,itisredirectedtothePassportloginserver(step3inFig.2),whereauthenticationisperformedoverSSL.TheloginserverthensuppliestheclientwithseveralencryptedcookiesthatserveascredentialstotheMSNnotificationservers.Whiletheinternalcryptoalgorithmsarenotpubliclycookiesaresentintheclear.Thusanattackercouldattemptdocumented,theencryptedtousethecookiesforimpersonationandman-in-the-middleattacks2,3.DataTransferOneofthekeyissuesinanyIMorchatprotocolishowprotocolheadersandpayloadsareencoded.Therepresentationofthisdatacantaketwoforms.Historically,manynetworkprotocolshaveusedabinaryrepresentationofdatainnetworkbyteorder;examplesincludeTCPandIP.Application-layerprotocolssuchasHTTPandSMTPhavetendedtouseatextbasedapproach.Themainadvantagetothebinaryrepresentationisthatitmakesmostefficientuseofspaceonthenetwork.Theadvantageofthetext-basedapproachesisthattherepresentationisclosertothewayhumansviewinformation,andthusdebuggingiseasier.AIMandYMSGbothusebinaryrepresentationfortheirheaders.AIMusesatwo-levelbinarystructure,calledFLAPandSNACpackets,illustratedinFig.4.FLAPpacketshavefixed-lengthheadersandvariable-lengthdata;SNACpacketsareasubtypeofFLAPpacketsthatincludeseveraladditionalfixed-lengthfieldsfollowedbyavariabledatacomponent.YMSG,incontrast,hasasingle-levelstructureoffixedYMSG,incontrast,hasasingle-levelstructureoffixedlengthfieldsfollowedbyvariable-lengthdata,asshowninFig.5.Thedatafieldisasequenceofkey-valuepairs,wherekeysarerepresentedasavariable-lengthASCIInumber.AIMandYMSGhavedifferentmethodsofencodingheaderinformation.AIMfavorsavariable-lengthencodingthatismoreefficientinhowmuchspaceonthewireittakes;YMSGhasamoreregularstructurethatissimplertoparseanddecode.UnlikeAIMandYMSG,MSNheadersaretextbased,asshowninFig.6.MSNheaderstaketheformof,wherecommandisathree-letterencoding,transactionIDisanintegernumber,andparameterListdependsonthecommand.Figure7showsanexampleofsomeMSNmessagesduringtheloginphase,wheredifferentprotocolandoperatingversionsarespecifiedandtheclientistransferredtoanotificationserver.VERindicateswhatnativeprotocolversionsaresupportedbytheclient.CVRindicatesLocaleID,OStype,OSversion,platformarchitecture,clienttype,clientversion,andfixedstringof“MSMSGS”followedbythepassportID.XFRissentbytheserverindicatingtheIPaddressandportofthenewnotificationserverNSfollowedbya0andtheoldIPaddressandport.OnepotentialproblemforIMserviceprovidersareusersthatsenddataatexcessiverates,floodingthenetworkwithuselesstrafficandinconveniencingotherusers.WhileTCPprovidessomeprotectionagainstthisthroughcongestioncontrol,someIMprovidershaveapparentlydecidedthatthisisnotsufficient.Thus,severalsystemsprovidesomekindofratecontroltopreventSPAMordenialofservicewithintheirnetworks.AIMhasarelativelycomplexalgorithmthathasdifferentratelimitsbasedonthemessagetype.Ratesarebasedonatimewindow(inseconds).Iftheclientexceedstherate,theuserwillbewarned,andifthebadbehaviorpersists,theserverwillstartdroppingmessagesandwilleveneventuallydisconnecttheclient.YMSGhasastaticlimitofthreeIMspersecond,whichisenforcedbytheclient.Thisimpliesthatratelimitingcouldbecircumventedbythird-partyclients(suchasgaimorxchat)thatdonotenforcethelimit.MSN,ontheotherhand,doesnothaveanyrate-limitingcontrol.Figure3.YMSGsystemarchitecture.AnotherwaythatIMsystemsminimizetheloadontheirnetworksisbygettingridofidleclients.Idleclientscauseloadonthesystemsbyconsumingmemory(suchasconnectionstate)andevenCPUcycles(throughtimermanagement).Thus,eachsystemmaintainsakeep-aliveheartbeatmessage;iftheclientdoesnotprovideaheartbeatorresponsetoaquery,theconnectionmaybeterminated.InthecaseofAIM,theclientmustsendakeep-aliveeveryminutetotheserver.YSMGhastwotypesofheartbeatrequests,aprimaryandasecondary,thattheservergeneratesandtheclientmustrespondto.Itisnotimmediatelyclearwhytwotypesofsessiontimeoutsareused.Typicalvaluesare60minutesfortheprimaryand13minutesforthesecondary.MSNhasbothclientandserverheartbeats.Whentheclientpings,theserverrespondswithhowlongtheclientshouldwaituntilthenextping.Whentheserverpings,itisachallengetotheclient,whichmustthenrespondwithanMD5hashofthechallengeandtheclientID.Figure4.AIMFLAPandSNACpacketformats.Figure5.YMSGpacketformat.FutureDirectionsRecently,theIETFhasembarkedonanefforttostandardizeIMandchatprotocols.Twocompetingstandardsarebeingdeveloped:onebasedonSIMPLE4andasecondonebasedonXMPP5.SIMPLEisanextensiontotheSessionInitiationProtocol(SIP)6thstaddsinstantmessagingandpresence.SIPisatext-basedcontrol-planeprotocolforestablishingmultimediasessionssuchasVoiceoverIP.SIPcanbetransmittedoverUDP,TCP,orSSL/TLS.TheSIP/SIMPLEworkinggroupdefinestwomodelsformessagingandchatsessions:thepagermodelandthesessionmodel.Thepagermodelisappropriatewhenauserwishestosendasmallnumberofshortmessages.Thesessionmodelisintendedforextendedconversations,suchaschatgroups.TheSIP/SIMPLEpagermetaphorissimilartothatofatwo-waypagerorSMSenabledhandset;thereisnonotionofasessionwithanexplicitstartandend,noranyexplicitassociationbetweenmessages.IMpayloadsarecarriedinsidetheSIPpacketviaanewMESSAGEmethod.SIMPLEthususestheSIMProutinginfrastructuretodelivermessagestoendpoints.SinceSIPisdesignedandusedprimarilyfortransportingcontrolmessages,thereispotentialfortrafficcongestionwithintheSIPinfrastructurewhe
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2026中再生金属科技(江苏)有限责任公司招聘25人备考题库含答案详解(完整版)
- 2026黑龙江大庆油田总医院招聘消化科医生岗位2人备考题库及答案详解(考点梳理)
- 2026陕西咸阳渭城卫生院招聘2人备考题库及答案详解(易错题)
- 2026江苏南京信息工程大学招聘音乐教师1人备考题库及1套参考答案详解
- 2026江苏无锡瀚澜水利科技有限公司招聘工作人员8人备考题库含答案详解(完整版)
- 2026云南宏合新型材料有限公司招聘备考题库及答案详解(易错题)
- 2026甘肃省中医院考核招聘高层次人才1人备考题库(第四期)及答案详解(历年真题)
- 2026苏州电瓷厂股份有限公司招聘12人备考题库附答案详解(培优)
- 2026年宁波市海曙区幼儿园教师招聘笔试参考试题及答案解析
- 2026年南昌轨道交通地产开发有限公司劳务人员招聘5人考试备考试题及答案解析
- 2026年甘肃八年级地生会考真题试卷+答案
- 核心素养导向下的小学五年级英语Unit 3 What would you like 大单元教学设计与实施教案
- 英语河北保定市2026届高三年级第一次模拟考试(保定一模)(4.7-4.9)
- 2022年温州保安员考试官方指定模拟试题及答案全解
- 派出所内部卫生制度
- 河道治理课件
- 2025重症医学同步习题与全真模拟试题及答案
- 被压迫者的教育学
- 中医门诊部申请书
- 2025年工会社会工作者招聘笔试模拟试题库及答案
- 职教高考英语复习基础语法知识词法专题一名词课件
评论
0/150
提交评论