DefaultSettings.php 280 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829
  1. <?php
  2. /**
  3. * Default values for MediaWiki configuration settings.
  4. *
  5. *
  6. * NEVER EDIT THIS FILE
  7. *
  8. *
  9. * To customize your installation, edit "LocalSettings.php". If you make
  10. * changes here, they will be lost on next upgrade of MediaWiki!
  11. *
  12. * In this file, variables whose default values depend on other
  13. * variables are set to false. The actual default value of these variables
  14. * will only be set in Setup.php, taking into account any custom settings
  15. * performed in LocalSettings.php.
  16. *
  17. * Documentation is in the source and on:
  18. * https://www.mediawiki.org/wiki/Manual:Configuration_settings
  19. *
  20. * @warning Note: this (and other things) will break if the autoloader is not
  21. * enabled. Please include includes/AutoLoader.php before including this file.
  22. *
  23. * This program is free software; you can redistribute it and/or modify
  24. * it under the terms of the GNU General Public License as published by
  25. * the Free Software Foundation; either version 2 of the License, or
  26. * (at your option) any later version.
  27. *
  28. * This program is distributed in the hope that it will be useful,
  29. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  30. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  31. * GNU General Public License for more details.
  32. *
  33. * You should have received a copy of the GNU General Public License along
  34. * with this program; if not, write to the Free Software Foundation, Inc.,
  35. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  36. * http://www.gnu.org/copyleft/gpl.html
  37. *
  38. * @file
  39. */
  40. /**
  41. * @cond file_level_code
  42. * This is not a valid entry point, perform no further processing unless
  43. * MEDIAWIKI is defined
  44. */
  45. if ( !defined( 'MEDIAWIKI' ) ) {
  46. echo "This file is part of MediaWiki and is not a valid entry point\n";
  47. die( 1 );
  48. }
  49. /** @endcond */
  50. /**
  51. * wgConf hold the site configuration.
  52. * Not used for much in a default install.
  53. * @since 1.5
  54. */
  55. $wgConf = new SiteConfiguration;
  56. /**
  57. * Registry of factory functions to create config objects:
  58. * The 'main' key must be set, and the value should be a valid
  59. * callable.
  60. * @since 1.23
  61. */
  62. $wgConfigRegistry = [
  63. 'main' => 'GlobalVarConfig::newInstance'
  64. ];
  65. /**
  66. * MediaWiki version number
  67. * @since 1.2
  68. */
  69. $wgVersion = '1.31.0';
  70. /**
  71. * Name of the site. It must be changed in LocalSettings.php
  72. */
  73. $wgSitename = 'MediaWiki';
  74. /**
  75. * When the wiki is running behind a proxy and this is set to true, assumes that the proxy exposes
  76. * the wiki on the standard ports (443 for https and 80 for http).
  77. * @var bool
  78. * @since 1.26
  79. */
  80. $wgAssumeProxiesUseDefaultProtocolPorts = true;
  81. /**
  82. * URL of the server.
  83. *
  84. * @par Example:
  85. * @code
  86. * $wgServer = 'http://example.com';
  87. * @endcode
  88. *
  89. * This is usually detected correctly by MediaWiki. If MediaWiki detects the
  90. * wrong server, it will redirect incorrectly after you save a page. In that
  91. * case, set this variable to fix it.
  92. *
  93. * If you want to use protocol-relative URLs on your wiki, set this to a
  94. * protocol-relative URL like '//example.com' and set $wgCanonicalServer
  95. * to a fully qualified URL.
  96. */
  97. $wgServer = WebRequest::detectServer();
  98. /**
  99. * Canonical URL of the server, to use in IRC feeds and notification e-mails.
  100. * Must be fully qualified, even if $wgServer is protocol-relative.
  101. *
  102. * Defaults to $wgServer, expanded to a fully qualified http:// URL if needed.
  103. * @since 1.18
  104. */
  105. $wgCanonicalServer = false;
  106. /**
  107. * Server name. This is automatically computed by parsing the bare
  108. * hostname out of $wgCanonicalServer. It should not be customized.
  109. * @since 1.24
  110. */
  111. $wgServerName = false;
  112. /************************************************************************//**
  113. * @name Script path settings
  114. * @{
  115. */
  116. /**
  117. * The path we should point to.
  118. * It might be a virtual path in case with use apache mod_rewrite for example.
  119. *
  120. * This *needs* to be set correctly.
  121. *
  122. * Other paths will be set to defaults based on it unless they are directly
  123. * set in LocalSettings.php
  124. */
  125. $wgScriptPath = '/wiki';
  126. /**
  127. * Whether to support URLs like index.php/Page_title These often break when PHP
  128. * is set up in CGI mode. PATH_INFO *may* be correct if cgi.fix_pathinfo is set,
  129. * but then again it may not; lighttpd converts incoming path data to lowercase
  130. * on systems with case-insensitive filesystems, and there have been reports of
  131. * problems on Apache as well.
  132. *
  133. * To be safe we'll continue to keep it off by default.
  134. *
  135. * Override this to false if $_SERVER['PATH_INFO'] contains unexpectedly
  136. * incorrect garbage, or to true if it is really correct.
  137. *
  138. * The default $wgArticlePath will be set based on this value at runtime, but if
  139. * you have customized it, having this incorrectly set to true can cause
  140. * redirect loops when "pretty URLs" are used.
  141. * @since 1.2.1
  142. */
  143. $wgUsePathInfo = ( strpos( PHP_SAPI, 'cgi' ) === false ) &&
  144. ( strpos( PHP_SAPI, 'apache2filter' ) === false ) &&
  145. ( strpos( PHP_SAPI, 'isapi' ) === false );
  146. /**@}*/
  147. /************************************************************************//**
  148. * @name URLs and file paths
  149. *
  150. * These various web and file path variables are set to their defaults
  151. * in Setup.php if they are not explicitly set from LocalSettings.php.
  152. *
  153. * These will relatively rarely need to be set manually, unless you are
  154. * splitting style sheets or images outside the main document root.
  155. *
  156. * In this section, a "path" is usually a host-relative URL, i.e. a URL without
  157. * the host part, that starts with a slash. In most cases a full URL is also
  158. * acceptable. A "directory" is a local file path.
  159. *
  160. * In both paths and directories, trailing slashes should not be included.
  161. *
  162. * @{
  163. */
  164. /**
  165. * The URL path to index.php.
  166. *
  167. * Defaults to "{$wgScriptPath}/index.php".
  168. */
  169. $wgScript = false;
  170. /**
  171. * The URL path to load.php.
  172. *
  173. * Defaults to "{$wgScriptPath}/load.php".
  174. * @since 1.17
  175. */
  176. $wgLoadScript = false;
  177. /**
  178. * The URL path of the skins directory.
  179. * Defaults to "{$wgResourceBasePath}/skins".
  180. * @since 1.3
  181. */
  182. $wgStylePath = false;
  183. $wgStyleSheetPath = &$wgStylePath;
  184. /**
  185. * The URL path of the skins directory. Should not point to an external domain.
  186. * Defaults to "{$wgScriptPath}/skins".
  187. * @since 1.17
  188. */
  189. $wgLocalStylePath = false;
  190. /**
  191. * The URL path of the extensions directory.
  192. * Defaults to "{$wgResourceBasePath}/extensions".
  193. * @since 1.16
  194. */
  195. $wgExtensionAssetsPath = false;
  196. /**
  197. * Filesystem extensions directory.
  198. * Defaults to "{$IP}/extensions".
  199. * @since 1.25
  200. */
  201. $wgExtensionDirectory = "{$IP}/extensions";
  202. /**
  203. * Filesystem stylesheets directory.
  204. * Defaults to "{$IP}/skins".
  205. * @since 1.3
  206. */
  207. $wgStyleDirectory = "{$IP}/skins";
  208. /**
  209. * The URL path for primary article page views. This path should contain $1,
  210. * which is replaced by the article title.
  211. *
  212. * Defaults to "{$wgScript}/$1" or "{$wgScript}?title=$1",
  213. * depending on $wgUsePathInfo.
  214. */
  215. $wgArticlePath = false;
  216. /**
  217. * The URL path for the images directory.
  218. * Defaults to "{$wgScriptPath}/images".
  219. */
  220. $wgUploadPath = false;
  221. /**
  222. * The filesystem path of the images directory. Defaults to "{$IP}/images".
  223. */
  224. $wgUploadDirectory = false;
  225. /**
  226. * Directory where the cached page will be saved.
  227. * Defaults to "{$wgUploadDirectory}/cache".
  228. */
  229. $wgFileCacheDirectory = false;
  230. /**
  231. * The URL path of the wiki logo. The logo size should be 135x135 pixels.
  232. * Defaults to "$wgResourceBasePath/resources/assets/wiki.png".
  233. */
  234. $wgLogo = false;
  235. /**
  236. * Array with URL paths to HD versions of the wiki logo. The scaled logo size
  237. * should be under 135x155 pixels.
  238. * Only 1.5x and 2x versions are supported.
  239. *
  240. * @par Example:
  241. * @code
  242. * $wgLogoHD = [
  243. * "1.5x" => "path/to/1.5x_version.png",
  244. * "2x" => "path/to/2x_version.png"
  245. * ];
  246. * @endcode
  247. *
  248. * SVG is also supported but when enabled, it
  249. * disables 1.5x and 2x as svg will already
  250. * be optimised for screen resolution.
  251. *
  252. * @par Example:
  253. * @code
  254. * $wgLogoHD = [
  255. * "svg" => "path/to/svg_version.svg",
  256. * ];
  257. * @endcode
  258. *
  259. * @since 1.25
  260. */
  261. $wgLogoHD = false;
  262. /**
  263. * The URL path of the shortcut icon.
  264. * @since 1.6
  265. */
  266. $wgFavicon = '/favicon.ico';
  267. /**
  268. * The URL path of the icon for iPhone and iPod Touch web app bookmarks.
  269. * Defaults to no icon.
  270. * @since 1.12
  271. */
  272. $wgAppleTouchIcon = false;
  273. /**
  274. * Value for the referrer policy meta tag.
  275. * One or more of the values defined in the Referrer Policy specification:
  276. * https://w3c.github.io/webappsec-referrer-policy/
  277. * ('no-referrer', 'no-referrer-when-downgrade', 'same-origin',
  278. * 'origin', 'strict-origin', 'origin-when-cross-origin',
  279. * 'strict-origin-when-cross-origin', or 'unsafe-url')
  280. * Setting it to false prevents the meta tag from being output
  281. * (which results in falling back to the Referrer-Policy header,
  282. * or 'no-referrer-when-downgrade' if that's not set either.)
  283. * Setting it to an array (supported since 1.31) will create a meta tag for
  284. * each value, in the reverse of the order (meaning that the first array element
  285. * will be the default and the others used as fallbacks for browsers which do not
  286. * understand it).
  287. *
  288. * @var array|string|bool
  289. * @since 1.25
  290. */
  291. $wgReferrerPolicy = false;
  292. /**
  293. * The local filesystem path to a temporary directory. This is not required to
  294. * be web accessible.
  295. *
  296. * When this setting is set to false, its value will be set through a call
  297. * to wfTempDir(). See that methods implementation for the actual detection
  298. * logic.
  299. *
  300. * Developers should use the global function wfTempDir() instead of this
  301. * variable.
  302. *
  303. * @see wfTempDir()
  304. * @note Default changed to false in MediaWiki 1.20.
  305. */
  306. $wgTmpDirectory = false;
  307. /**
  308. * If set, this URL is added to the start of $wgUploadPath to form a complete
  309. * upload URL.
  310. * @since 1.4
  311. */
  312. $wgUploadBaseUrl = '';
  313. /**
  314. * To enable remote on-demand scaling, set this to the thumbnail base URL.
  315. * Full thumbnail URL will be like $wgUploadStashScalerBaseUrl/e/e6/Foo.jpg/123px-Foo.jpg
  316. * where 'e6' are the first two characters of the MD5 hash of the file name.
  317. * If $wgUploadStashScalerBaseUrl is set to false, thumbs are rendered locally as needed.
  318. * @since 1.17
  319. */
  320. $wgUploadStashScalerBaseUrl = false;
  321. /**
  322. * To set 'pretty' URL paths for actions other than
  323. * plain page views, add to this array.
  324. *
  325. * @par Example:
  326. * Set pretty URL for the edit action:
  327. * @code
  328. * 'edit' => "$wgScriptPath/edit/$1"
  329. * @endcode
  330. *
  331. * There must be an appropriate script or rewrite rule in place to handle these
  332. * URLs.
  333. * @since 1.5
  334. */
  335. $wgActionPaths = [];
  336. /**@}*/
  337. /************************************************************************//**
  338. * @name Files and file uploads
  339. * @{
  340. */
  341. /**
  342. * Uploads have to be specially set up to be secure
  343. */
  344. $wgEnableUploads = false;
  345. /**
  346. * The maximum age of temporary (incomplete) uploaded files
  347. */
  348. $wgUploadStashMaxAge = 6 * 3600; // 6 hours
  349. /**
  350. * Allows to move images and other media files
  351. */
  352. $wgAllowImageMoving = true;
  353. /**
  354. * Enable deferred upload tasks that use the job queue.
  355. * Only enable this if job runners are set up for both the
  356. * 'AssembleUploadChunks' and 'PublishStashedFile' job types.
  357. *
  358. * @note If you use suhosin, this setting is incompatible with
  359. * suhosin.session.encrypt.
  360. */
  361. $wgEnableAsyncUploads = false;
  362. /**
  363. * Additional characters that are not allowed in filenames. They are replaced with '-' when
  364. * uploading. Like $wgLegalTitleChars, this is a regexp character class.
  365. *
  366. * Slashes and backslashes are disallowed regardless of this setting, but included here for
  367. * completeness.
  368. */
  369. $wgIllegalFileChars = ":\\/\\\\";
  370. /**
  371. * What directory to place deleted uploads in.
  372. * Defaults to "{$wgUploadDirectory}/deleted".
  373. */
  374. $wgDeletedDirectory = false;
  375. /**
  376. * Set this to true if you use img_auth and want the user to see details on why access failed.
  377. */
  378. $wgImgAuthDetails = false;
  379. /**
  380. * Map of relative URL directories to match to internal mwstore:// base storage paths.
  381. * For img_auth.php requests, everything after "img_auth.php/" is checked to see
  382. * if starts with any of the prefixes defined here. The prefixes should not overlap.
  383. * The prefix that matches has a corresponding storage path, which the rest of the URL
  384. * is assumed to be relative to. The file at that path (or a 404) is send to the client.
  385. *
  386. * Example:
  387. * $wgImgAuthUrlPathMap['/timeline/'] = 'mwstore://local-fs/timeline-render/';
  388. * The above maps ".../img_auth.php/timeline/X" to "mwstore://local-fs/timeline-render/".
  389. * The name "local-fs" should correspond by name to an entry in $wgFileBackends.
  390. *
  391. * @see $wgFileBackends
  392. */
  393. $wgImgAuthUrlPathMap = [];
  394. /**
  395. * File repository structures
  396. *
  397. * $wgLocalFileRepo is a single repository structure, and $wgForeignFileRepos is
  398. * an array of such structures. Each repository structure is an associative
  399. * array of properties configuring the repository.
  400. *
  401. * Properties required for all repos:
  402. * - class The class name for the repository. May come from the core or an extension.
  403. * The core repository classes are FileRepo, LocalRepo, ForeignDBRepo.
  404. *
  405. * - name A unique name for the repository (but $wgLocalFileRepo should be 'local').
  406. * The name should consist of alpha-numeric characters.
  407. * - backend A file backend name (see $wgFileBackends).
  408. *
  409. * For most core repos:
  410. * - zones Associative array of zone names that each map to an array with:
  411. * container : backend container name the zone is in
  412. * directory : root path within container for the zone
  413. * url : base URL to the root of the zone
  414. * urlsByExt : map of file extension types to base URLs
  415. * (useful for using a different cache for videos)
  416. * Zones default to using "<repo name>-<zone name>" as the container name
  417. * and default to using the container root as the zone's root directory.
  418. * Nesting of zone locations within other zones should be avoided.
  419. * - url Public zone URL. The 'zones' settings take precedence.
  420. * - hashLevels The number of directory levels for hash-based division of files
  421. * - thumbScriptUrl The URL for thumb.php (optional, not recommended)
  422. * - transformVia404 Whether to skip media file transformation on parse and rely on a 404
  423. * handler instead.
  424. * - initialCapital Equivalent to $wgCapitalLinks (or $wgCapitalLinkOverrides[NS_FILE],
  425. * determines whether filenames implicitly start with a capital letter.
  426. * The current implementation may give incorrect description page links
  427. * when the local $wgCapitalLinks and initialCapital are mismatched.
  428. * - pathDisclosureProtection
  429. * May be 'paranoid' to remove all parameters from error messages, 'none' to
  430. * leave the paths in unchanged, or 'simple' to replace paths with
  431. * placeholders. Default for LocalRepo is 'simple'.
  432. * - fileMode This allows wikis to set the file mode when uploading/moving files. Default
  433. * is 0644.
  434. * - directory The local filesystem directory where public files are stored. Not used for
  435. * some remote repos.
  436. * - thumbDir The base thumbnail directory. Defaults to "<directory>/thumb".
  437. * - thumbUrl The base thumbnail URL. Defaults to "<url>/thumb".
  438. * - isPrivate Set this if measures should always be taken to keep the files private.
  439. * One should not trust this to assure that the files are not web readable;
  440. * the server configuration should be done manually depending on the backend.
  441. *
  442. * These settings describe a foreign MediaWiki installation. They are optional, and will be ignored
  443. * for local repositories:
  444. * - descBaseUrl URL of image description pages, e.g. https://en.wikipedia.org/wiki/File:
  445. * - scriptDirUrl URL of the MediaWiki installation, equivalent to $wgScriptPath, e.g.
  446. * https://en.wikipedia.org/w
  447. * - articleUrl Equivalent to $wgArticlePath, e.g. https://en.wikipedia.org/wiki/$1
  448. * - fetchDescription Fetch the text of the remote file description page. Equivalent to
  449. * $wgFetchCommonsDescriptions.
  450. * - abbrvThreshold File names over this size will use the short form of thumbnail names.
  451. * Short thumbnail names only have the width, parameters, and the extension.
  452. *
  453. * ForeignDBRepo:
  454. * - dbType, dbServer, dbUser, dbPassword, dbName, dbFlags
  455. * equivalent to the corresponding member of $wgDBservers
  456. * - tablePrefix Table prefix, the foreign wiki's $wgDBprefix
  457. * - hasSharedCache True if the wiki's shared cache is accessible via the local $wgMemc
  458. *
  459. * ForeignAPIRepo:
  460. * - apibase Use for the foreign API's URL
  461. * - apiThumbCacheExpiry How long to locally cache thumbs for
  462. *
  463. * If you leave $wgLocalFileRepo set to false, Setup will fill in appropriate values.
  464. * Otherwise, set $wgLocalFileRepo to a repository structure as described above.
  465. * If you set $wgUseInstantCommons to true, it will add an entry for Commons.
  466. * If you set $wgForeignFileRepos to an array of repository structures, those will
  467. * be searched after the local file repo.
  468. * Otherwise, you will only have access to local media files.
  469. *
  470. * @see Setup.php for an example usage and default initialization.
  471. */
  472. $wgLocalFileRepo = false;
  473. /**
  474. * @see $wgLocalFileRepo
  475. */
  476. $wgForeignFileRepos = [];
  477. /**
  478. * Use Commons as a remote file repository. Essentially a wrapper, when this
  479. * is enabled $wgForeignFileRepos will point at Commons with a set of default
  480. * settings
  481. */
  482. $wgUseInstantCommons = false;
  483. /**
  484. * Array of foreign file repo names (set in $wgForeignFileRepos above) that
  485. * are allowable upload targets. These wikis must have some method of
  486. * authentication (i.e. CentralAuth), and be CORS-enabled for this wiki.
  487. * The string 'local' signifies the default local file repository.
  488. *
  489. * Example:
  490. * $wgForeignUploadTargets = [ 'shared' ];
  491. */
  492. $wgForeignUploadTargets = [ 'local' ];
  493. /**
  494. * Configuration for file uploads using the embeddable upload dialog
  495. * (https://www.mediawiki.org/wiki/Upload_dialog).
  496. *
  497. * This applies also to foreign uploads to this wiki (the configuration is loaded by remote wikis
  498. * using the action=query&meta=siteinfo API).
  499. *
  500. * See below for documentation of each property. None of the properties may be omitted.
  501. */
  502. $wgUploadDialog = [
  503. // Fields to make available in the dialog. `true` means that this field is visible, `false` means
  504. // that it is hidden. The "Name" field can't be hidden. Note that you also have to add the
  505. // matching replacement to the 'filepage' format key below to make use of these.
  506. 'fields' => [
  507. 'description' => true,
  508. 'date' => false,
  509. 'categories' => false,
  510. ],
  511. // Suffix of localisation messages used to describe the license under which the uploaded file will
  512. // be released. The same value may be set for both 'local' and 'foreign' uploads.
  513. 'licensemessages' => [
  514. // The 'local' messages are used for local uploads on this wiki:
  515. // * upload-form-label-own-work-message-generic-local
  516. // * upload-form-label-not-own-work-message-generic-local
  517. // * upload-form-label-not-own-work-local-generic-local
  518. 'local' => 'generic-local',
  519. // The 'foreign' messages are used for cross-wiki uploads from other wikis to this wiki:
  520. // * upload-form-label-own-work-message-generic-foreign
  521. // * upload-form-label-not-own-work-message-generic-foreign
  522. // * upload-form-label-not-own-work-local-generic-foreign
  523. 'foreign' => 'generic-foreign',
  524. ],
  525. // Upload comments to use for 'local' and 'foreign' uploads. This can also be set to a single
  526. // string value, in which case it is used for both kinds of uploads. Available replacements:
  527. // * $HOST - domain name from which a cross-wiki upload originates
  528. // * $PAGENAME - wiki page name from which an upload originates
  529. 'comment' => [
  530. 'local' => '',
  531. 'foreign' => '',
  532. ],
  533. // Format of the file page wikitext to be generated from the fields input by the user.
  534. 'format' => [
  535. // Wrapper for the whole page. Available replacements:
  536. // * $DESCRIPTION - file description, as input by the user (only if the 'description' field is
  537. // enabled), wrapped as defined below in the 'description' key
  538. // * $DATE - file creation date, as input by the user (only if the 'date' field is enabled)
  539. // * $SOURCE - as defined below in the 'ownwork' key, may be extended in the future
  540. // * $AUTHOR - linked user name, may be extended in the future
  541. // * $LICENSE - as defined below in the 'license' key, may be extended in the future
  542. // * $CATEGORIES - file categories wikitext, as input by the user (only if the 'categories'
  543. // field is enabled), or if no input, as defined below in the 'uncategorized' key
  544. 'filepage' => '$DESCRIPTION',
  545. // Wrapped for file description. Available replacements:
  546. // * $LANGUAGE - source wiki's content language
  547. // * $TEXT - input by the user
  548. 'description' => '$TEXT',
  549. 'ownwork' => '',
  550. 'license' => '',
  551. 'uncategorized' => '',
  552. ],
  553. ];
  554. /**
  555. * File backend structure configuration.
  556. *
  557. * This is an array of file backend configuration arrays.
  558. * Each backend configuration has the following parameters:
  559. * - 'name' : A unique name for the backend
  560. * - 'class' : The file backend class to use
  561. * - 'wikiId' : A unique string that identifies the wiki (container prefix)
  562. * - 'lockManager' : The name of a lock manager (see $wgLockManagers)
  563. *
  564. * See FileBackend::__construct() for more details.
  565. * Additional parameters are specific to the file backend class used.
  566. * These settings should be global to all wikis when possible.
  567. *
  568. * FileBackendMultiWrite::__construct() is augmented with a 'template' option that
  569. * can be used in any of the values of the 'backends' array. Its value is the name of
  570. * another backend in $wgFileBackends. When set, it pre-fills the array with all of the
  571. * configuration of the named backend. Explicitly set values in the array take precedence.
  572. *
  573. * There are two particularly important aspects about each backend:
  574. * - a) Whether it is fully qualified or wiki-relative.
  575. * By default, the paths of files are relative to the current wiki,
  576. * which works via prefixing them with the current wiki ID when accessed.
  577. * Setting 'wikiId' forces the backend to be fully qualified by prefixing
  578. * all paths with the specified value instead. This can be useful if
  579. * multiple wikis need to share the same data. Note that 'name' is *not*
  580. * part of any prefix and thus should not be relied upon for namespacing.
  581. * - b) Whether it is only defined for some wikis or is defined on all
  582. * wikis in the wiki farm. Defining a backend globally is useful
  583. * if multiple wikis need to share the same data.
  584. * One should be aware of these aspects when configuring a backend for use with
  585. * any basic feature or plugin. For example, suppose an extension stores data for
  586. * different wikis in different directories and sometimes needs to access data from
  587. * a foreign wiki's directory in order to render a page on given wiki. The extension
  588. * would need a fully qualified backend that is defined on all wikis in the wiki farm.
  589. */
  590. $wgFileBackends = [];
  591. /**
  592. * Array of configuration arrays for each lock manager.
  593. * Each backend configuration has the following parameters:
  594. * - 'name' : A unique name for the lock manager
  595. * - 'class' : The lock manger class to use
  596. *
  597. * See LockManager::__construct() for more details.
  598. * Additional parameters are specific to the lock manager class used.
  599. * These settings should be global to all wikis.
  600. *
  601. * When using DBLockManager, the 'dbsByBucket' map can reference 'localDBMaster' as
  602. * a peer database in each bucket. This will result in an extra connection to the domain
  603. * that the LockManager services, which must also be a valid wiki ID.
  604. */
  605. $wgLockManagers = [];
  606. /**
  607. * Show Exif data, on by default if available.
  608. * Requires PHP's Exif extension: https://secure.php.net/manual/en/ref.exif.php
  609. *
  610. * @note FOR WINDOWS USERS:
  611. * To enable Exif functions, add the following line to the "Windows
  612. * extensions" section of php.ini:
  613. * @code{.ini}
  614. * extension=extensions/php_exif.dll
  615. * @endcode
  616. */
  617. $wgShowEXIF = function_exists( 'exif_read_data' );
  618. /**
  619. * If to automatically update the img_metadata field
  620. * if the metadata field is outdated but compatible with the current version.
  621. * Defaults to false.
  622. */
  623. $wgUpdateCompatibleMetadata = false;
  624. /**
  625. * If you operate multiple wikis, you can define a shared upload path here.
  626. * Uploads to this wiki will NOT be put there - they will be put into
  627. * $wgUploadDirectory.
  628. * If $wgUseSharedUploads is set, the wiki will look in the shared repository if
  629. * no file of the given name is found in the local repository (for [[File:..]],
  630. * [[Media:..]] links). Thumbnails will also be looked for and generated in this
  631. * directory.
  632. *
  633. * Note that these configuration settings can now be defined on a per-
  634. * repository basis for an arbitrary number of file repositories, using the
  635. * $wgForeignFileRepos variable.
  636. */
  637. $wgUseSharedUploads = false;
  638. /**
  639. * Full path on the web server where shared uploads can be found
  640. */
  641. $wgSharedUploadPath = null;
  642. /**
  643. * Fetch commons image description pages and display them on the local wiki?
  644. */
  645. $wgFetchCommonsDescriptions = false;
  646. /**
  647. * Path on the file system where shared uploads can be found.
  648. */
  649. $wgSharedUploadDirectory = null;
  650. /**
  651. * DB name with metadata about shared directory.
  652. * Set this to false if the uploads do not come from a wiki.
  653. */
  654. $wgSharedUploadDBname = false;
  655. /**
  656. * Optional table prefix used in database.
  657. */
  658. $wgSharedUploadDBprefix = '';
  659. /**
  660. * Cache shared metadata in memcached.
  661. * Don't do this if the commons wiki is in a different memcached domain
  662. */
  663. $wgCacheSharedUploads = true;
  664. /**
  665. * Allow for upload to be copied from an URL.
  666. * The timeout for copy uploads is set by $wgCopyUploadTimeout.
  667. * You have to assign the user right 'upload_by_url' to a user group, to use this.
  668. */
  669. $wgAllowCopyUploads = false;
  670. /**
  671. * A list of domains copy uploads can come from
  672. *
  673. * @since 1.20
  674. */
  675. $wgCopyUploadsDomains = [];
  676. /**
  677. * Enable copy uploads from Special:Upload. $wgAllowCopyUploads must also be
  678. * true. If $wgAllowCopyUploads is true, but this is false, you will only be
  679. * able to perform copy uploads from the API or extensions (e.g. UploadWizard).
  680. */
  681. $wgCopyUploadsFromSpecialUpload = false;
  682. /**
  683. * Proxy to use for copy upload requests.
  684. * @since 1.20
  685. */
  686. $wgCopyUploadProxy = false;
  687. /**
  688. * Different timeout for upload by url
  689. * This could be useful since when fetching large files, you may want a
  690. * timeout longer than the default $wgHTTPTimeout. False means fallback
  691. * to default.
  692. *
  693. * @var int|bool
  694. *
  695. * @since 1.22
  696. */
  697. $wgCopyUploadTimeout = false;
  698. /**
  699. * Max size for uploads, in bytes. If not set to an array, applies to all
  700. * uploads. If set to an array, per upload type maximums can be set, using the
  701. * file and url keys. If the * key is set this value will be used as maximum
  702. * for non-specified types.
  703. *
  704. * @par Example:
  705. * @code
  706. * $wgMaxUploadSize = [
  707. * '*' => 250 * 1024,
  708. * 'url' => 500 * 1024,
  709. * ];
  710. * @endcode
  711. * Sets the maximum for all uploads to 250 kB except for upload-by-url, which
  712. * will have a maximum of 500 kB.
  713. */
  714. $wgMaxUploadSize = 1024 * 1024 * 100; # 100MB
  715. /**
  716. * Minimum upload chunk size, in bytes. When using chunked upload, non-final
  717. * chunks smaller than this will be rejected. May be reduced based on the
  718. * 'upload_max_filesize' or 'post_max_size' PHP settings.
  719. * @since 1.26
  720. */
  721. $wgMinUploadChunkSize = 1024; # 1KB
  722. /**
  723. * Point the upload navigation link to an external URL
  724. * Useful if you want to use a shared repository by default
  725. * without disabling local uploads (use $wgEnableUploads = false for that).
  726. *
  727. * @par Example:
  728. * @code
  729. * $wgUploadNavigationUrl = 'https://commons.wikimedia.org/wiki/Special:Upload';
  730. * @endcode
  731. */
  732. $wgUploadNavigationUrl = false;
  733. /**
  734. * Point the upload link for missing files to an external URL, as with
  735. * $wgUploadNavigationUrl. The URL will get "(?|&)wpDestFile=<filename>"
  736. * appended to it as appropriate.
  737. */
  738. $wgUploadMissingFileUrl = false;
  739. /**
  740. * Give a path here to use thumb.php for thumbnail generation on client
  741. * request, instead of generating them on render and outputting a static URL.
  742. * This is necessary if some of your apache servers don't have read/write
  743. * access to the thumbnail path.
  744. *
  745. * @par Example:
  746. * @code
  747. * $wgThumbnailScriptPath = "{$wgScriptPath}/thumb.php";
  748. * @endcode
  749. */
  750. $wgThumbnailScriptPath = false;
  751. /**
  752. * @see $wgThumbnailScriptPath
  753. */
  754. $wgSharedThumbnailScriptPath = false;
  755. /**
  756. * Set this to false if you do not want MediaWiki to divide your images
  757. * directory into many subdirectories, for improved performance.
  758. *
  759. * It's almost always good to leave this enabled. In previous versions of
  760. * MediaWiki, some users set this to false to allow images to be added to the
  761. * wiki by simply copying them into $wgUploadDirectory and then running
  762. * maintenance/rebuildImages.php to register them in the database. This is no
  763. * longer recommended, use maintenance/importImages.php instead.
  764. *
  765. * @note That this variable may be ignored if $wgLocalFileRepo is set.
  766. * @todo Deprecate the setting and ultimately remove it from Core.
  767. */
  768. $wgHashedUploadDirectory = true;
  769. /**
  770. * Set the following to false especially if you have a set of files that need to
  771. * be accessible by all wikis, and you do not want to use the hash (path/a/aa/)
  772. * directory layout.
  773. */
  774. $wgHashedSharedUploadDirectory = true;
  775. /**
  776. * Base URL for a repository wiki. Leave this blank if uploads are just stored
  777. * in a shared directory and not meant to be accessible through a separate wiki.
  778. * Otherwise the image description pages on the local wiki will link to the
  779. * image description page on this wiki.
  780. *
  781. * Please specify the namespace, as in the example below.
  782. */
  783. $wgRepositoryBaseUrl = "https://commons.wikimedia.org/wiki/File:";
  784. /**
  785. * This is the list of preferred extensions for uploading files. Uploading files
  786. * with extensions not in this list will trigger a warning.
  787. *
  788. * @warning If you add any OpenOffice or Microsoft Office file formats here,
  789. * such as odt or doc, and untrusted users are allowed to upload files, then
  790. * your wiki will be vulnerable to cross-site request forgery (CSRF).
  791. */
  792. $wgFileExtensions = [ 'png', 'gif', 'jpg', 'jpeg', 'webp' ];
  793. /**
  794. * Files with these extensions will never be allowed as uploads.
  795. * An array of file extensions to blacklist. You should append to this array
  796. * if you want to blacklist additional files.
  797. */
  798. $wgFileBlacklist = [
  799. # HTML may contain cookie-stealing JavaScript and web bugs
  800. 'html', 'htm', 'js', 'jsb', 'mhtml', 'mht', 'xhtml', 'xht',
  801. # PHP scripts may execute arbitrary code on the server
  802. 'php', 'phtml', 'php3', 'php4', 'php5', 'phps',
  803. # Other types that may be interpreted by some servers
  804. 'shtml', 'jhtml', 'pl', 'py', 'cgi',
  805. # May contain harmful executables for Windows victims
  806. 'exe', 'scr', 'dll', 'msi', 'vbs', 'bat', 'com', 'pif', 'cmd', 'vxd', 'cpl' ];
  807. /**
  808. * Files with these MIME types will never be allowed as uploads
  809. * if $wgVerifyMimeType is enabled.
  810. */
  811. $wgMimeTypeBlacklist = [
  812. # HTML may contain cookie-stealing JavaScript and web bugs
  813. 'text/html', 'text/javascript', 'text/x-javascript', 'application/x-shellscript',
  814. # PHP scripts may execute arbitrary code on the server
  815. 'application/x-php', 'text/x-php',
  816. # Other types that may be interpreted by some servers
  817. 'text/x-python', 'text/x-perl', 'text/x-bash', 'text/x-sh', 'text/x-csh',
  818. # Client-side hazards on Internet Explorer
  819. 'text/scriptlet', 'application/x-msdownload',
  820. # Windows metafile, client-side vulnerability on some systems
  821. 'application/x-msmetafile',
  822. ];
  823. /**
  824. * Allow Java archive uploads.
  825. * This is not recommended for public wikis since a maliciously-constructed
  826. * applet running on the same domain as the wiki can steal the user's cookies.
  827. */
  828. $wgAllowJavaUploads = false;
  829. /**
  830. * This is a flag to determine whether or not to check file extensions on upload.
  831. *
  832. * @warning Setting this to false is insecure for public wikis.
  833. */
  834. $wgCheckFileExtensions = true;
  835. /**
  836. * If this is turned off, users may override the warning for files not covered
  837. * by $wgFileExtensions.
  838. *
  839. * @warning Setting this to false is insecure for public wikis.
  840. */
  841. $wgStrictFileExtensions = true;
  842. /**
  843. * Setting this to true will disable the upload system's checks for HTML/JavaScript.
  844. *
  845. * @warning THIS IS VERY DANGEROUS on a publicly editable site, so USE
  846. * $wgGroupPermissions TO RESTRICT UPLOADING to only those that you trust
  847. */
  848. $wgDisableUploadScriptChecks = false;
  849. /**
  850. * Warn if uploaded files are larger than this (in bytes), or false to disable
  851. */
  852. $wgUploadSizeWarning = false;
  853. /**
  854. * list of trusted media-types and MIME types.
  855. * Use the MEDIATYPE_xxx constants to represent media types.
  856. * This list is used by File::isSafeFile
  857. *
  858. * Types not listed here will have a warning about unsafe content
  859. * displayed on the images description page. It would also be possible
  860. * to use this for further restrictions, like disabling direct
  861. * [[media:...]] links for non-trusted formats.
  862. */
  863. $wgTrustedMediaFormats = [
  864. MEDIATYPE_BITMAP, // all bitmap formats
  865. MEDIATYPE_AUDIO, // all audio formats
  866. MEDIATYPE_VIDEO, // all plain video formats
  867. "image/svg+xml", // svg (only needed if inline rendering of svg is not supported)
  868. "application/pdf", // PDF files
  869. # "application/x-shockwave-flash", //flash/shockwave movie
  870. ];
  871. /**
  872. * Plugins for media file type handling.
  873. * Each entry in the array maps a MIME type to a class name
  874. *
  875. * Core media handlers are listed in MediaHandlerFactory,
  876. * and extensions should use extension.json.
  877. */
  878. $wgMediaHandlers = [];
  879. /**
  880. * Media handler overrides for parser tests (they don't need to generate actual
  881. * thumbnails, so a mock will do)
  882. */
  883. $wgParserTestMediaHandlers = [
  884. 'image/jpeg' => 'MockBitmapHandler',
  885. 'image/png' => 'MockBitmapHandler',
  886. 'image/gif' => 'MockBitmapHandler',
  887. 'image/tiff' => 'MockBitmapHandler',
  888. 'image/webp' => 'MockBitmapHandler',
  889. 'image/x-ms-bmp' => 'MockBitmapHandler',
  890. 'image/x-bmp' => 'MockBitmapHandler',
  891. 'image/x-xcf' => 'MockBitmapHandler',
  892. 'image/svg+xml' => 'MockSvgHandler',
  893. 'image/vnd.djvu' => 'MockDjVuHandler',
  894. ];
  895. /**
  896. * Plugins for page content model handling.
  897. * Each entry in the array maps a model id to a class name or callback
  898. * that creates an instance of the appropriate ContentHandler subclass.
  899. *
  900. * @since 1.21
  901. */
  902. $wgContentHandlers = [
  903. // the usual case
  904. CONTENT_MODEL_WIKITEXT => WikitextContentHandler::class,
  905. // dumb version, no syntax highlighting
  906. CONTENT_MODEL_JAVASCRIPT => JavaScriptContentHandler::class,
  907. // simple implementation, for use by extensions, etc.
  908. CONTENT_MODEL_JSON => JsonContentHandler::class,
  909. // dumb version, no syntax highlighting
  910. CONTENT_MODEL_CSS => CssContentHandler::class,
  911. // plain text, for use by extensions, etc.
  912. CONTENT_MODEL_TEXT => TextContentHandler::class,
  913. ];
  914. /**
  915. * Whether to enable server-side image thumbnailing. If false, images will
  916. * always be sent to the client in full resolution, with appropriate width= and
  917. * height= attributes on the <img> tag for the client to do its own scaling.
  918. */
  919. $wgUseImageResize = true;
  920. /**
  921. * Resizing can be done using PHP's internal image libraries or using
  922. * ImageMagick or another third-party converter, e.g. GraphicMagick.
  923. * These support more file formats than PHP, which only supports PNG,
  924. * GIF, JPG, XBM and WBMP.
  925. *
  926. * Use Image Magick instead of PHP builtin functions.
  927. */
  928. $wgUseImageMagick = false;
  929. /**
  930. * The convert command shipped with ImageMagick
  931. */
  932. $wgImageMagickConvertCommand = '/usr/bin/convert';
  933. /**
  934. * Array of max pixel areas for interlacing per MIME type
  935. * @since 1.27
  936. */
  937. $wgMaxInterlacingAreas = [];
  938. /**
  939. * Sharpening parameter to ImageMagick
  940. */
  941. $wgSharpenParameter = '0x0.4';
  942. /**
  943. * Reduction in linear dimensions below which sharpening will be enabled
  944. */
  945. $wgSharpenReductionThreshold = 0.85;
  946. /**
  947. * Temporary directory used for ImageMagick. The directory must exist. Leave
  948. * this set to false to let ImageMagick decide for itself.
  949. */
  950. $wgImageMagickTempDir = false;
  951. /**
  952. * Use another resizing converter, e.g. GraphicMagick
  953. * %s will be replaced with the source path, %d with the destination
  954. * %w and %h will be replaced with the width and height.
  955. *
  956. * @par Example for GraphicMagick:
  957. * @code
  958. * $wgCustomConvertCommand = "gm convert %s -resize %wx%h %d"
  959. * @endcode
  960. *
  961. * Leave as false to skip this.
  962. */
  963. $wgCustomConvertCommand = false;
  964. /**
  965. * used for lossless jpeg rotation
  966. *
  967. * @since 1.21
  968. */
  969. $wgJpegTran = '/usr/bin/jpegtran';
  970. /**
  971. * At default setting of 'yuv420', JPEG thumbnails will use 4:2:0 chroma
  972. * subsampling to reduce file size, at the cost of possible color fringing
  973. * at sharp edges.
  974. *
  975. * See https://en.wikipedia.org/wiki/Chroma_subsampling
  976. *
  977. * Supported values:
  978. * false - use scaling system's default (same as pre-1.27 behavior)
  979. * 'yuv444' - luma and chroma at same resolution
  980. * 'yuv422' - chroma at 1/2 resolution horizontally, full vertically
  981. * 'yuv420' - chroma at 1/2 resolution in both dimensions
  982. *
  983. * This setting is currently supported only for the ImageMagick backend;
  984. * others may default to 4:2:0 or 4:4:4 or maintaining the source file's
  985. * sampling in the thumbnail.
  986. *
  987. * @since 1.27
  988. */
  989. $wgJpegPixelFormat = 'yuv420';
  990. /**
  991. * Some tests and extensions use exiv2 to manipulate the Exif metadata in some
  992. * image formats.
  993. */
  994. $wgExiv2Command = '/usr/bin/exiv2';
  995. /**
  996. * Path to exiftool binary. Used for lossless ICC profile swapping.
  997. *
  998. * @since 1.26
  999. */
  1000. $wgExiftool = '/usr/bin/exiftool';
  1001. /**
  1002. * Scalable Vector Graphics (SVG) may be uploaded as images.
  1003. * Since SVG support is not yet standard in browsers, it is
  1004. * necessary to rasterize SVGs to PNG as a fallback format.
  1005. *
  1006. * An external program is required to perform this conversion.
  1007. * If set to an array, the first item is a PHP callable and any further items
  1008. * are passed as parameters after $srcPath, $dstPath, $width, $height
  1009. */
  1010. $wgSVGConverters = [
  1011. 'ImageMagick' =>
  1012. '$path/convert -background "#ffffff00" -thumbnail $widthx$height\! $input PNG:$output',
  1013. 'sodipodi' => '$path/sodipodi -z -w $width -f $input -e $output',
  1014. 'inkscape' => '$path/inkscape -z -w $width -f $input -e $output',
  1015. 'batik' => 'java -Djava.awt.headless=true -jar $path/batik-rasterizer.jar -w $width -d '
  1016. . '$output $input',
  1017. 'rsvg' => '$path/rsvg-convert -w $width -h $height -o $output $input',
  1018. 'imgserv' => '$path/imgserv-wrapper -i svg -o png -w$width $input $output',
  1019. 'ImagickExt' => [ 'SvgHandler::rasterizeImagickExt' ],
  1020. ];
  1021. /**
  1022. * Pick a converter defined in $wgSVGConverters
  1023. */
  1024. $wgSVGConverter = 'ImageMagick';
  1025. /**
  1026. * If not in the executable PATH, specify the SVG converter path.
  1027. */
  1028. $wgSVGConverterPath = '';
  1029. /**
  1030. * Don't scale a SVG larger than this
  1031. */
  1032. $wgSVGMaxSize = 5120;
  1033. /**
  1034. * Don't read SVG metadata beyond this point.
  1035. * Default is 1024*256 bytes
  1036. */
  1037. $wgSVGMetadataCutoff = 262144;
  1038. /**
  1039. * Disallow <title> element in SVG files.
  1040. *
  1041. * MediaWiki will reject HTMLesque tags in uploaded files due to idiotic
  1042. * browsers which can not perform basic stuff like MIME detection and which are
  1043. * vulnerable to further idiots uploading crap files as images.
  1044. *
  1045. * When this directive is on, "<title>" will be allowed in files with an
  1046. * "image/svg+xml" MIME type. You should leave this disabled if your web server
  1047. * is misconfigured and doesn't send appropriate MIME types for SVG images.
  1048. */
  1049. $wgAllowTitlesInSVG = false;
  1050. /**
  1051. * The maximum number of pixels a source image can have if it is to be scaled
  1052. * down by a scaler that requires the full source image to be decompressed
  1053. * and stored in decompressed form, before the thumbnail is generated.
  1054. *
  1055. * This provides a limit on memory usage for the decompression side of the
  1056. * image scaler. The limit is used when scaling PNGs with any of the
  1057. * built-in image scalers, such as ImageMagick or GD. It is ignored for
  1058. * JPEGs with ImageMagick, and when using the VipsScaler extension.
  1059. *
  1060. * The default is 50 MB if decompressed to RGBA form, which corresponds to
  1061. * 12.5 million pixels or 3500x3500.
  1062. */
  1063. $wgMaxImageArea = 1.25e7;
  1064. /**
  1065. * Force thumbnailing of animated GIFs above this size to a single
  1066. * frame instead of an animated thumbnail. As of MW 1.17 this limit
  1067. * is checked against the total size of all frames in the animation.
  1068. * It probably makes sense to keep this equal to $wgMaxImageArea.
  1069. */
  1070. $wgMaxAnimatedGifArea = 1.25e7;
  1071. /**
  1072. * Browsers don't support TIFF inline generally...
  1073. * For inline display, we need to convert to PNG or JPEG.
  1074. * Note scaling should work with ImageMagick, but may not with GD scaling.
  1075. *
  1076. * @par Example:
  1077. * @code
  1078. * // PNG is lossless, but inefficient for photos
  1079. * $wgTiffThumbnailType = [ 'png', 'image/png' ];
  1080. * // JPEG is good for photos, but has no transparency support. Bad for diagrams.
  1081. * $wgTiffThumbnailType = [ 'jpg', 'image/jpeg' ];
  1082. * @endcode
  1083. */
  1084. $wgTiffThumbnailType = false;
  1085. /**
  1086. * If rendered thumbnail files are older than this timestamp, they
  1087. * will be rerendered on demand as if the file didn't already exist.
  1088. * Update if there is some need to force thumbs and SVG rasterizations
  1089. * to rerender, such as fixes to rendering bugs.
  1090. */
  1091. $wgThumbnailEpoch = '20030516000000';
  1092. /**
  1093. * Certain operations are avoided if there were too many recent failures,
  1094. * for example, thumbnail generation. Bump this value to invalidate all
  1095. * memory of failed operations and thus allow further attempts to resume.
  1096. * This is useful when a cause for the failures has been found and fixed.
  1097. */
  1098. $wgAttemptFailureEpoch = 1;
  1099. /**
  1100. * If set, inline scaled images will still produce "<img>" tags ready for
  1101. * output instead of showing an error message.
  1102. *
  1103. * This may be useful if errors are transitory, especially if the site
  1104. * is configured to automatically render thumbnails on request.
  1105. *
  1106. * On the other hand, it may obscure error conditions from debugging.
  1107. * Enable the debug log or the 'thumbnail' log group to make sure errors
  1108. * are logged to a file for review.
  1109. */
  1110. $wgIgnoreImageErrors = false;
  1111. /**
  1112. * Allow thumbnail rendering on page view. If this is false, a valid
  1113. * thumbnail URL is still output, but no file will be created at
  1114. * the target location. This may save some time if you have a
  1115. * thumb.php or 404 handler set up which is faster than the regular
  1116. * webserver(s).
  1117. */
  1118. $wgGenerateThumbnailOnParse = true;
  1119. /**
  1120. * Show thumbnails for old images on the image description page
  1121. */
  1122. $wgShowArchiveThumbnails = true;
  1123. /**
  1124. * If set to true, images that contain certain the exif orientation tag will
  1125. * be rotated accordingly. If set to null, try to auto-detect whether a scaler
  1126. * is available that can rotate.
  1127. */
  1128. $wgEnableAutoRotation = null;
  1129. /**
  1130. * Internal name of virus scanner. This serves as a key to the
  1131. * $wgAntivirusSetup array. Set this to NULL to disable virus scanning. If not
  1132. * null, every file uploaded will be scanned for viruses.
  1133. */
  1134. $wgAntivirus = null;
  1135. /**
  1136. * Configuration for different virus scanners. This an associative array of
  1137. * associative arrays. It contains one setup array per known scanner type.
  1138. * The entry is selected by $wgAntivirus, i.e.
  1139. * valid values for $wgAntivirus are the keys defined in this array.
  1140. *
  1141. * The configuration array for each scanner contains the following keys:
  1142. * "command", "codemap", "messagepattern":
  1143. *
  1144. * "command" is the full command to call the virus scanner - %f will be
  1145. * replaced with the name of the file to scan. If not present, the filename
  1146. * will be appended to the command. Note that this must be overwritten if the
  1147. * scanner is not in the system path; in that case, please set
  1148. * $wgAntivirusSetup[$wgAntivirus]['command'] to the desired command with full
  1149. * path.
  1150. *
  1151. * "codemap" is a mapping of exit code to return codes of the detectVirus
  1152. * function in SpecialUpload.
  1153. * - An exit code mapped to AV_SCAN_FAILED causes the function to consider
  1154. * the scan to be failed. This will pass the file if $wgAntivirusRequired
  1155. * is not set.
  1156. * - An exit code mapped to AV_SCAN_ABORTED causes the function to consider
  1157. * the file to have an unsupported format, which is probably immune to
  1158. * viruses. This causes the file to pass.
  1159. * - An exit code mapped to AV_NO_VIRUS will cause the file to pass, meaning
  1160. * no virus was found.
  1161. * - All other codes (like AV_VIRUS_FOUND) will cause the function to report
  1162. * a virus.
  1163. * - You may use "*" as a key in the array to catch all exit codes not mapped otherwise.
  1164. *
  1165. * "messagepattern" is a perl regular expression to extract the meaningful part of the scanners
  1166. * output. The relevant part should be matched as group one (\1).
  1167. * If not defined or the pattern does not match, the full message is shown to the user.
  1168. */
  1169. $wgAntivirusSetup = [
  1170. # setup for clamav
  1171. 'clamav' => [
  1172. 'command' => 'clamscan --no-summary ',
  1173. 'codemap' => [
  1174. "0" => AV_NO_VIRUS, # no virus
  1175. "1" => AV_VIRUS_FOUND, # virus found
  1176. "52" => AV_SCAN_ABORTED, # unsupported file format (probably immune)
  1177. "*" => AV_SCAN_FAILED, # else scan failed
  1178. ],
  1179. 'messagepattern' => '/.*?:(.*)/sim',
  1180. ],
  1181. ];
  1182. /**
  1183. * Determines if a failed virus scan (AV_SCAN_FAILED) will cause the file to be rejected.
  1184. */
  1185. $wgAntivirusRequired = true;
  1186. /**
  1187. * Determines if the MIME type of uploaded files should be checked
  1188. */
  1189. $wgVerifyMimeType = true;
  1190. /**
  1191. * Sets the MIME type definition file to use by MimeMagic.php.
  1192. * Set to null, to use built-in defaults only.
  1193. * example: $wgMimeTypeFile = '/etc/mime.types';
  1194. */
  1195. $wgMimeTypeFile = 'includes/mime.types';
  1196. /**
  1197. * Sets the MIME type info file to use by MimeMagic.php.
  1198. * Set to null, to use built-in defaults only.
  1199. */
  1200. $wgMimeInfoFile = 'includes/mime.info';
  1201. /**
  1202. * Sets an external MIME detector program. The command must print only
  1203. * the MIME type to standard output.
  1204. * The name of the file to process will be appended to the command given here.
  1205. * If not set or NULL, PHP's mime_content_type function will be used.
  1206. *
  1207. * @par Example:
  1208. * @code
  1209. * #$wgMimeDetectorCommand = "file -bi"; # use external MIME detector (Linux)
  1210. * @endcode
  1211. */
  1212. $wgMimeDetectorCommand = null;
  1213. /**
  1214. * Switch for trivial MIME detection. Used by thumb.php to disable all fancy
  1215. * things, because only a few types of images are needed and file extensions
  1216. * can be trusted.
  1217. */
  1218. $wgTrivialMimeDetection = false;
  1219. /**
  1220. * Additional XML types we can allow via MIME-detection.
  1221. * array = [ 'rootElement' => 'associatedMimeType' ]
  1222. */
  1223. $wgXMLMimeTypes = [
  1224. 'http://www.w3.org/2000/svg:svg' => 'image/svg+xml',
  1225. 'svg' => 'image/svg+xml',
  1226. 'http://www.lysator.liu.se/~alla/dia/:diagram' => 'application/x-dia-diagram',
  1227. 'http://www.w3.org/1999/xhtml:html' => 'text/html', // application/xhtml+xml?
  1228. 'html' => 'text/html', // application/xhtml+xml?
  1229. ];
  1230. /**
  1231. * Limit images on image description pages to a user-selectable limit. In order
  1232. * to reduce disk usage, limits can only be selected from a list.
  1233. * The user preference is saved as an array offset in the database, by default
  1234. * the offset is set with $wgDefaultUserOptions['imagesize']. Make sure you
  1235. * change it if you alter the array (see T10858).
  1236. * This is the list of settings the user can choose from:
  1237. */
  1238. $wgImageLimits = [
  1239. [ 320, 240 ],
  1240. [ 640, 480 ],
  1241. [ 800, 600 ],
  1242. [ 1024, 768 ],
  1243. [ 1280, 1024 ]
  1244. ];
  1245. /**
  1246. * Adjust thumbnails on image pages according to a user setting. In order to
  1247. * reduce disk usage, the values can only be selected from a list. This is the
  1248. * list of settings the user can choose from:
  1249. */
  1250. $wgThumbLimits = [
  1251. 120,
  1252. 150,
  1253. 180,
  1254. 200,
  1255. 250,
  1256. 300
  1257. ];
  1258. /**
  1259. * When defined, is an array of image widths used as buckets for thumbnail generation.
  1260. * The goal is to save resources by generating thumbnails based on reference buckets instead of
  1261. * always using the original. This will incur a speed gain but cause a quality loss.
  1262. *
  1263. * The buckets generation is chained, with each bucket generated based on the above bucket
  1264. * when possible. File handlers have to opt into using that feature. For now only BitmapHandler
  1265. * supports it.
  1266. */
  1267. $wgThumbnailBuckets = null;
  1268. /**
  1269. * When using thumbnail buckets as defined above, this sets the minimum distance to the bucket
  1270. * above the requested size. The distance represents how many extra pixels of width the bucket
  1271. * needs in order to be used as the reference for a given thumbnail. For example, with the
  1272. * following buckets:
  1273. *
  1274. * $wgThumbnailBuckets = [ 128, 256, 512 ];
  1275. *
  1276. * and a distance of 50:
  1277. *
  1278. * $wgThumbnailMinimumBucketDistance = 50;
  1279. *
  1280. * If we want to render a thumbnail of width 220px, the 512px bucket will be used,
  1281. * because 220 + 50 = 270 and the closest bucket bigger than 270px is 512.
  1282. */
  1283. $wgThumbnailMinimumBucketDistance = 50;
  1284. /**
  1285. * When defined, is an array of thumbnail widths to be rendered at upload time. The idea is to
  1286. * prerender common thumbnail sizes, in order to avoid the necessity to render them on demand, which
  1287. * has a performance impact for the first client to view a certain size.
  1288. *
  1289. * This obviously means that more disk space is needed per upload upfront.
  1290. *
  1291. * @since 1.25
  1292. */
  1293. $wgUploadThumbnailRenderMap = [];
  1294. /**
  1295. * The method through which the thumbnails will be prerendered for the entries in
  1296. * $wgUploadThumbnailRenderMap
  1297. *
  1298. * The method can be either "http" or "jobqueue". The former uses an http request to hit the
  1299. * thumbnail's URL.
  1300. * This method only works if thumbnails are configured to be rendered by a 404 handler. The latter
  1301. * option uses the job queue to render the thumbnail.
  1302. *
  1303. * @since 1.25
  1304. */
  1305. $wgUploadThumbnailRenderMethod = 'jobqueue';
  1306. /**
  1307. * When using the "http" wgUploadThumbnailRenderMethod, lets one specify a custom Host HTTP header.
  1308. *
  1309. * @since 1.25
  1310. */
  1311. $wgUploadThumbnailRenderHttpCustomHost = false;
  1312. /**
  1313. * When using the "http" wgUploadThumbnailRenderMethod, lets one specify a custom domain to send the
  1314. * HTTP request to.
  1315. *
  1316. * @since 1.25
  1317. */
  1318. $wgUploadThumbnailRenderHttpCustomDomain = false;
  1319. /**
  1320. * When this variable is true and JPGs use the sRGB ICC profile, swaps it for the more lightweight
  1321. * (and free) TinyRGB profile when generating thumbnails.
  1322. *
  1323. * @since 1.26
  1324. */
  1325. $wgUseTinyRGBForJPGThumbnails = false;
  1326. /**
  1327. * Parameters for the "<gallery>" tag.
  1328. * Fields are:
  1329. * - imagesPerRow: Default number of images per-row in the gallery. 0 -> Adapt to screensize
  1330. * - imageWidth: Width of the cells containing images in galleries (in "px")
  1331. * - imageHeight: Height of the cells containing images in galleries (in "px")
  1332. * - captionLength: Length to truncate filename to in caption when using "showfilename".
  1333. * A value of 'true' will truncate the filename to one line using CSS
  1334. * and will be the behaviour after deprecation.
  1335. * @deprecated since 1.28
  1336. * - showBytes: Show the filesize in bytes in categories
  1337. * - showDimensions: Show the dimensions (width x height) in categories
  1338. * - mode: Gallery mode
  1339. */
  1340. $wgGalleryOptions = [];
  1341. /**
  1342. * Adjust width of upright images when parameter 'upright' is used
  1343. * This allows a nicer look for upright images without the need to fix the width
  1344. * by hardcoded px in wiki sourcecode.
  1345. */
  1346. $wgThumbUpright = 0.75;
  1347. /**
  1348. * Default value for chmoding of new directories.
  1349. */
  1350. $wgDirectoryMode = 0777;
  1351. /**
  1352. * Generate and use thumbnails suitable for screens with 1.5 and 2.0 pixel densities.
  1353. *
  1354. * This means a 320x240 use of an image on the wiki will also generate 480x360 and 640x480
  1355. * thumbnails, output via the srcset attribute.
  1356. *
  1357. * On older browsers, a JavaScript polyfill switches the appropriate images in after loading
  1358. * the original low-resolution versions depending on the reported window.devicePixelRatio.
  1359. * The polyfill can be found in the jquery.hidpi module.
  1360. */
  1361. $wgResponsiveImages = true;
  1362. /**
  1363. * @name DJVU settings
  1364. * @{
  1365. */
  1366. /**
  1367. * Path of the djvudump executable
  1368. * Enable this and $wgDjvuRenderer to enable djvu rendering
  1369. * example: $wgDjvuDump = 'djvudump';
  1370. */
  1371. $wgDjvuDump = null;
  1372. /**
  1373. * Path of the ddjvu DJVU renderer
  1374. * Enable this and $wgDjvuDump to enable djvu rendering
  1375. * example: $wgDjvuRenderer = 'ddjvu';
  1376. */
  1377. $wgDjvuRenderer = null;
  1378. /**
  1379. * Path of the djvutxt DJVU text extraction utility
  1380. * Enable this and $wgDjvuDump to enable text layer extraction from djvu files
  1381. * example: $wgDjvuTxt = 'djvutxt';
  1382. */
  1383. $wgDjvuTxt = null;
  1384. /**
  1385. * Path of the djvutoxml executable
  1386. * This works like djvudump except much, much slower as of version 3.5.
  1387. *
  1388. * For now we recommend you use djvudump instead. The djvuxml output is
  1389. * probably more stable, so we'll switch back to it as soon as they fix
  1390. * the efficiency problem.
  1391. * https://sourceforge.net/tracker/index.php?func=detail&aid=1704049&group_id=32953&atid=406583
  1392. *
  1393. * @par Example:
  1394. * @code
  1395. * $wgDjvuToXML = 'djvutoxml';
  1396. * @endcode
  1397. */
  1398. $wgDjvuToXML = null;
  1399. /**
  1400. * Shell command for the DJVU post processor
  1401. * Default: pnmtojpeg, since ddjvu generates ppm output
  1402. * Set this to false to output the ppm file directly.
  1403. */
  1404. $wgDjvuPostProcessor = 'pnmtojpeg';
  1405. /**
  1406. * File extension for the DJVU post processor output
  1407. */
  1408. $wgDjvuOutputExtension = 'jpg';
  1409. /** @} */ # end of DJvu }
  1410. /** @} */ # end of file uploads }
  1411. /************************************************************************//**
  1412. * @name Email settings
  1413. * @{
  1414. */
  1415. /**
  1416. * Site admin email address.
  1417. *
  1418. * Defaults to "wikiadmin@$wgServerName".
  1419. */
  1420. $wgEmergencyContact = false;
  1421. /**
  1422. * Sender email address for e-mail notifications.
  1423. *
  1424. * The address we use as sender when a user requests a password reminder.
  1425. *
  1426. * Defaults to "apache@$wgServerName".
  1427. */
  1428. $wgPasswordSender = false;
  1429. /**
  1430. * Sender name for e-mail notifications.
  1431. *
  1432. * @deprecated since 1.23; use the system message 'emailsender' instead.
  1433. */
  1434. $wgPasswordSenderName = 'MediaWiki Mail';
  1435. /**
  1436. * Reply-To address for e-mail notifications.
  1437. *
  1438. * Defaults to $wgPasswordSender.
  1439. */
  1440. $wgNoReplyAddress = false;
  1441. /**
  1442. * Set to true to enable the e-mail basic features:
  1443. * Password reminders, etc. If sending e-mail on your
  1444. * server doesn't work, you might want to disable this.
  1445. */
  1446. $wgEnableEmail = true;
  1447. /**
  1448. * Set to true to enable user-to-user e-mail.
  1449. * This can potentially be abused, as it's hard to track.
  1450. */
  1451. $wgEnableUserEmail = true;
  1452. /**
  1453. * Set to true to enable user-to-user e-mail blacklist.
  1454. *
  1455. * @since 1.30
  1456. */
  1457. $wgEnableUserEmailBlacklist = false;
  1458. /**
  1459. * If true put the sending user's email in a Reply-To header
  1460. * instead of From (false). ($wgPasswordSender will be used as From.)
  1461. *
  1462. * Some mailers (eg SMTP) set the SMTP envelope sender to the From value,
  1463. * which can cause problems with SPF validation and leak recipient addresses
  1464. * when bounces are sent to the sender. In addition, DMARC restrictions
  1465. * can cause emails to fail to be received when false.
  1466. */
  1467. $wgUserEmailUseReplyTo = true;
  1468. /**
  1469. * Minimum time, in hours, which must elapse between password reminder
  1470. * emails for a given account. This is to prevent abuse by mail flooding.
  1471. */
  1472. $wgPasswordReminderResendTime = 24;
  1473. /**
  1474. * The time, in seconds, when an emailed temporary password expires.
  1475. */
  1476. $wgNewPasswordExpiry = 3600 * 24 * 7;
  1477. /**
  1478. * The time, in seconds, when an email confirmation email expires
  1479. */
  1480. $wgUserEmailConfirmationTokenExpiry = 7 * 24 * 60 * 60;
  1481. /**
  1482. * The number of days that a user's password is good for. After this number of days, the
  1483. * user will be asked to reset their password. Set to false to disable password expiration.
  1484. */
  1485. $wgPasswordExpirationDays = false;
  1486. /**
  1487. * If a user's password is expired, the number of seconds when they can still login,
  1488. * and cancel their password change, but are sent to the password change form on each login.
  1489. */
  1490. $wgPasswordExpireGrace = 3600 * 24 * 7; // 7 days
  1491. /**
  1492. * SMTP Mode.
  1493. *
  1494. * For using a direct (authenticated) SMTP server connection.
  1495. * Default to false or fill an array :
  1496. *
  1497. * @code
  1498. * $wgSMTP = [
  1499. * 'host' => 'SMTP domain',
  1500. * 'IDHost' => 'domain for MessageID',
  1501. * 'port' => '25',
  1502. * 'auth' => [true|false],
  1503. * 'username' => [SMTP username],
  1504. * 'password' => [SMTP password],
  1505. * ];
  1506. * @endcode
  1507. */
  1508. $wgSMTP = false;
  1509. /**
  1510. * Additional email parameters, will be passed as the last argument to mail() call.
  1511. */
  1512. $wgAdditionalMailParams = null;
  1513. /**
  1514. * For parts of the system that have been updated to provide HTML email content, send
  1515. * both text and HTML parts as the body of the email
  1516. */
  1517. $wgAllowHTMLEmail = false;
  1518. /**
  1519. * True: from page editor if s/he opted-in. False: Enotif mails appear to come
  1520. * from $wgEmergencyContact
  1521. */
  1522. $wgEnotifFromEditor = false;
  1523. // TODO move UPO to preferences probably ?
  1524. # If set to true, users get a corresponding option in their preferences and can choose to
  1525. # enable or disable at their discretion
  1526. # If set to false, the corresponding input form on the user preference page is suppressed
  1527. # It call this to be a "user-preferences-option (UPO)"
  1528. /**
  1529. * Require email authentication before sending mail to an email address.
  1530. * This is highly recommended. It prevents MediaWiki from being used as an open
  1531. * spam relay.
  1532. */
  1533. $wgEmailAuthentication = true;
  1534. /**
  1535. * Allow users to enable email notification ("enotif") on watchlist changes.
  1536. */
  1537. $wgEnotifWatchlist = false;
  1538. /**
  1539. * Allow users to enable email notification ("enotif") when someone edits their
  1540. * user talk page.
  1541. *
  1542. * The owner of the user talk page must also have the 'enotifusertalkpages' user
  1543. * preference set to true.
  1544. */
  1545. $wgEnotifUserTalk = false;
  1546. /**
  1547. * Set the Reply-to address in notifications to the editor's address, if user
  1548. * allowed this in the preferences.
  1549. */
  1550. $wgEnotifRevealEditorAddress = false;
  1551. /**
  1552. * Potentially send notification mails on minor edits to pages. This is enabled
  1553. * by default. If this is false, users will never be notified on minor edits.
  1554. *
  1555. * If it is true, editors with the 'nominornewtalk' right (typically bots) will still not
  1556. * trigger notifications for minor edits they make (to any page, not just user talk).
  1557. *
  1558. * Finally, if the watcher/recipient has the 'enotifminoredits' user preference set to
  1559. * false, they will not receive notifications for minor edits.
  1560. *
  1561. * User talk notifications are also affected by $wgEnotifMinorEdits, the above settings,
  1562. * $wgEnotifUserTalk, and the preference described there.
  1563. */
  1564. $wgEnotifMinorEdits = true;
  1565. /**
  1566. * Send a generic mail instead of a personalised mail for each user. This
  1567. * always uses UTC as the time zone, and doesn't include the username.
  1568. *
  1569. * For pages with many users watching, this can significantly reduce mail load.
  1570. * Has no effect when using sendmail rather than SMTP.
  1571. */
  1572. $wgEnotifImpersonal = false;
  1573. /**
  1574. * Maximum number of users to mail at once when using impersonal mail. Should
  1575. * match the limit on your mail server.
  1576. */
  1577. $wgEnotifMaxRecips = 500;
  1578. /**
  1579. * Use real name instead of username in e-mail "from" field.
  1580. */
  1581. $wgEnotifUseRealName = false;
  1582. /**
  1583. * Array of usernames who will be sent a notification email for every change
  1584. * which occurs on a wiki. Users will not be notified of their own changes.
  1585. */
  1586. $wgUsersNotifiedOnAllChanges = [];
  1587. /** @} */ # end of email settings
  1588. /************************************************************************//**
  1589. * @name Database settings
  1590. * @{
  1591. */
  1592. /**
  1593. * Database host name or IP address
  1594. */
  1595. $wgDBserver = 'localhost';
  1596. /**
  1597. * Database port number (for PostgreSQL and Microsoft SQL Server).
  1598. */
  1599. $wgDBport = 5432;
  1600. /**
  1601. * Name of the database
  1602. */
  1603. $wgDBname = 'my_wiki';
  1604. /**
  1605. * Database username
  1606. */
  1607. $wgDBuser = 'wikiuser';
  1608. /**
  1609. * Database user's password
  1610. */
  1611. $wgDBpassword = '';
  1612. /**
  1613. * Database type
  1614. */
  1615. $wgDBtype = 'mysql';
  1616. /**
  1617. * Whether to use SSL in DB connection.
  1618. *
  1619. * This setting is only used if $wgLBFactoryConf['class'] is set to
  1620. * '\Wikimedia\Rdbms\LBFactorySimple' and $wgDBservers is an empty array; otherwise
  1621. * the DBO_SSL flag must be set in the 'flags' option of the database
  1622. * connection to achieve the same functionality.
  1623. */
  1624. $wgDBssl = false;
  1625. /**
  1626. * Whether to use compression in DB connection.
  1627. *
  1628. * This setting is only used $wgLBFactoryConf['class'] is set to
  1629. * '\Wikimedia\Rdbms\LBFactorySimple' and $wgDBservers is an empty array; otherwise
  1630. * the DBO_COMPRESS flag must be set in the 'flags' option of the database
  1631. * connection to achieve the same functionality.
  1632. */
  1633. $wgDBcompress = false;
  1634. /**
  1635. * Separate username for maintenance tasks. Leave as null to use the default.
  1636. */
  1637. $wgDBadminuser = null;
  1638. /**
  1639. * Separate password for maintenance tasks. Leave as null to use the default.
  1640. */
  1641. $wgDBadminpassword = null;
  1642. /**
  1643. * Search type.
  1644. * Leave as null to select the default search engine for the
  1645. * selected database type (eg SearchMySQL), or set to a class
  1646. * name to override to a custom search engine.
  1647. */
  1648. $wgSearchType = null;
  1649. /**
  1650. * Alternative search types
  1651. * Sometimes you want to support multiple search engines for testing. This
  1652. * allows users to select their search engine of choice via url parameters
  1653. * to Special:Search and the action=search API. If using this, there's no
  1654. * need to add $wgSearchType to it, that is handled automatically.
  1655. */
  1656. $wgSearchTypeAlternatives = null;
  1657. /**
  1658. * Table name prefix
  1659. */
  1660. $wgDBprefix = '';
  1661. /**
  1662. * MySQL table options to use during installation or update
  1663. */
  1664. $wgDBTableOptions = 'ENGINE=InnoDB';
  1665. /**
  1666. * SQL Mode - default is turning off all modes, including strict, if set.
  1667. * null can be used to skip the setting for performance reasons and assume
  1668. * DBA has done his best job.
  1669. * String override can be used for some additional fun :-)
  1670. */
  1671. $wgSQLMode = '';
  1672. /**
  1673. * Mediawiki schema
  1674. */
  1675. $wgDBmwschema = null;
  1676. /**
  1677. * To override default SQLite data directory ($docroot/../data)
  1678. */
  1679. $wgSQLiteDataDir = '';
  1680. /**
  1681. * Shared database for multiple wikis. Commonly used for storing a user table
  1682. * for single sign-on. The server for this database must be the same as for the
  1683. * main database.
  1684. *
  1685. * For backwards compatibility the shared prefix is set to the same as the local
  1686. * prefix, and the user table is listed in the default list of shared tables.
  1687. * The user_properties table is also added so that users will continue to have their
  1688. * preferences shared (preferences were stored in the user table prior to 1.16)
  1689. *
  1690. * $wgSharedTables may be customized with a list of tables to share in the shared
  1691. * database. However it is advised to limit what tables you do share as many of
  1692. * MediaWiki's tables may have side effects if you try to share them.
  1693. *
  1694. * $wgSharedPrefix is the table prefix for the shared database. It defaults to
  1695. * $wgDBprefix.
  1696. *
  1697. * $wgSharedSchema is the table schema for the shared database. It defaults to
  1698. * $wgDBmwschema.
  1699. *
  1700. * @deprecated since 1.21 In new code, use the $wiki parameter to wfGetLB() to
  1701. * access remote databases. Using wfGetLB() allows the shared database to
  1702. * reside on separate servers to the wiki's own database, with suitable
  1703. * configuration of $wgLBFactoryConf.
  1704. */
  1705. $wgSharedDB = null;
  1706. /**
  1707. * @see $wgSharedDB
  1708. */
  1709. $wgSharedPrefix = false;
  1710. /**
  1711. * @see $wgSharedDB
  1712. */
  1713. $wgSharedTables = [ 'user', 'user_properties' ];
  1714. /**
  1715. * @see $wgSharedDB
  1716. * @since 1.23
  1717. */
  1718. $wgSharedSchema = false;
  1719. /**
  1720. * Database load balancer
  1721. * This is a two-dimensional array, an array of server info structures
  1722. * Fields are:
  1723. * - host: Host name
  1724. * - dbname: Default database name
  1725. * - user: DB user
  1726. * - password: DB password
  1727. * - type: DB type
  1728. * - driver: DB driver (when there are multiple drivers)
  1729. *
  1730. * - load: Ratio of DB_REPLICA load, must be >=0, the sum of all loads must be >0.
  1731. * If this is zero for any given server, no normal query traffic will be
  1732. * sent to it. It will be excluded from lag checks in maintenance scripts.
  1733. * The only way it can receive traffic is if groupLoads is used.
  1734. *
  1735. * - groupLoads: array of load ratios, the key is the query group name. A query may belong
  1736. * to several groups, the most specific group defined here is used.
  1737. *
  1738. * - flags: bit field
  1739. * - DBO_DEFAULT -- turns on DBO_TRX only if "cliMode" is off (recommended)
  1740. * - DBO_DEBUG -- equivalent of $wgDebugDumpSql
  1741. * - DBO_TRX -- wrap entire request in a transaction
  1742. * - DBO_NOBUFFER -- turn off buffering (not useful in LocalSettings.php)
  1743. * - DBO_PERSISTENT -- enables persistent database connections
  1744. * - DBO_SSL -- uses SSL/TLS encryption in database connections, if available
  1745. * - DBO_COMPRESS -- uses internal compression in database connections,
  1746. * if available
  1747. *
  1748. * - max lag: (optional) Maximum replication lag before a replica DB goes out of rotation
  1749. * - is static: (optional) Set to true if the dataset is static and no replication is used.
  1750. * - cliMode: (optional) Connection handles will not assume that requests are short-lived
  1751. * nor that INSERT..SELECT can be rewritten into a buffered SELECT and INSERT.
  1752. * [Default: uses value of $wgCommandLineMode]
  1753. *
  1754. * These and any other user-defined properties will be assigned to the mLBInfo member
  1755. * variable of the Database object.
  1756. *
  1757. * Leave at false to use the single-server variables above. If you set this
  1758. * variable, the single-server variables will generally be ignored (except
  1759. * perhaps in some command-line scripts).
  1760. *
  1761. * The first server listed in this array (with key 0) will be the master. The
  1762. * rest of the servers will be replica DBs. To prevent writes to your replica DBs due to
  1763. * accidental misconfiguration or MediaWiki bugs, set read_only=1 on all your
  1764. * replica DBs in my.cnf. You can set read_only mode at runtime using:
  1765. *
  1766. * @code
  1767. * SET @@read_only=1;
  1768. * @endcode
  1769. *
  1770. * Since the effect of writing to a replica DB is so damaging and difficult to clean
  1771. * up, we at Wikimedia set read_only=1 in my.cnf on all our DB servers, even
  1772. * our masters, and then set read_only=0 on masters at runtime.
  1773. */
  1774. $wgDBservers = false;
  1775. /**
  1776. * Load balancer factory configuration
  1777. * To set up a multi-master wiki farm, set the class here to something that
  1778. * can return a LoadBalancer with an appropriate master on a call to getMainLB().
  1779. * The class identified here is responsible for reading $wgDBservers,
  1780. * $wgDBserver, etc., so overriding it may cause those globals to be ignored.
  1781. *
  1782. * The LBFactoryMulti class is provided for this purpose, please see
  1783. * includes/db/LBFactoryMulti.php for configuration information.
  1784. */
  1785. $wgLBFactoryConf = [ 'class' => \Wikimedia\Rdbms\LBFactorySimple::class ];
  1786. /**
  1787. * After a state-changing request is done by a client, this determines
  1788. * how many seconds that client should keep using the master datacenter.
  1789. * This avoids unexpected stale or 404 responses due to replication lag.
  1790. * @since 1.27
  1791. */
  1792. $wgDataCenterUpdateStickTTL = 10;
  1793. /**
  1794. * File to log database errors to
  1795. */
  1796. $wgDBerrorLog = false;
  1797. /**
  1798. * Timezone to use in the error log.
  1799. * Defaults to the wiki timezone ($wgLocaltimezone).
  1800. *
  1801. * A list of usable timezones can found at:
  1802. * https://secure.php.net/manual/en/timezones.php
  1803. *
  1804. * @par Examples:
  1805. * @code
  1806. * $wgDBerrorLogTZ = 'UTC';
  1807. * $wgDBerrorLogTZ = 'GMT';
  1808. * $wgDBerrorLogTZ = 'PST8PDT';
  1809. * $wgDBerrorLogTZ = 'Europe/Sweden';
  1810. * $wgDBerrorLogTZ = 'CET';
  1811. * @endcode
  1812. *
  1813. * @since 1.20
  1814. */
  1815. $wgDBerrorLogTZ = false;
  1816. /**
  1817. * Set to true to engage MySQL 4.1/5.0 charset-related features;
  1818. * for now will just cause sending of 'SET NAMES=utf8' on connect.
  1819. *
  1820. * @warning THIS IS EXPERIMENTAL!
  1821. *
  1822. * May break if you're not using the table defs from mysql5/tables.sql.
  1823. * May break if you're upgrading an existing wiki if set differently.
  1824. * Broken symptoms likely to include incorrect behavior with page titles,
  1825. * usernames, comments etc containing non-ASCII characters.
  1826. * Might also cause failures on the object cache and other things.
  1827. *
  1828. * Even correct usage may cause failures with Unicode supplementary
  1829. * characters (those not in the Basic Multilingual Plane) unless MySQL
  1830. * has enhanced their Unicode support.
  1831. *
  1832. * @deprecated since 1.31
  1833. */
  1834. $wgDBmysql5 = false;
  1835. /**
  1836. * Set true to enable Oracle DCRP (supported from 11gR1 onward)
  1837. *
  1838. * To use this feature set to true and use a datasource defined as
  1839. * POOLED (i.e. in tnsnames definition set server=pooled in connect_data
  1840. * block).
  1841. *
  1842. * Starting from 11gR1 you can use DCRP (Database Resident Connection
  1843. * Pool) that maintains established sessions and reuses them on new
  1844. * connections.
  1845. *
  1846. * Not completely tested, but it should fall back on normal connection
  1847. * in case the pool is full or the datasource is not configured as
  1848. * pooled.
  1849. * And the other way around; using oci_pconnect on a non pooled
  1850. * datasource should produce a normal connection.
  1851. *
  1852. * When it comes to frequent shortlived DB connections like with MW
  1853. * Oracle tends to s***. The problem is the driver connects to the
  1854. * database reasonably fast, but establishing a session takes time and
  1855. * resources. MW does not rely on session state (as it does not use
  1856. * features such as package variables) so establishing a valid session
  1857. * is in this case an unwanted overhead that just slows things down.
  1858. *
  1859. * @warning EXPERIMENTAL!
  1860. */
  1861. $wgDBOracleDRCP = false;
  1862. /**
  1863. * Other wikis on this site, can be administered from a single developer account.
  1864. *
  1865. * Array numeric key => database name
  1866. */
  1867. $wgLocalDatabases = [];
  1868. /**
  1869. * If lag is higher than $wgSlaveLagWarning, show a warning in some special
  1870. * pages (like watchlist). If the lag is higher than $wgSlaveLagCritical,
  1871. * show a more obvious warning.
  1872. */
  1873. $wgSlaveLagWarning = 10;
  1874. /**
  1875. * @see $wgSlaveLagWarning
  1876. */
  1877. $wgSlaveLagCritical = 30;
  1878. /**
  1879. * Use Windows Authentication instead of $wgDBuser / $wgDBpassword for MS SQL Server
  1880. */
  1881. $wgDBWindowsAuthentication = false;
  1882. /**@}*/ # End of DB settings }
  1883. /************************************************************************//**
  1884. * @name Text storage
  1885. * @{
  1886. */
  1887. /**
  1888. * We can also compress text stored in the 'text' table. If this is set on, new
  1889. * revisions will be compressed on page save if zlib support is available. Any
  1890. * compressed revisions will be decompressed on load regardless of this setting,
  1891. * but will not be readable at all* if zlib support is not available.
  1892. */
  1893. $wgCompressRevisions = false;
  1894. /**
  1895. * External stores allow including content
  1896. * from non database sources following URL links.
  1897. *
  1898. * Short names of ExternalStore classes may be specified in an array here:
  1899. * @code
  1900. * $wgExternalStores = [ "http","file","custom" ]...
  1901. * @endcode
  1902. *
  1903. * CAUTION: Access to database might lead to code execution
  1904. */
  1905. $wgExternalStores = [];
  1906. /**
  1907. * An array of external MySQL servers.
  1908. *
  1909. * @par Example:
  1910. * Create a cluster named 'cluster1' containing three servers:
  1911. * @code
  1912. * $wgExternalServers = [
  1913. * 'cluster1' => <array in the same format as $wgDBservers>
  1914. * ];
  1915. * @endcode
  1916. *
  1917. * Used by \Wikimedia\Rdbms\LBFactorySimple, may be ignored if $wgLBFactoryConf is set to
  1918. * another class.
  1919. */
  1920. $wgExternalServers = [];
  1921. /**
  1922. * The place to put new revisions, false to put them in the local text table.
  1923. * Part of a URL, e.g. DB://cluster1
  1924. *
  1925. * Can be an array instead of a single string, to enable data distribution. Keys
  1926. * must be consecutive integers, starting at zero.
  1927. *
  1928. * @par Example:
  1929. * @code
  1930. * $wgDefaultExternalStore = [ 'DB://cluster1', 'DB://cluster2' ];
  1931. * @endcode
  1932. *
  1933. * @var array
  1934. */
  1935. $wgDefaultExternalStore = false;
  1936. /**
  1937. * Revision text may be cached in $wgMemc to reduce load on external storage
  1938. * servers and object extraction overhead for frequently-loaded revisions.
  1939. *
  1940. * Set to 0 to disable, or number of seconds before cache expiry.
  1941. */
  1942. $wgRevisionCacheExpiry = 86400 * 7;
  1943. /** @} */ # end text storage }
  1944. /************************************************************************//**
  1945. * @name Performance hacks and limits
  1946. * @{
  1947. */
  1948. /**
  1949. * Disable database-intensive features
  1950. */
  1951. $wgMiserMode = false;
  1952. /**
  1953. * Disable all query pages if miser mode is on, not just some
  1954. */
  1955. $wgDisableQueryPages = false;
  1956. /**
  1957. * Number of rows to cache in 'querycache' table when miser mode is on
  1958. */
  1959. $wgQueryCacheLimit = 1000;
  1960. /**
  1961. * Number of links to a page required before it is deemed "wanted"
  1962. */
  1963. $wgWantedPagesThreshold = 1;
  1964. /**
  1965. * Enable slow parser functions
  1966. */
  1967. $wgAllowSlowParserFunctions = false;
  1968. /**
  1969. * Allow schema updates
  1970. */
  1971. $wgAllowSchemaUpdates = true;
  1972. /**
  1973. * Maximum article size in kilobytes
  1974. */
  1975. $wgMaxArticleSize = 2048;
  1976. /**
  1977. * The minimum amount of memory that MediaWiki "needs"; MediaWiki will try to
  1978. * raise PHP's memory limit if it's below this amount.
  1979. */
  1980. $wgMemoryLimit = "50M";
  1981. /**
  1982. * The minimum amount of time that MediaWiki needs for "slow" write request,
  1983. * particularly ones with multiple non-atomic writes that *should* be as
  1984. * transactional as possible; MediaWiki will call set_time_limit() if needed.
  1985. * @since 1.26
  1986. */
  1987. $wgTransactionalTimeLimit = 120;
  1988. /** @} */ # end performance hacks }
  1989. /************************************************************************//**
  1990. * @name Cache settings
  1991. * @{
  1992. */
  1993. /**
  1994. * Directory for caching data in the local filesystem. Should not be accessible
  1995. * from the web.
  1996. *
  1997. * Note: if multiple wikis share the same localisation cache directory, they
  1998. * must all have the same set of extensions. You can set a directory just for
  1999. * the localisation cache using $wgLocalisationCacheConf['storeDirectory'].
  2000. */
  2001. $wgCacheDirectory = false;
  2002. /**
  2003. * Main cache type. This should be a cache with fast access, but it may have
  2004. * limited space. By default, it is disabled, since the stock database cache
  2005. * is not fast enough to make it worthwhile.
  2006. *
  2007. * The options are:
  2008. *
  2009. * - CACHE_ANYTHING: Use anything, as long as it works
  2010. * - CACHE_NONE: Do not cache
  2011. * - CACHE_DB: Store cache objects in the DB
  2012. * - CACHE_MEMCACHED: MemCached, must specify servers in $wgMemCachedServers
  2013. * - CACHE_ACCEL: APC, APCU or WinCache
  2014. * - (other): A string may be used which identifies a cache
  2015. * configuration in $wgObjectCaches.
  2016. *
  2017. * @see $wgMessageCacheType, $wgParserCacheType
  2018. */
  2019. $wgMainCacheType = CACHE_NONE;
  2020. /**
  2021. * The cache type for storing the contents of the MediaWiki namespace. This
  2022. * cache is used for a small amount of data which is expensive to regenerate.
  2023. *
  2024. * For available types see $wgMainCacheType.
  2025. */
  2026. $wgMessageCacheType = CACHE_ANYTHING;
  2027. /**
  2028. * The cache type for storing article HTML. This is used to store data which
  2029. * is expensive to regenerate, and benefits from having plenty of storage space.
  2030. *
  2031. * For available types see $wgMainCacheType.
  2032. */
  2033. $wgParserCacheType = CACHE_ANYTHING;
  2034. /**
  2035. * The cache type for storing session data.
  2036. *
  2037. * For available types see $wgMainCacheType.
  2038. */
  2039. $wgSessionCacheType = CACHE_ANYTHING;
  2040. /**
  2041. * The cache type for storing language conversion tables,
  2042. * which are used when parsing certain text and interface messages.
  2043. *
  2044. * For available types see $wgMainCacheType.
  2045. *
  2046. * @since 1.20
  2047. */
  2048. $wgLanguageConverterCacheType = CACHE_ANYTHING;
  2049. /**
  2050. * Advanced object cache configuration.
  2051. *
  2052. * Use this to define the class names and constructor parameters which are used
  2053. * for the various cache types. Custom cache types may be defined here and
  2054. * referenced from $wgMainCacheType, $wgMessageCacheType, $wgParserCacheType,
  2055. * or $wgLanguageConverterCacheType.
  2056. *
  2057. * The format is an associative array where the key is a cache identifier, and
  2058. * the value is an associative array of parameters. The "class" parameter is the
  2059. * class name which will be used. Alternatively, a "factory" parameter may be
  2060. * given, giving a callable function which will generate a suitable cache object.
  2061. */
  2062. $wgObjectCaches = [
  2063. CACHE_NONE => [ 'class' => EmptyBagOStuff::class, 'reportDupes' => false ],
  2064. CACHE_DB => [ 'class' => SqlBagOStuff::class, 'loggroup' => 'SQLBagOStuff' ],
  2065. CACHE_ANYTHING => [ 'factory' => 'ObjectCache::newAnything' ],
  2066. CACHE_ACCEL => [ 'factory' => 'ObjectCache::getLocalServerInstance' ],
  2067. CACHE_MEMCACHED => [ 'class' => MemcachedPhpBagOStuff::class, 'loggroup' => 'memcached' ],
  2068. 'db-replicated' => [
  2069. 'class' => ReplicatedBagOStuff::class,
  2070. 'readFactory' => [
  2071. 'class' => SqlBagOStuff::class,
  2072. 'args' => [ [ 'slaveOnly' => true ] ]
  2073. ],
  2074. 'writeFactory' => [
  2075. 'class' => SqlBagOStuff::class,
  2076. 'args' => [ [ 'slaveOnly' => false ] ]
  2077. ],
  2078. 'loggroup' => 'SQLBagOStuff',
  2079. 'reportDupes' => false
  2080. ],
  2081. 'apc' => [ 'class' => APCBagOStuff::class, 'reportDupes' => false ],
  2082. 'apcu' => [ 'class' => APCUBagOStuff::class, 'reportDupes' => false ],
  2083. 'wincache' => [ 'class' => WinCacheBagOStuff::class, 'reportDupes' => false ],
  2084. 'memcached-php' => [ 'class' => MemcachedPhpBagOStuff::class, 'loggroup' => 'memcached' ],
  2085. 'memcached-pecl' => [ 'class' => MemcachedPeclBagOStuff::class, 'loggroup' => 'memcached' ],
  2086. 'hash' => [ 'class' => HashBagOStuff::class, 'reportDupes' => false ],
  2087. ];
  2088. /**
  2089. * Main Wide-Area-Network cache type. This should be a cache with fast access,
  2090. * but it may have limited space. By default, it is disabled, since the basic stock
  2091. * cache is not fast enough to make it worthwhile. For single data-center setups, this can
  2092. * simply be pointed to a cache in $wgWANObjectCaches that uses a local $wgObjectCaches
  2093. * cache with a relayer of type EventRelayerNull.
  2094. *
  2095. * The options are:
  2096. * - false: Configure the cache using $wgMainCacheType, without using
  2097. * a relayer (only matters if there are multiple data-centers)
  2098. * - CACHE_NONE: Do not cache
  2099. * - (other): A string may be used which identifies a cache
  2100. * configuration in $wgWANObjectCaches
  2101. * @since 1.26
  2102. */
  2103. $wgMainWANCache = false;
  2104. /**
  2105. * Advanced WAN object cache configuration.
  2106. *
  2107. * Each WAN cache wraps a registered object cache (for the local cluster)
  2108. * and it must also be configured to point to a PubSub instance. Subscribers
  2109. * must be configured to relay purges to the actual cache servers.
  2110. *
  2111. * The format is an associative array where the key is a cache identifier, and
  2112. * the value is an associative array of parameters. The "cacheId" parameter is
  2113. * a cache identifier from $wgObjectCaches. The "channels" parameter is a map of
  2114. * actions ('purge') to PubSub channels defined in $wgEventRelayerConfig.
  2115. * The "loggroup" parameter controls where log events are sent.
  2116. *
  2117. * @since 1.26
  2118. */
  2119. $wgWANObjectCaches = [
  2120. CACHE_NONE => [
  2121. 'class' => WANObjectCache::class,
  2122. 'cacheId' => CACHE_NONE,
  2123. 'channels' => []
  2124. ]
  2125. /* Example of a simple single data-center cache:
  2126. 'memcached-php' => [
  2127. 'class' => WANObjectCache::class,
  2128. 'cacheId' => 'memcached-php',
  2129. 'channels' => [ 'purge' => 'wancache-main-memcached-purge' ]
  2130. ]
  2131. */
  2132. ];
  2133. /**
  2134. * Verify and enforce WAN cache purges using reliable DB sources as streams.
  2135. *
  2136. * These secondary cache purges are de-duplicated via simple cache mutexes.
  2137. * This improves consistency when cache purges are lost, which becomes more likely
  2138. * as more cache servers are added or if there are multiple datacenters. Only keys
  2139. * related to important mutable content will be checked.
  2140. *
  2141. * @var bool
  2142. * @since 1.29
  2143. */
  2144. $wgEnableWANCacheReaper = false;
  2145. /**
  2146. * Main object stash type. This should be a fast storage system for storing
  2147. * lightweight data like hit counters and user activity. Sites with multiple
  2148. * data-centers should have this use a store that replicates all writes. The
  2149. * store should have enough consistency for CAS operations to be usable.
  2150. * Reads outside of those needed for merge() may be eventually consistent.
  2151. *
  2152. * The options are:
  2153. * - db: Store cache objects in the DB
  2154. * - (other): A string may be used which identifies a cache
  2155. * configuration in $wgObjectCaches
  2156. *
  2157. * @since 1.26
  2158. */
  2159. $wgMainStash = 'db-replicated';
  2160. /**
  2161. * The expiry time for the parser cache, in seconds.
  2162. * The default is 86400 (one day).
  2163. */
  2164. $wgParserCacheExpireTime = 86400;
  2165. /**
  2166. * @deprecated since 1.27, session data is always stored in object cache.
  2167. */
  2168. $wgSessionsInObjectCache = true;
  2169. /**
  2170. * The expiry time to use for session storage, in seconds.
  2171. */
  2172. $wgObjectCacheSessionExpiry = 3600;
  2173. /**
  2174. * @deprecated since 1.27, MediaWiki\Session\SessionManager doesn't use PHP session storage.
  2175. */
  2176. $wgSessionHandler = null;
  2177. /**
  2178. * Whether to use PHP session handling ($_SESSION and session_*() functions)
  2179. *
  2180. * If the constant MW_NO_SESSION is defined, this is forced to 'disable'.
  2181. *
  2182. * If the constant MW_NO_SESSION_HANDLER is defined, this is ignored and PHP
  2183. * session handling will function independently of SessionHandler.
  2184. * SessionHandler and PHP's session handling may attempt to override each
  2185. * others' cookies.
  2186. *
  2187. * @since 1.27
  2188. * @var string
  2189. * - 'enable': Integrate with PHP's session handling as much as possible.
  2190. * - 'warn': Integrate but log warnings if anything changes $_SESSION.
  2191. * - 'disable': Throw exceptions if PHP session handling is used.
  2192. */
  2193. $wgPHPSessionHandling = 'enable';
  2194. /**
  2195. * Number of internal PBKDF2 iterations to use when deriving session secrets.
  2196. *
  2197. * @since 1.28
  2198. */
  2199. $wgSessionPbkdf2Iterations = 10001;
  2200. /**
  2201. * If enabled, will send MemCached debugging information to $wgDebugLogFile
  2202. */
  2203. $wgMemCachedDebug = false;
  2204. /**
  2205. * The list of MemCached servers and port numbers
  2206. */
  2207. $wgMemCachedServers = [ '127.0.0.1:11211' ];
  2208. /**
  2209. * Use persistent connections to MemCached, which are shared across multiple
  2210. * requests.
  2211. */
  2212. $wgMemCachedPersistent = false;
  2213. /**
  2214. * Read/write timeout for MemCached server communication, in microseconds.
  2215. */
  2216. $wgMemCachedTimeout = 500000;
  2217. /**
  2218. * Set this to true to maintain a copy of the message cache on the local server.
  2219. *
  2220. * This layer of message cache is in addition to the one configured by $wgMessageCacheType.
  2221. *
  2222. * The local copy is put in APC. If APC is not installed, this setting does nothing.
  2223. *
  2224. * Note that this is about the message cache, which stores interface messages
  2225. * maintained as wiki pages. This is separate from the localisation cache for interface
  2226. * messages provided by the software, which is configured by $wgLocalisationCacheConf.
  2227. */
  2228. $wgUseLocalMessageCache = false;
  2229. /**
  2230. * Instead of caching everything, only cache those messages which have
  2231. * been customised in the site content language. This means that
  2232. * MediaWiki:Foo/ja is ignored if MediaWiki:Foo doesn't exist.
  2233. * This option is probably only useful for translatewiki.net.
  2234. */
  2235. $wgAdaptiveMessageCache = false;
  2236. /**
  2237. * Localisation cache configuration. Associative array with keys:
  2238. * class: The class to use. May be overridden by extensions.
  2239. *
  2240. * store: The location to store cache data. May be 'files', 'array', 'db' or
  2241. * 'detect'. If set to "files", data will be in CDB files. If set
  2242. * to "db", data will be stored to the database. If set to
  2243. * "detect", files will be used if $wgCacheDirectory is set,
  2244. * otherwise the database will be used.
  2245. * "array" is an experimental option that uses PHP files that
  2246. * store static arrays.
  2247. *
  2248. * storeClass: The class name for the underlying storage. If set to a class
  2249. * name, it overrides the "store" setting.
  2250. *
  2251. * storeDirectory: If the store class puts its data in files, this is the
  2252. * directory it will use. If this is false, $wgCacheDirectory
  2253. * will be used.
  2254. *
  2255. * manualRecache: Set this to true to disable cache updates on web requests.
  2256. * Use maintenance/rebuildLocalisationCache.php instead.
  2257. */
  2258. $wgLocalisationCacheConf = [
  2259. 'class' => LocalisationCache::class,
  2260. 'store' => 'detect',
  2261. 'storeClass' => false,
  2262. 'storeDirectory' => false,
  2263. 'manualRecache' => false,
  2264. ];
  2265. /**
  2266. * Allow client-side caching of pages
  2267. */
  2268. $wgCachePages = true;
  2269. /**
  2270. * Set this to current time to invalidate all prior cached pages. Affects both
  2271. * client-side and server-side caching.
  2272. * You can get the current date on your server by using the command:
  2273. * @verbatim
  2274. * date +%Y%m%d%H%M%S
  2275. * @endverbatim
  2276. */
  2277. $wgCacheEpoch = '20030516000000';
  2278. /**
  2279. * Directory where GitInfo will look for pre-computed cache files. If false,
  2280. * $wgCacheDirectory/gitinfo will be used.
  2281. */
  2282. $wgGitInfoCacheDirectory = false;
  2283. /**
  2284. * Bump this number when changing the global style sheets and JavaScript.
  2285. *
  2286. * It should be appended in the query string of static CSS and JS includes,
  2287. * to ensure that client-side caches do not keep obsolete copies of global
  2288. * styles.
  2289. *
  2290. * @deprecated since 1.31
  2291. */
  2292. $wgStyleVersion = '303';
  2293. /**
  2294. * This will cache static pages for non-logged-in users to reduce
  2295. * database traffic on public sites. ResourceLoader requests to default
  2296. * language and skins are cached as well as single module requests.
  2297. */
  2298. $wgUseFileCache = false;
  2299. /**
  2300. * Depth of the subdirectory hierarchy to be created under
  2301. * $wgFileCacheDirectory. The subdirectories will be named based on
  2302. * the MD5 hash of the title. A value of 0 means all cache files will
  2303. * be put directly into the main file cache directory.
  2304. */
  2305. $wgFileCacheDepth = 2;
  2306. /**
  2307. * Kept for extension compatibility; see $wgParserCacheType
  2308. * @deprecated since 1.26
  2309. */
  2310. $wgEnableParserCache = true;
  2311. /**
  2312. * Append a configured value to the parser cache and the sitenotice key so
  2313. * that they can be kept separate for some class of activity.
  2314. */
  2315. $wgRenderHashAppend = '';
  2316. /**
  2317. * If on, the sidebar navigation links are cached for users with the
  2318. * current language set. This can save a touch of load on a busy site
  2319. * by shaving off extra message lookups.
  2320. *
  2321. * However it is also fragile: changing the site configuration, or
  2322. * having a variable $wgArticlePath, can produce broken links that
  2323. * don't update as expected.
  2324. */
  2325. $wgEnableSidebarCache = false;
  2326. /**
  2327. * Expiry time for the sidebar cache, in seconds
  2328. */
  2329. $wgSidebarCacheExpiry = 86400;
  2330. /**
  2331. * When using the file cache, we can store the cached HTML gzipped to save disk
  2332. * space. Pages will then also be served compressed to clients that support it.
  2333. *
  2334. * Requires zlib support enabled in PHP.
  2335. */
  2336. $wgUseGzip = false;
  2337. /**
  2338. * Clock skew or the one-second resolution of time() can occasionally cause cache
  2339. * problems when the user requests two pages within a short period of time. This
  2340. * variable adds a given number of seconds to vulnerable timestamps, thereby giving
  2341. * a grace period.
  2342. */
  2343. $wgClockSkewFudge = 5;
  2344. /**
  2345. * Invalidate various caches when LocalSettings.php changes. This is equivalent
  2346. * to setting $wgCacheEpoch to the modification time of LocalSettings.php, as
  2347. * was previously done in the default LocalSettings.php file.
  2348. *
  2349. * On high-traffic wikis, this should be set to false, to avoid the need to
  2350. * check the file modification time, and to avoid the performance impact of
  2351. * unnecessary cache invalidations.
  2352. */
  2353. $wgInvalidateCacheOnLocalSettingsChange = true;
  2354. /**
  2355. * When loading extensions through the extension registration system, this
  2356. * can be used to invalidate the cache. A good idea would be to set this to
  2357. * one file, you can just `touch` that one to invalidate the cache
  2358. *
  2359. * @par Example:
  2360. * @code
  2361. * $wgExtensionInfoMtime = filemtime( "$IP/LocalSettings.php" );
  2362. * @endcode
  2363. *
  2364. * If set to false, the mtime for each individual JSON file will be checked,
  2365. * which can be slow if a large number of extensions are being loaded.
  2366. *
  2367. * @var int|bool
  2368. */
  2369. $wgExtensionInfoMTime = false;
  2370. /** @} */ # end of cache settings
  2371. /************************************************************************//**
  2372. * @name HTTP proxy (CDN) settings
  2373. *
  2374. * Many of these settings apply to any HTTP proxy used in front of MediaWiki,
  2375. * although they are referred to as Squid settings for historical reasons.
  2376. *
  2377. * Achieving a high hit ratio with an HTTP proxy requires special
  2378. * configuration. See https://www.mediawiki.org/wiki/Manual:Squid_caching for
  2379. * more details.
  2380. *
  2381. * @{
  2382. */
  2383. /**
  2384. * Enable/disable CDN.
  2385. * See https://www.mediawiki.org/wiki/Manual:Squid_caching
  2386. */
  2387. $wgUseSquid = false;
  2388. /**
  2389. * If you run Squid3 with ESI support, enable this (default:false):
  2390. */
  2391. $wgUseESI = false;
  2392. /**
  2393. * Send the Key HTTP header for better caching.
  2394. * See https://datatracker.ietf.org/doc/draft-fielding-http-key/ for details.
  2395. * @since 1.27
  2396. */
  2397. $wgUseKeyHeader = false;
  2398. /**
  2399. * Add X-Forwarded-Proto to the Vary and Key headers for API requests and
  2400. * RSS/Atom feeds. Use this if you have an SSL termination setup
  2401. * and need to split the cache between HTTP and HTTPS for API requests,
  2402. * feed requests and HTTP redirect responses in order to prevent cache
  2403. * pollution. This does not affect 'normal' requests to index.php other than
  2404. * HTTP redirects.
  2405. */
  2406. $wgVaryOnXFP = false;
  2407. /**
  2408. * Internal server name as known to CDN, if different.
  2409. *
  2410. * @par Example:
  2411. * @code
  2412. * $wgInternalServer = 'http://yourinternal.tld:8000';
  2413. * @endcode
  2414. */
  2415. $wgInternalServer = false;
  2416. /**
  2417. * Cache TTL for the CDN sent as s-maxage (without ESI) or
  2418. * Surrogate-Control (with ESI). Without ESI, you should strip
  2419. * out s-maxage in the CDN config.
  2420. *
  2421. * 18000 seconds = 5 hours, more cache hits with 2678400 = 31 days.
  2422. */
  2423. $wgSquidMaxage = 18000;
  2424. /**
  2425. * Cache timeout for the CDN when DB replica DB lag is high
  2426. * @see $wgSquidMaxage
  2427. * @since 1.27
  2428. */
  2429. $wgCdnMaxageLagged = 30;
  2430. /**
  2431. * If set, any SquidPurge call on a URL or URLs will send a second purge no less than
  2432. * this many seconds later via the job queue. This requires delayed job support.
  2433. * This should be safely higher than the 'max lag' value in $wgLBFactoryConf, so that
  2434. * replica DB lag does not cause page to be stuck in stales states in CDN.
  2435. *
  2436. * This also fixes race conditions in two-tiered CDN setups (e.g. cdn2 => cdn1 => MediaWiki).
  2437. * If a purge for a URL reaches cdn2 before cdn1 and a request reaches cdn2 for that URL,
  2438. * it will populate the response from the stale cdn1 value. When cdn1 gets the purge, cdn2
  2439. * will still be stale. If the rebound purge delay is safely higher than the time to relay
  2440. * a purge to all nodes, then the rebound puge will clear cdn2 after cdn1 was cleared.
  2441. *
  2442. * @since 1.27
  2443. */
  2444. $wgCdnReboundPurgeDelay = 0;
  2445. /**
  2446. * Cache timeout for the CDN when a response is known to be wrong or incomplete (due to load)
  2447. * @see $wgSquidMaxage
  2448. * @since 1.27
  2449. */
  2450. $wgCdnMaxageSubstitute = 60;
  2451. /**
  2452. * Default maximum age for raw CSS/JS accesses
  2453. *
  2454. * 300 seconds = 5 minutes.
  2455. */
  2456. $wgForcedRawSMaxage = 300;
  2457. /**
  2458. * List of proxy servers to purge on changes; default port is 80. Use IP addresses.
  2459. *
  2460. * When MediaWiki is running behind a proxy, it will trust X-Forwarded-For
  2461. * headers sent/modified from these proxies when obtaining the remote IP address
  2462. *
  2463. * For a list of trusted servers which *aren't* purged, see $wgSquidServersNoPurge.
  2464. */
  2465. $wgSquidServers = [];
  2466. /**
  2467. * As above, except these servers aren't purged on page changes; use to set a
  2468. * list of trusted proxies, etc. Supports both individual IP addresses and
  2469. * CIDR blocks.
  2470. * @since 1.23 Supports CIDR ranges
  2471. */
  2472. $wgSquidServersNoPurge = [];
  2473. /**
  2474. * Whether to use a Host header in purge requests sent to the proxy servers
  2475. * configured in $wgSquidServers. Set this to false to support Squid
  2476. * configured in forward-proxy mode.
  2477. *
  2478. * If this is set to true, a Host header will be sent, and only the path
  2479. * component of the URL will appear on the request line, as if the request
  2480. * were a non-proxy HTTP 1.1 request. Varnish only supports this style of
  2481. * request. Squid supports this style of request only if reverse-proxy mode
  2482. * (http_port ... accel) is enabled.
  2483. *
  2484. * If this is set to false, no Host header will be sent, and the absolute URL
  2485. * will be sent in the request line, as is the standard for an HTTP proxy
  2486. * request in both HTTP 1.0 and 1.1. This style of request is not supported
  2487. * by Varnish, but is supported by Squid in either configuration (forward or
  2488. * reverse).
  2489. *
  2490. * @since 1.21
  2491. */
  2492. $wgSquidPurgeUseHostHeader = true;
  2493. /**
  2494. * Routing configuration for HTCP multicast purging. Add elements here to
  2495. * enable HTCP and determine which purges are sent where. If set to an empty
  2496. * array, HTCP is disabled.
  2497. *
  2498. * Each key in this array is a regular expression to match against the purged
  2499. * URL, or an empty string to match all URLs. The purged URL is matched against
  2500. * the regexes in the order specified, and the first rule whose regex matches
  2501. * is used, all remaining rules will thus be ignored.
  2502. *
  2503. * @par Example configuration to send purges for upload.wikimedia.org to one
  2504. * multicast group and all other purges to another:
  2505. * @code
  2506. * $wgHTCPRouting = [
  2507. * '|^https?://upload\.wikimedia\.org|' => [
  2508. * 'host' => '239.128.0.113',
  2509. * 'port' => 4827,
  2510. * ],
  2511. * '' => [
  2512. * 'host' => '239.128.0.112',
  2513. * 'port' => 4827,
  2514. * ],
  2515. * ];
  2516. * @endcode
  2517. *
  2518. * You can also pass an array of hosts to send purges too. This is useful when
  2519. * you have several multicast groups or unicast address that should receive a
  2520. * given purge. Multiple hosts support was introduced in MediaWiki 1.22.
  2521. *
  2522. * @par Example of sending purges to multiple hosts:
  2523. * @code
  2524. * $wgHTCPRouting = [
  2525. * '' => [
  2526. * // Purges to text caches using multicast
  2527. * [ 'host' => '239.128.0.114', 'port' => '4827' ],
  2528. * // Purges to a hardcoded list of caches
  2529. * [ 'host' => '10.88.66.1', 'port' => '4827' ],
  2530. * [ 'host' => '10.88.66.2', 'port' => '4827' ],
  2531. * [ 'host' => '10.88.66.3', 'port' => '4827' ],
  2532. * ],
  2533. * ];
  2534. * @endcode
  2535. *
  2536. * @since 1.22
  2537. *
  2538. * $wgHTCPRouting replaces $wgHTCPMulticastRouting that was introduced in 1.20.
  2539. * For back compatibility purposes, whenever its array is empty
  2540. * $wgHTCPMutlicastRouting will be used as a fallback if it not null.
  2541. *
  2542. * @see $wgHTCPMulticastTTL
  2543. */
  2544. $wgHTCPRouting = [];
  2545. /**
  2546. * HTCP multicast TTL.
  2547. * @see $wgHTCPRouting
  2548. */
  2549. $wgHTCPMulticastTTL = 1;
  2550. /**
  2551. * Should forwarded Private IPs be accepted?
  2552. */
  2553. $wgUsePrivateIPs = false;
  2554. /** @} */ # end of HTTP proxy settings
  2555. /************************************************************************//**
  2556. * @name Language, regional and character encoding settings
  2557. * @{
  2558. */
  2559. /**
  2560. * Site language code. See languages/data/Names.php for languages supported by
  2561. * MediaWiki out of the box. Not all languages listed there have translations,
  2562. * see languages/messages/ for the list of languages with some localisation.
  2563. *
  2564. * Warning: Don't use any of MediaWiki's deprecated language codes listed in
  2565. * LanguageCode::getDeprecatedCodeMapping or $wgDummyLanguageCodes, like "no"
  2566. * for Norwegian (use "nb" instead). If you do, things will break unexpectedly.
  2567. *
  2568. * This defines the default interface language for all users, but users can
  2569. * change it in their preferences.
  2570. *
  2571. * This also defines the language of pages in the wiki. The content is wrapped
  2572. * in a html element with lang=XX attribute. This behavior can be overridden
  2573. * via hooks, see Title::getPageLanguage.
  2574. */
  2575. $wgLanguageCode = 'en';
  2576. /**
  2577. * Language cache size, or really how many languages can we handle
  2578. * simultaneously without degrading to crawl speed.
  2579. */
  2580. $wgLangObjCacheSize = 10;
  2581. /**
  2582. * Some languages need different word forms, usually for different cases.
  2583. * Used in Language::convertGrammar().
  2584. *
  2585. * @par Example:
  2586. * @code
  2587. * $wgGrammarForms['en']['genitive']['car'] = 'car\'s';
  2588. * @endcode
  2589. */
  2590. $wgGrammarForms = [];
  2591. /**
  2592. * Treat language links as magic connectors, not inline links
  2593. */
  2594. $wgInterwikiMagic = true;
  2595. /**
  2596. * Hide interlanguage links from the sidebar
  2597. */
  2598. $wgHideInterlanguageLinks = false;
  2599. /**
  2600. * List of additional interwiki prefixes that should be treated as
  2601. * interlanguage links (i.e. placed in the sidebar).
  2602. * Notes:
  2603. * - This will not do anything unless the prefixes are defined in the interwiki
  2604. * map.
  2605. * - The display text for these custom interlanguage links will be fetched from
  2606. * the system message "interlanguage-link-xyz" where xyz is the prefix in
  2607. * this array.
  2608. * - A friendly name for each site, used for tooltip text, may optionally be
  2609. * placed in the system message "interlanguage-link-sitename-xyz" where xyz is
  2610. * the prefix in this array.
  2611. */
  2612. $wgExtraInterlanguageLinkPrefixes = [];
  2613. /**
  2614. * List of language names or overrides for default names in Names.php
  2615. */
  2616. $wgExtraLanguageNames = [];
  2617. /**
  2618. * List of mappings from one language code to another.
  2619. * This array makes the codes not appear as a selectable language on the
  2620. * installer, and excludes them when running the transstat.php script.
  2621. *
  2622. * In Setup.php, the variable $wgDummyLanguageCodes is created by combining
  2623. * these codes with a list of "deprecated" codes, which are mostly leftovers
  2624. * from renames or other legacy things, and the internal codes 'qqq' and 'qqx'.
  2625. * If a mapping in $wgExtraLanguageCodes collide with a built-in mapping, the
  2626. * value in $wgExtraLanguageCodes will be used.
  2627. *
  2628. * @since 1.29
  2629. */
  2630. $wgExtraLanguageCodes = [
  2631. 'bh' => 'bho', // Bihari language family
  2632. 'no' => 'nb', // Norwegian language family
  2633. 'simple' => 'en', // Simple English
  2634. ];
  2635. /**
  2636. * Functionally the same as $wgExtraLanguageCodes, but deprecated. Instead of
  2637. * appending values to this array, append them to $wgExtraLanguageCodes.
  2638. *
  2639. * @deprecated since 1.29
  2640. */
  2641. $wgDummyLanguageCodes = [];
  2642. /**
  2643. * Set this to true to replace Arabic presentation forms with their standard
  2644. * forms in the U+0600-U+06FF block. This only works if $wgLanguageCode is
  2645. * set to "ar".
  2646. *
  2647. * Note that pages with titles containing presentation forms will become
  2648. * inaccessible, run maintenance/cleanupTitles.php to fix this.
  2649. */
  2650. $wgFixArabicUnicode = true;
  2651. /**
  2652. * Set this to true to replace ZWJ-based chillu sequences in Malayalam text
  2653. * with their Unicode 5.1 equivalents. This only works if $wgLanguageCode is
  2654. * set to "ml". Note that some clients (even new clients as of 2010) do not
  2655. * support these characters.
  2656. *
  2657. * If you enable this on an existing wiki, run maintenance/cleanupTitles.php to
  2658. * fix any ZWJ sequences in existing page titles.
  2659. */
  2660. $wgFixMalayalamUnicode = true;
  2661. /**
  2662. * Set this to always convert certain Unicode sequences to modern ones
  2663. * regardless of the content language. This has a small performance
  2664. * impact.
  2665. *
  2666. * See $wgFixArabicUnicode and $wgFixMalayalamUnicode for conversion
  2667. * details.
  2668. *
  2669. * @since 1.17
  2670. */
  2671. $wgAllUnicodeFixes = false;
  2672. /**
  2673. * Set this to eg 'ISO-8859-1' to perform character set conversion when
  2674. * loading old revisions not marked with "utf-8" flag. Use this when
  2675. * converting a wiki from MediaWiki 1.4 or earlier to UTF-8 without the
  2676. * burdensome mass conversion of old text data.
  2677. *
  2678. * @note This DOES NOT touch any fields other than old_text. Titles, comments,
  2679. * user names, etc still must be converted en masse in the database before
  2680. * continuing as a UTF-8 wiki.
  2681. */
  2682. $wgLegacyEncoding = false;
  2683. /**
  2684. * @deprecated since 1.30, does nothing
  2685. */
  2686. $wgBrowserBlackList = [];
  2687. /**
  2688. * If set to true, the MediaWiki 1.4 to 1.5 schema conversion will
  2689. * create stub reference rows in the text table instead of copying
  2690. * the full text of all current entries from 'cur' to 'text'.
  2691. *
  2692. * This will speed up the conversion step for large sites, but
  2693. * requires that the cur table be kept around for those revisions
  2694. * to remain viewable.
  2695. *
  2696. * This option affects the updaters *only*. Any present cur stub
  2697. * revisions will be readable at runtime regardless of this setting.
  2698. */
  2699. $wgLegacySchemaConversion = false;
  2700. /**
  2701. * Enable dates like 'May 12' instead of '12 May', if the default date format
  2702. * is 'dmy or mdy'.
  2703. */
  2704. $wgAmericanDates = false;
  2705. /**
  2706. * For Hindi and Arabic use local numerals instead of Western style (0-9)
  2707. * numerals in interface.
  2708. */
  2709. $wgTranslateNumerals = true;
  2710. /**
  2711. * Translation using MediaWiki: namespace.
  2712. * Interface messages will be loaded from the database.
  2713. */
  2714. $wgUseDatabaseMessages = true;
  2715. /**
  2716. * Expiry time for the message cache key
  2717. */
  2718. $wgMsgCacheExpiry = 86400;
  2719. /**
  2720. * Maximum entry size in the message cache, in bytes
  2721. */
  2722. $wgMaxMsgCacheEntrySize = 10000;
  2723. /**
  2724. * Whether to enable language variant conversion.
  2725. */
  2726. $wgDisableLangConversion = false;
  2727. /**
  2728. * Whether to enable language variant conversion for links.
  2729. */
  2730. $wgDisableTitleConversion = false;
  2731. /**
  2732. * Default variant code, if false, the default will be the language code
  2733. */
  2734. $wgDefaultLanguageVariant = false;
  2735. /**
  2736. * Whether to enable the pig latin variant of English (en-x-piglatin),
  2737. * used to ease variant development work.
  2738. */
  2739. $wgUsePigLatinVariant = false;
  2740. /**
  2741. * Disabled variants array of language variant conversion.
  2742. *
  2743. * @par Example:
  2744. * @code
  2745. * $wgDisabledVariants[] = 'zh-mo';
  2746. * $wgDisabledVariants[] = 'zh-my';
  2747. * @endcode
  2748. */
  2749. $wgDisabledVariants = [];
  2750. /**
  2751. * Like $wgArticlePath, but on multi-variant wikis, this provides a
  2752. * path format that describes which parts of the URL contain the
  2753. * language variant.
  2754. *
  2755. * @par Example:
  2756. * @code
  2757. * $wgLanguageCode = 'sr';
  2758. * $wgVariantArticlePath = '/$2/$1';
  2759. * $wgArticlePath = '/wiki/$1';
  2760. * @endcode
  2761. *
  2762. * A link to /wiki/ would be redirected to /sr/Главна_страна
  2763. *
  2764. * It is important that $wgArticlePath not overlap with possible values
  2765. * of $wgVariantArticlePath.
  2766. */
  2767. $wgVariantArticlePath = false;
  2768. /**
  2769. * Show a bar of language selection links in the user login and user
  2770. * registration forms; edit the "loginlanguagelinks" message to
  2771. * customise these.
  2772. */
  2773. $wgLoginLanguageSelector = false;
  2774. /**
  2775. * When translating messages with wfMessage(), it is not always clear what
  2776. * should be considered UI messages and what should be content messages.
  2777. *
  2778. * For example, for the English Wikipedia, there should be only one 'mainpage',
  2779. * so when getting the link for 'mainpage', we should treat it as site content
  2780. * and call ->inContentLanguage()->text(), but for rendering the text of the
  2781. * link, we call ->text(). The code behaves this way by default. However,
  2782. * sites like the Wikimedia Commons do offer different versions of 'mainpage'
  2783. * and the like for different languages. This array provides a way to override
  2784. * the default behavior.
  2785. *
  2786. * @par Example:
  2787. * To allow language-specific main page and community
  2788. * portal:
  2789. * @code
  2790. * $wgForceUIMsgAsContentMsg = [ 'mainpage', 'portal-url' ];
  2791. * @endcode
  2792. */
  2793. $wgForceUIMsgAsContentMsg = [];
  2794. /**
  2795. * Fake out the timezone that the server thinks it's in. This will be used for
  2796. * date display and not for what's stored in the DB. Leave to null to retain
  2797. * your server's OS-based timezone value.
  2798. *
  2799. * This variable is currently used only for signature formatting and for local
  2800. * time/date parser variables ({{LOCALTIME}} etc.)
  2801. *
  2802. * Timezones can be translated by editing MediaWiki messages of type
  2803. * timezone-nameinlowercase like timezone-utc.
  2804. *
  2805. * A list of usable timezones can found at:
  2806. * https://secure.php.net/manual/en/timezones.php
  2807. *
  2808. * @par Examples:
  2809. * @code
  2810. * $wgLocaltimezone = 'UTC';
  2811. * $wgLocaltimezone = 'GMT';
  2812. * $wgLocaltimezone = 'PST8PDT';
  2813. * $wgLocaltimezone = 'Europe/Sweden';
  2814. * $wgLocaltimezone = 'CET';
  2815. * @endcode
  2816. */
  2817. $wgLocaltimezone = null;
  2818. /**
  2819. * Set an offset from UTC in minutes to use for the default timezone setting
  2820. * for anonymous users and new user accounts.
  2821. *
  2822. * This setting is used for most date/time displays in the software, and is
  2823. * overridable in user preferences. It is *not* used for signature timestamps.
  2824. *
  2825. * By default, this will be set to match $wgLocaltimezone.
  2826. */
  2827. $wgLocalTZoffset = null;
  2828. /** @} */ # End of language/charset settings
  2829. /*************************************************************************//**
  2830. * @name Output format and skin settings
  2831. * @{
  2832. */
  2833. /**
  2834. * The default Content-Type header.
  2835. */
  2836. $wgMimeType = 'text/html';
  2837. /**
  2838. * Previously used as content type in HTML script tags. This is now ignored since
  2839. * HTML5 doesn't require a MIME type for script tags (javascript is the default).
  2840. * It was also previously used by RawAction to determine the ctype query parameter
  2841. * value that will result in a javascript response.
  2842. * @deprecated since 1.22
  2843. */
  2844. $wgJsMimeType = null;
  2845. /**
  2846. * The default xmlns attribute. The option to define this has been removed.
  2847. * The value of this variable is no longer used by core and is set to a fixed
  2848. * value in Setup.php for compatibility with extensions that depend on the value
  2849. * of this variable being set. Such a dependency however is deprecated.
  2850. * @deprecated since 1.22
  2851. */
  2852. $wgXhtmlDefaultNamespace = null;
  2853. /**
  2854. * Previously used to determine if we should output an HTML5 doctype.
  2855. * This is no longer used as we always output HTML5 now. For compatibility with
  2856. * extensions that still check the value of this config it's value is now forced
  2857. * to true by Setup.php.
  2858. * @deprecated since 1.22
  2859. */
  2860. $wgHtml5 = true;
  2861. /**
  2862. * Defines the value of the version attribute in the &lt;html&gt; tag, if any.
  2863. *
  2864. * If your wiki uses RDFa, set it to the correct value for RDFa+HTML5.
  2865. * Correct current values are 'HTML+RDFa 1.0' or 'XHTML+RDFa 1.0'.
  2866. * See also https://www.w3.org/TR/rdfa-in-html/#document-conformance
  2867. * @since 1.16
  2868. */
  2869. $wgHtml5Version = null;
  2870. /**
  2871. * Temporary variable that allows HTMLForms to be rendered as tables.
  2872. * Table based layouts cause various issues when designing for mobile.
  2873. * This global allows skins or extensions a means to force non-table based rendering.
  2874. * Setting to false forces form components to always render as div elements.
  2875. * @since 1.24
  2876. */
  2877. $wgHTMLFormAllowTableFormat = true;
  2878. /**
  2879. * Temporary variable that applies MediaWiki UI wherever it can be supported.
  2880. * Temporary variable that should be removed when mediawiki ui is more
  2881. * stable and change has been communicated.
  2882. * @since 1.24
  2883. */
  2884. $wgUseMediaWikiUIEverywhere = false;
  2885. /**
  2886. * Whether to label the store-to-database-and-show-to-others button in the editor
  2887. * as "Save page"/"Save changes" if false (the default) or, if true, instead as
  2888. * "Publish page"/"Publish changes".
  2889. *
  2890. * @since 1.28
  2891. */
  2892. $wgEditSubmitButtonLabelPublish = false;
  2893. /**
  2894. * Permit other namespaces in addition to the w3.org default.
  2895. *
  2896. * Use the prefix for the key and the namespace for the value.
  2897. *
  2898. * @par Example:
  2899. * @code
  2900. * $wgXhtmlNamespaces['svg'] = 'http://www.w3.org/2000/svg';
  2901. * @endcode
  2902. * Normally we wouldn't have to define this in the root "<html>"
  2903. * element, but IE needs it there in some circumstances.
  2904. *
  2905. * This is ignored if $wgMimeType is set to a non-XML MIME type.
  2906. */
  2907. $wgXhtmlNamespaces = [];
  2908. /**
  2909. * Site notice shown at the top of each page
  2910. *
  2911. * MediaWiki:Sitenotice page, which will override this. You can also
  2912. * provide a separate message for logged-out users using the
  2913. * MediaWiki:Anonnotice page.
  2914. */
  2915. $wgSiteNotice = '';
  2916. /**
  2917. * If this is set, a "donate" link will appear in the sidebar. Set it to a URL.
  2918. */
  2919. $wgSiteSupportPage = '';
  2920. /**
  2921. * Default skin, for new users and anonymous visitors. Registered users may
  2922. * change this to any one of the other available skins in their preferences.
  2923. */
  2924. $wgDefaultSkin = 'vector';
  2925. /**
  2926. * Fallback skin used when the skin defined by $wgDefaultSkin can't be found.
  2927. *
  2928. * @since 1.24
  2929. */
  2930. $wgFallbackSkin = 'fallback';
  2931. /**
  2932. * Specify the names of skins that should not be presented in the list of
  2933. * available skins in user preferences. If you want to remove a skin entirely,
  2934. * remove it from the skins/ directory and its entry from LocalSettings.php.
  2935. */
  2936. $wgSkipSkins = [];
  2937. /**
  2938. * @deprecated since 1.23; use $wgSkipSkins instead
  2939. */
  2940. $wgSkipSkin = '';
  2941. /**
  2942. * Allow user Javascript page?
  2943. * This enables a lot of neat customizations, but may
  2944. * increase security risk to users and server load.
  2945. */
  2946. $wgAllowUserJs = false;
  2947. /**
  2948. * Allow user Cascading Style Sheets (CSS)?
  2949. * This enables a lot of neat customizations, but may
  2950. * increase security risk to users and server load.
  2951. */
  2952. $wgAllowUserCss = false;
  2953. /**
  2954. * Allow style-related user-preferences?
  2955. *
  2956. * This controls whether the `editfont` and `underline` preferences
  2957. * are availabe to users.
  2958. */
  2959. $wgAllowUserCssPrefs = true;
  2960. /**
  2961. * Use the site's Javascript page?
  2962. */
  2963. $wgUseSiteJs = true;
  2964. /**
  2965. * Use the site's Cascading Style Sheets (CSS)?
  2966. */
  2967. $wgUseSiteCss = true;
  2968. /**
  2969. * Break out of framesets. This can be used to prevent clickjacking attacks,
  2970. * or to prevent external sites from framing your site with ads.
  2971. */
  2972. $wgBreakFrames = false;
  2973. /**
  2974. * The X-Frame-Options header to send on pages sensitive to clickjacking
  2975. * attacks, such as edit pages. This prevents those pages from being displayed
  2976. * in a frame or iframe. The options are:
  2977. *
  2978. * - 'DENY': Do not allow framing. This is recommended for most wikis.
  2979. *
  2980. * - 'SAMEORIGIN': Allow framing by pages on the same domain. This can be used
  2981. * to allow framing within a trusted domain. This is insecure if there
  2982. * is a page on the same domain which allows framing of arbitrary URLs.
  2983. *
  2984. * - false: Allow all framing. This opens up the wiki to XSS attacks and thus
  2985. * full compromise of local user accounts. Private wikis behind a
  2986. * corporate firewall are especially vulnerable. This is not
  2987. * recommended.
  2988. *
  2989. * For extra safety, set $wgBreakFrames = true, to prevent framing on all pages,
  2990. * not just edit pages.
  2991. */
  2992. $wgEditPageFrameOptions = 'DENY';
  2993. /**
  2994. * Disallow framing of API pages directly, by setting the X-Frame-Options
  2995. * header. Since the API returns CSRF tokens, allowing the results to be
  2996. * framed can compromise your user's account security.
  2997. * Options are:
  2998. * - 'DENY': Do not allow framing. This is recommended for most wikis.
  2999. * - 'SAMEORIGIN': Allow framing by pages on the same domain.
  3000. * - false: Allow all framing.
  3001. * Note: $wgBreakFrames will override this for human formatted API output.
  3002. */
  3003. $wgApiFrameOptions = 'DENY';
  3004. /**
  3005. * Disable output compression (enabled by default if zlib is available)
  3006. */
  3007. $wgDisableOutputCompression = false;
  3008. /**
  3009. * Abandoned experiment with HTML5-style ID escaping. Normalized IDs a bit
  3010. * too aggressively, breaking preexisting content (particularly Cite).
  3011. * See T29733, T29694, T29474.
  3012. *
  3013. * @deprecated since 1.30, use $wgFragmentMode
  3014. */
  3015. $wgExperimentalHtmlIds = false;
  3016. /**
  3017. * How should section IDs be encoded?
  3018. * This array can contain 1 or 2 elements, each of them can be one of:
  3019. * - 'html5' is modern HTML5 style encoding with minimal escaping. Displays Unicode
  3020. * characters in most browsers' address bars.
  3021. * - 'legacy' is old MediaWiki-style encoding, e.g. 啤酒 turns into .E5.95.A4.E9.85.92
  3022. * - 'html5-legacy' corresponds to DEPRECATED $wgExperimentalHtmlIds mode. DO NOT use
  3023. * it for anything but migration off that mode (see below).
  3024. *
  3025. * The first element of this array specifies the primary mode of escaping IDs. This
  3026. * is what users will see when they e.g. follow an [[#internal link]] to a section of
  3027. * a page.
  3028. *
  3029. * The optional second element defines a fallback mode, useful for migrations.
  3030. * If present, it will direct MediaWiki to add empty <span>s to every section with its
  3031. * id attribute set to fallback encoded title so that links using the previous encoding
  3032. * would still work.
  3033. *
  3034. * Example: you want to migrate your wiki from 'legacy' to 'html5'
  3035. *
  3036. * On the first step, set this variable to [ 'legacy', 'html5' ]. After a while, when
  3037. * all caches (parser, HTTP, etc.) contain only pages generated with this setting,
  3038. * flip the value to [ 'html5', 'legacy' ]. This will result in all internal links being
  3039. * generated in the new encoding while old links (both external and cached internal) will
  3040. * still work. After a long time, you might want to ditch backwards compatibility and
  3041. * set it to [ 'html5' ]. After all, pages get edited, breaking incoming links no matter which
  3042. * fragment mode is used.
  3043. *
  3044. * @since 1.30
  3045. */
  3046. $wgFragmentMode = [ 'legacy', 'html5' ];
  3047. /**
  3048. * Which ID escaping mode should be used for external interwiki links? See documentation
  3049. * for $wgFragmentMode above for details of each mode. Because you can't control external sites,
  3050. * this setting should probably always be 'legacy', unless every wiki you link to has converted
  3051. * to 'html5'.
  3052. *
  3053. * @since 1.30
  3054. */
  3055. $wgExternalInterwikiFragmentMode = 'legacy';
  3056. /**
  3057. * Abstract list of footer icons for skins in place of old copyrightico and poweredbyico code
  3058. * You can add new icons to the built in copyright or poweredby, or you can create
  3059. * a new block. Though note that you may need to add some custom css to get good styling
  3060. * of new blocks in monobook. vector and modern should work without any special css.
  3061. *
  3062. * $wgFooterIcons itself is a key/value array.
  3063. * The key is the name of a block that the icons will be wrapped in. The final id varies
  3064. * by skin; Monobook and Vector will turn poweredby into f-poweredbyico while Modern
  3065. * turns it into mw_poweredby.
  3066. * The value is either key/value array of icons or a string.
  3067. * In the key/value array the key may or may not be used by the skin but it can
  3068. * be used to find the icon and unset it or change the icon if needed.
  3069. * This is useful for disabling icons that are set by extensions.
  3070. * The value should be either a string or an array. If it is a string it will be output
  3071. * directly as html, however some skins may choose to ignore it. An array is the preferred format
  3072. * for the icon, the following keys are used:
  3073. * - src: An absolute url to the image to use for the icon, this is recommended
  3074. * but not required, however some skins will ignore icons without an image
  3075. * - srcset: optional additional-resolution images; see HTML5 specs
  3076. * - url: The url to use in the a element around the text or icon, if not set an a element will
  3077. * not be outputted
  3078. * - alt: This is the text form of the icon, it will be displayed without an image in
  3079. * skins like Modern or if src is not set, and will otherwise be used as
  3080. * the alt="" for the image. This key is required.
  3081. * - width and height: If the icon specified by src is not of the standard size
  3082. * you can specify the size of image to use with these keys.
  3083. * Otherwise they will default to the standard 88x31.
  3084. * @todo Reformat documentation.
  3085. */
  3086. $wgFooterIcons = [
  3087. "copyright" => [
  3088. "copyright" => [], // placeholder for the built in copyright icon
  3089. ],
  3090. "poweredby" => [
  3091. "mediawiki" => [
  3092. // Defaults to point at
  3093. // "$wgResourceBasePath/resources/assets/poweredby_mediawiki_88x31.png"
  3094. // plus srcset for 1.5x, 2x resolution variants.
  3095. "src" => null,
  3096. "url" => "//www.mediawiki.org/",
  3097. "alt" => "Powered by MediaWiki",
  3098. ]
  3099. ],
  3100. ];
  3101. /**
  3102. * Login / create account link behavior when it's possible for anonymous users
  3103. * to create an account.
  3104. * - true = use a combined login / create account link
  3105. * - false = split login and create account into two separate links
  3106. */
  3107. $wgUseCombinedLoginLink = false;
  3108. /**
  3109. * Display user edit counts in various prominent places.
  3110. */
  3111. $wgEdititis = false;
  3112. /**
  3113. * Some web hosts attempt to rewrite all responses with a 404 (not found)
  3114. * status code, mangling or hiding MediaWiki's output. If you are using such a
  3115. * host, you should start looking for a better one. While you're doing that,
  3116. * set this to false to convert some of MediaWiki's 404 responses to 200 so
  3117. * that the generated error pages can be seen.
  3118. *
  3119. * In cases where for technical reasons it is more important for MediaWiki to
  3120. * send the correct status code than for the body to be transmitted intact,
  3121. * this configuration variable is ignored.
  3122. */
  3123. $wgSend404Code = true;
  3124. /**
  3125. * The $wgShowRollbackEditCount variable is used to show how many edits can be rolled back.
  3126. * The numeric value of the variable controls how many edits MediaWiki will look back to
  3127. * determine whether a rollback is allowed (by checking that they are all from the same author).
  3128. * If the value is false or 0, the edits are not counted. Disabling this will prevent MediaWiki
  3129. * from hiding some useless rollback links.
  3130. *
  3131. * @since 1.20
  3132. */
  3133. $wgShowRollbackEditCount = 10;
  3134. /**
  3135. * Output a <link rel="canonical"> tag on every page indicating the canonical
  3136. * server which should be used, i.e. $wgServer or $wgCanonicalServer. Since
  3137. * detection of the current server is unreliable, the link is sent
  3138. * unconditionally.
  3139. */
  3140. $wgEnableCanonicalServerLink = false;
  3141. /**
  3142. * When OutputHandler is used, mangle any output that contains
  3143. * <cross-domain-policy>. Without this, an attacker can send their own
  3144. * cross-domain policy unless it is prevented by the crossdomain.xml file at
  3145. * the domain root.
  3146. *
  3147. * @since 1.25
  3148. */
  3149. $wgMangleFlashPolicy = true;
  3150. /** @} */ # End of output format settings }
  3151. /*************************************************************************//**
  3152. * @name ResourceLoader settings
  3153. * @{
  3154. */
  3155. /**
  3156. * Client-side resource modules.
  3157. *
  3158. * Extensions should add their ResourceLoader module definitions
  3159. * to the $wgResourceModules variable.
  3160. *
  3161. * @par Example:
  3162. * @code
  3163. * $wgResourceModules['ext.myExtension'] = [
  3164. * 'scripts' => 'myExtension.js',
  3165. * 'styles' => 'myExtension.css',
  3166. * 'dependencies' => [ 'jquery.cookie', 'jquery.tabIndex' ],
  3167. * 'localBasePath' => __DIR__,
  3168. * 'remoteExtPath' => 'MyExtension',
  3169. * ];
  3170. * @endcode
  3171. */
  3172. $wgResourceModules = [];
  3173. /**
  3174. * Skin-specific styles for resource modules.
  3175. *
  3176. * These are later added to the 'skinStyles' list of the existing module. The 'styles' list can
  3177. * not be modified or disabled.
  3178. *
  3179. * For example, here is a module "bar" and how skin Foo would provide additional styles for it.
  3180. *
  3181. * @par Example:
  3182. * @code
  3183. * $wgResourceModules['bar'] = [
  3184. * 'scripts' => 'resources/bar/bar.js',
  3185. * 'styles' => 'resources/bar/main.css',
  3186. * ];
  3187. *
  3188. * $wgResourceModuleSkinStyles['foo'] = [
  3189. * 'bar' => 'skins/Foo/bar.css',
  3190. * ];
  3191. * @endcode
  3192. *
  3193. * This is mostly equivalent to:
  3194. *
  3195. * @par Equivalent:
  3196. * @code
  3197. * $wgResourceModules['bar'] = [
  3198. * 'scripts' => 'resources/bar/bar.js',
  3199. * 'styles' => 'resources/bar/main.css',
  3200. * 'skinStyles' => [
  3201. * 'foo' => skins/Foo/bar.css',
  3202. * ],
  3203. * ];
  3204. * @endcode
  3205. *
  3206. * If the module already defines its own entry in `skinStyles` for a given skin, then
  3207. * $wgResourceModuleSkinStyles is ignored.
  3208. *
  3209. * If a module defines a `skinStyles['default']` the skin may want to extend that instead
  3210. * of replacing them. This can be done using the `+` prefix.
  3211. *
  3212. * @par Example:
  3213. * @code
  3214. * $wgResourceModules['bar'] = [
  3215. * 'scripts' => 'resources/bar/bar.js',
  3216. * 'styles' => 'resources/bar/basic.css',
  3217. * 'skinStyles' => [
  3218. * 'default' => 'resources/bar/additional.css',
  3219. * ],
  3220. * ];
  3221. * // Note the '+' character:
  3222. * $wgResourceModuleSkinStyles['foo'] = [
  3223. * '+bar' => 'skins/Foo/bar.css',
  3224. * ];
  3225. * @endcode
  3226. *
  3227. * This is mostly equivalent to:
  3228. *
  3229. * @par Equivalent:
  3230. * @code
  3231. * $wgResourceModules['bar'] = [
  3232. * 'scripts' => 'resources/bar/bar.js',
  3233. * 'styles' => 'resources/bar/basic.css',
  3234. * 'skinStyles' => [
  3235. * 'default' => 'resources/bar/additional.css',
  3236. * 'foo' => [
  3237. * 'resources/bar/additional.css',
  3238. * 'skins/Foo/bar.css',
  3239. * ],
  3240. * ],
  3241. * ];
  3242. * @endcode
  3243. *
  3244. * In other words, as a module author, use the `styles` list for stylesheets that may not be
  3245. * disabled by a skin. To provide default styles that may be extended or replaced,
  3246. * use `skinStyles['default']`.
  3247. *
  3248. * As with $wgResourceModules, paths default to being relative to the MediaWiki root.
  3249. * You should always provide a localBasePath and remoteBasePath (or remoteExtPath/remoteSkinPath).
  3250. *
  3251. * @par Example:
  3252. * @code
  3253. * $wgResourceModuleSkinStyles['foo'] = [
  3254. * 'bar' => 'bar.css',
  3255. * 'quux' => 'quux.css',
  3256. * 'remoteSkinPath' => 'Foo',
  3257. * 'localBasePath' => __DIR__,
  3258. * ];
  3259. * @endcode
  3260. */
  3261. $wgResourceModuleSkinStyles = [];
  3262. /**
  3263. * Extensions should register foreign module sources here. 'local' is a
  3264. * built-in source that is not in this array, but defined by
  3265. * ResourceLoader::__construct() so that it cannot be unset.
  3266. *
  3267. * @par Example:
  3268. * @code
  3269. * $wgResourceLoaderSources['foo'] = 'http://example.org/w/load.php';
  3270. * @endcode
  3271. */
  3272. $wgResourceLoaderSources = [];
  3273. /**
  3274. * The default 'remoteBasePath' value for instances of ResourceLoaderFileModule.
  3275. * Defaults to $wgScriptPath.
  3276. */
  3277. $wgResourceBasePath = null;
  3278. /**
  3279. * Maximum time in seconds to cache resources served by ResourceLoader.
  3280. * Used to set last modified headers (max-age/s-maxage).
  3281. *
  3282. * Following options to distinguish:
  3283. * - versioned: Used for modules with a version, because changing version
  3284. * numbers causes cache misses. This normally has a long expiry time.
  3285. * - unversioned: Used for modules without a version to propagate changes
  3286. * quickly to clients. Also used for modules with errors to recover quickly.
  3287. * This normally has a short expiry time.
  3288. *
  3289. * Expiry time for the options to distinguish:
  3290. * - server: Squid/Varnish but also any other public proxy cache between the
  3291. * client and MediaWiki.
  3292. * - client: On the client side (e.g. in the browser cache).
  3293. */
  3294. $wgResourceLoaderMaxage = [
  3295. 'versioned' => [
  3296. 'server' => 30 * 24 * 60 * 60, // 30 days
  3297. 'client' => 30 * 24 * 60 * 60, // 30 days
  3298. ],
  3299. 'unversioned' => [
  3300. 'server' => 5 * 60, // 5 minutes
  3301. 'client' => 5 * 60, // 5 minutes
  3302. ],
  3303. ];
  3304. /**
  3305. * The default debug mode (on/off) for of ResourceLoader requests.
  3306. *
  3307. * This will still be overridden when the debug URL parameter is used.
  3308. */
  3309. $wgResourceLoaderDebug = false;
  3310. /**
  3311. * Whether to ensure the mediawiki.legacy library is loaded before other modules.
  3312. *
  3313. * @deprecated since 1.26: Always declare dependencies.
  3314. */
  3315. $wgIncludeLegacyJavaScript = false;
  3316. /**
  3317. * Whether or not to assign configuration variables to the global window object.
  3318. *
  3319. * If this is set to false, old code using deprecated variables will no longer
  3320. * work.
  3321. *
  3322. * @par Example of legacy code:
  3323. * @code{,js}
  3324. * if ( window.wgRestrictionEdit ) { ... }
  3325. * @endcode
  3326. * or:
  3327. * @code{,js}
  3328. * if ( wgIsArticle ) { ... }
  3329. * @endcode
  3330. *
  3331. * Instead, one needs to use mw.config.
  3332. * @par Example using mw.config global configuration:
  3333. * @code{,js}
  3334. * if ( mw.config.exists('wgRestrictionEdit') ) { ... }
  3335. * @endcode
  3336. * or:
  3337. * @code{,js}
  3338. * if ( mw.config.get('wgIsArticle') ) { ... }
  3339. * @endcode
  3340. */
  3341. $wgLegacyJavaScriptGlobals = true;
  3342. /**
  3343. * If set to a positive number, ResourceLoader will not generate URLs whose
  3344. * query string is more than this many characters long, and will instead use
  3345. * multiple requests with shorter query strings. This degrades performance,
  3346. * but may be needed if your web server has a low (less than, say 1024)
  3347. * query string length limit or a low value for suhosin.get.max_value_length
  3348. * that you can't increase.
  3349. *
  3350. * If set to a negative number, ResourceLoader will assume there is no query
  3351. * string length limit.
  3352. *
  3353. * Defaults to a value based on php configuration.
  3354. */
  3355. $wgResourceLoaderMaxQueryLength = false;
  3356. /**
  3357. * If set to true, JavaScript modules loaded from wiki pages will be parsed
  3358. * prior to minification to validate it.
  3359. *
  3360. * Parse errors will result in a JS exception being thrown during module load,
  3361. * which avoids breaking other modules loaded in the same request.
  3362. */
  3363. $wgResourceLoaderValidateJS = true;
  3364. /**
  3365. * If set to true, statically-sourced (file-backed) JavaScript resources will
  3366. * be parsed for validity before being bundled up into ResourceLoader modules.
  3367. *
  3368. * This can be helpful for development by providing better error messages in
  3369. * default (non-debug) mode, but JavaScript parsing is slow and memory hungry
  3370. * and may fail on large pre-bundled frameworks.
  3371. */
  3372. $wgResourceLoaderValidateStaticJS = false;
  3373. /**
  3374. * Global LESS variables. An associative array binding variable names to
  3375. * LESS code snippets representing their values.
  3376. *
  3377. * Adding an item here is equivalent to writing `@variable: value;`
  3378. * at the beginning of all your .less files, with all the consequences.
  3379. * In particular, string values must be escaped and quoted.
  3380. *
  3381. * Changes to this configuration do NOT trigger cache invalidation.
  3382. *
  3383. * @par Example:
  3384. * @code
  3385. * $wgResourceLoaderLESSVars = [
  3386. * 'exampleFontSize' => '1em',
  3387. * 'exampleBlue' => '#36c',
  3388. * ];
  3389. * @endcode
  3390. * @since 1.22
  3391. * @deprecated since 1.30 Use ResourceLoaderModule::getLessVars() instead to
  3392. * add variables to individual modules that need them.
  3393. */
  3394. $wgResourceLoaderLESSVars = [
  3395. /**
  3396. * Minimum available screen width at which a device can be considered a tablet
  3397. * The number is currently based on the device width of a Samsung Galaxy S5 mini and is low
  3398. * enough to cover iPad (768px). Number is prone to change with new information.
  3399. * @since 1.27
  3400. * @deprecated 1.31 Use mediawiki.ui/variables instead
  3401. */
  3402. 'deviceWidthTablet' => '720px',
  3403. ];
  3404. /**
  3405. * Default import paths for LESS modules. LESS files referenced in @import
  3406. * statements will be looked up here first, and relative to the importing file
  3407. * second. To avoid collisions, it's important for the LESS files in these
  3408. * directories to have a common, predictable file name prefix.
  3409. *
  3410. * Extensions need not (and should not) register paths in
  3411. * $wgResourceLoaderLESSImportPaths. The import path includes the path of the
  3412. * currently compiling LESS file, which allows each extension to freely import
  3413. * files from its own tree.
  3414. *
  3415. * @since 1.22
  3416. */
  3417. $wgResourceLoaderLESSImportPaths = [
  3418. "$IP/resources/src/mediawiki.less/",
  3419. ];
  3420. /**
  3421. * Whether ResourceLoader should attempt to persist modules in localStorage on
  3422. * browsers that support the Web Storage API.
  3423. */
  3424. $wgResourceLoaderStorageEnabled = true;
  3425. /**
  3426. * Cache version for client-side ResourceLoader module storage. You can trigger
  3427. * invalidation of the contents of the module store by incrementing this value.
  3428. *
  3429. * @since 1.23
  3430. */
  3431. $wgResourceLoaderStorageVersion = 1;
  3432. /**
  3433. * Whether to allow site-wide CSS (MediaWiki:Common.css and friends) on
  3434. * restricted pages like Special:UserLogin or Special:Preferences where
  3435. * JavaScript is disabled for security reasons. As it is possible to
  3436. * execute JavaScript through CSS, setting this to true opens up a
  3437. * potential security hole. Some sites may "skin" their wiki by using
  3438. * site-wide CSS, causing restricted pages to look unstyled and different
  3439. * from the rest of the site.
  3440. *
  3441. * @since 1.25
  3442. */
  3443. $wgAllowSiteCSSOnRestrictedPages = false;
  3444. /** @} */ # End of ResourceLoader settings }
  3445. /*************************************************************************//**
  3446. * @name Page title and interwiki link settings
  3447. * @{
  3448. */
  3449. /**
  3450. * Name of the project namespace. If left set to false, $wgSitename will be
  3451. * used instead.
  3452. */
  3453. $wgMetaNamespace = false;
  3454. /**
  3455. * Name of the project talk namespace.
  3456. *
  3457. * Normally you can ignore this and it will be something like
  3458. * $wgMetaNamespace . "_talk". In some languages, you may want to set this
  3459. * manually for grammatical reasons.
  3460. */
  3461. $wgMetaNamespaceTalk = false;
  3462. /**
  3463. * Additional namespaces. If the namespaces defined in Language.php and
  3464. * Namespace.php are insufficient, you can create new ones here, for example,
  3465. * to import Help files in other languages. You can also override the namespace
  3466. * names of existing namespaces. Extensions should use the CanonicalNamespaces
  3467. * hook or extension.json.
  3468. *
  3469. * @warning Once you delete a namespace, the pages in that namespace will
  3470. * no longer be accessible. If you rename it, then you can access them through
  3471. * the new namespace name.
  3472. *
  3473. * Custom namespaces should start at 100 to avoid conflicting with standard
  3474. * namespaces, and should always follow the even/odd main/talk pattern.
  3475. *
  3476. * @par Example:
  3477. * @code
  3478. * $wgExtraNamespaces = [
  3479. * 100 => "Hilfe",
  3480. * 101 => "Hilfe_Diskussion",
  3481. * 102 => "Aide",
  3482. * 103 => "Discussion_Aide"
  3483. * ];
  3484. * @endcode
  3485. *
  3486. * @todo Add a note about maintenance/namespaceDupes.php
  3487. */
  3488. $wgExtraNamespaces = [];
  3489. /**
  3490. * Same as above, but for namespaces with gender distinction.
  3491. * Note: the default form for the namespace should also be set
  3492. * using $wgExtraNamespaces for the same index.
  3493. * @since 1.18
  3494. */
  3495. $wgExtraGenderNamespaces = [];
  3496. /**
  3497. * Namespace aliases.
  3498. *
  3499. * These are alternate names for the primary localised namespace names, which
  3500. * are defined by $wgExtraNamespaces and the language file. If a page is
  3501. * requested with such a prefix, the request will be redirected to the primary
  3502. * name.
  3503. *
  3504. * Set this to a map from namespace names to IDs.
  3505. *
  3506. * @par Example:
  3507. * @code
  3508. * $wgNamespaceAliases = [
  3509. * 'Wikipedian' => NS_USER,
  3510. * 'Help' => 100,
  3511. * ];
  3512. * @endcode
  3513. */
  3514. $wgNamespaceAliases = [];
  3515. /**
  3516. * Allowed title characters -- regex character class
  3517. * Don't change this unless you know what you're doing
  3518. *
  3519. * Problematic punctuation:
  3520. * - []{}|# Are needed for link syntax, never enable these
  3521. * - <> Causes problems with HTML escaping, don't use
  3522. * - % Enabled by default, minor problems with path to query rewrite rules, see below
  3523. * - + Enabled by default, but doesn't work with path to query rewrite rules,
  3524. * corrupted by apache
  3525. * - ? Enabled by default, but doesn't work with path to PATH_INFO rewrites
  3526. *
  3527. * All three of these punctuation problems can be avoided by using an alias,
  3528. * instead of a rewrite rule of either variety.
  3529. *
  3530. * The problem with % is that when using a path to query rewrite rule, URLs are
  3531. * double-unescaped: once by Apache's path conversion code, and again by PHP. So
  3532. * %253F, for example, becomes "?". Our code does not double-escape to compensate
  3533. * for this, indeed double escaping would break if the double-escaped title was
  3534. * passed in the query string rather than the path. This is a minor security issue
  3535. * because articles can be created such that they are hard to view or edit.
  3536. *
  3537. * In some rare cases you may wish to remove + for compatibility with old links.
  3538. */
  3539. $wgLegalTitleChars = " %!\"$&'()*,\\-.\\/0-9:;=?@A-Z\\\\^_`a-z~\\x80-\\xFF+";
  3540. /**
  3541. * The interwiki prefix of the current wiki, or false if it doesn't have one.
  3542. *
  3543. * @deprecated since 1.23; use $wgLocalInterwikis instead
  3544. */
  3545. $wgLocalInterwiki = false;
  3546. /**
  3547. * Array for multiple $wgLocalInterwiki values, in case there are several
  3548. * interwiki prefixes that point to the current wiki. If $wgLocalInterwiki is
  3549. * set, its value is prepended to this array, for backwards compatibility.
  3550. *
  3551. * Note, recent changes feeds use only the first entry in this array (or
  3552. * $wgLocalInterwiki, if it is set). See $wgRCFeeds
  3553. */
  3554. $wgLocalInterwikis = [];
  3555. /**
  3556. * Expiry time for cache of interwiki table
  3557. */
  3558. $wgInterwikiExpiry = 10800;
  3559. /**
  3560. * @name Interwiki caching settings.
  3561. * @{
  3562. */
  3563. /**
  3564. * Interwiki cache, either as an associative array or a path to a constant
  3565. * database (.cdb) file.
  3566. *
  3567. * This data structure database is generated by the `dumpInterwiki` maintenance
  3568. * script (which lives in the WikimediaMaintenance repository) and has key
  3569. * formats such as the following:
  3570. *
  3571. * - dbname:key - a simple key (e.g. enwiki:meta)
  3572. * - _sitename:key - site-scope key (e.g. wiktionary:meta)
  3573. * - __global:key - global-scope key (e.g. __global:meta)
  3574. * - __sites:dbname - site mapping (e.g. __sites:enwiki)
  3575. *
  3576. * Sites mapping just specifies site name, other keys provide "local url"
  3577. * data layout.
  3578. *
  3579. * @var bool|array|string
  3580. */
  3581. $wgInterwikiCache = false;
  3582. /**
  3583. * Specify number of domains to check for messages.
  3584. * - 1: Just wiki(db)-level
  3585. * - 2: wiki and global levels
  3586. * - 3: site levels
  3587. */
  3588. $wgInterwikiScopes = 3;
  3589. /**
  3590. * Fallback site, if unable to resolve from cache
  3591. */
  3592. $wgInterwikiFallbackSite = 'wiki';
  3593. /** @} */ # end of Interwiki caching settings.
  3594. /**
  3595. * @name SiteStore caching settings.
  3596. * @{
  3597. */
  3598. /**
  3599. * Specify the file location for the Sites json cache file.
  3600. */
  3601. $wgSitesCacheFile = false;
  3602. /** @} */ # end of SiteStore caching settings.
  3603. /**
  3604. * If local interwikis are set up which allow redirects,
  3605. * set this regexp to restrict URLs which will be displayed
  3606. * as 'redirected from' links.
  3607. *
  3608. * @par Example:
  3609. * It might look something like this:
  3610. * @code
  3611. * $wgRedirectSources = '!^https?://[a-z-]+\.wikipedia\.org/!';
  3612. * @endcode
  3613. *
  3614. * Leave at false to avoid displaying any incoming redirect markers.
  3615. * This does not affect intra-wiki redirects, which don't change
  3616. * the URL.
  3617. */
  3618. $wgRedirectSources = false;
  3619. /**
  3620. * Set this to false to avoid forcing the first letter of links to capitals.
  3621. *
  3622. * @warning may break links! This makes links COMPLETELY case-sensitive. Links
  3623. * appearing with a capital at the beginning of a sentence will *not* go to the
  3624. * same place as links in the middle of a sentence using a lowercase initial.
  3625. */
  3626. $wgCapitalLinks = true;
  3627. /**
  3628. * @since 1.16 - This can now be set per-namespace. Some special namespaces (such
  3629. * as Special, see MWNamespace::$alwaysCapitalizedNamespaces for the full list) must be
  3630. * true by default (and setting them has no effect), due to various things that
  3631. * require them to be so. Also, since Talk namespaces need to directly mirror their
  3632. * associated content namespaces, the values for those are ignored in favor of the
  3633. * subject namespace's setting. Setting for NS_MEDIA is taken automatically from
  3634. * NS_FILE.
  3635. *
  3636. * @par Example:
  3637. * @code
  3638. * $wgCapitalLinkOverrides[ NS_FILE ] = false;
  3639. * @endcode
  3640. */
  3641. $wgCapitalLinkOverrides = [];
  3642. /**
  3643. * Which namespaces should support subpages?
  3644. * See Language.php for a list of namespaces.
  3645. */
  3646. $wgNamespacesWithSubpages = [
  3647. NS_TALK => true,
  3648. NS_USER => true,
  3649. NS_USER_TALK => true,
  3650. NS_PROJECT => true,
  3651. NS_PROJECT_TALK => true,
  3652. NS_FILE_TALK => true,
  3653. NS_MEDIAWIKI => true,
  3654. NS_MEDIAWIKI_TALK => true,
  3655. NS_TEMPLATE => true,
  3656. NS_TEMPLATE_TALK => true,
  3657. NS_HELP => true,
  3658. NS_HELP_TALK => true,
  3659. NS_CATEGORY_TALK => true
  3660. ];
  3661. /**
  3662. * Array holding default tracking category names.
  3663. *
  3664. * Array contains the system messages for each tracking category.
  3665. * Tracking categories allow pages with certain characteristics to be tracked.
  3666. * It works by adding any such page to a category automatically.
  3667. *
  3668. * A message with the suffix '-desc' should be added as a description message
  3669. * to have extra information on Special:TrackingCategories.
  3670. *
  3671. * @deprecated since 1.25 Extensions should now register tracking categories using
  3672. * the new extension registration system.
  3673. *
  3674. * @since 1.23
  3675. */
  3676. $wgTrackingCategories = [];
  3677. /**
  3678. * Array of namespaces which can be deemed to contain valid "content", as far
  3679. * as the site statistics are concerned. Useful if additional namespaces also
  3680. * contain "content" which should be considered when generating a count of the
  3681. * number of articles in the wiki.
  3682. */
  3683. $wgContentNamespaces = [ NS_MAIN ];
  3684. /**
  3685. * Optional array of namespaces which should be blacklisted from Special:ShortPages
  3686. * Only pages inside $wgContentNamespaces but not $wgShortPagesNamespaceBlacklist will
  3687. * be shown on that page.
  3688. * @since 1.30
  3689. */
  3690. $wgShortPagesNamespaceBlacklist = [];
  3691. /**
  3692. * Array of namespaces, in addition to the talk namespaces, where signatures
  3693. * (~~~~) are likely to be used. This determines whether to display the
  3694. * Signature button on the edit toolbar, and may also be used by extensions.
  3695. * For example, "traditional" style wikis, where content and discussion are
  3696. * intermixed, could place NS_MAIN and NS_PROJECT namespaces in this array.
  3697. */
  3698. $wgExtraSignatureNamespaces = [];
  3699. /**
  3700. * Max number of redirects to follow when resolving redirects.
  3701. * 1 means only the first redirect is followed (default behavior).
  3702. * 0 or less means no redirects are followed.
  3703. */
  3704. $wgMaxRedirects = 1;
  3705. /**
  3706. * Array of invalid page redirect targets.
  3707. * Attempting to create a redirect to any of the pages in this array
  3708. * will make the redirect fail.
  3709. * Userlogout is hard-coded, so it does not need to be listed here.
  3710. * (T12569) Disallow Mypage and Mytalk as well.
  3711. *
  3712. * As of now, this only checks special pages. Redirects to pages in
  3713. * other namespaces cannot be invalidated by this variable.
  3714. */
  3715. $wgInvalidRedirectTargets = [ 'Filepath', 'Mypage', 'Mytalk', 'Redirect' ];
  3716. /** @} */ # End of title and interwiki settings }
  3717. /************************************************************************//**
  3718. * @name Parser settings
  3719. * These settings configure the transformation from wikitext to HTML.
  3720. * @{
  3721. */
  3722. /**
  3723. * Parser configuration. Associative array with the following members:
  3724. *
  3725. * class The class name
  3726. *
  3727. * preprocessorClass The preprocessor class. Two classes are currently available:
  3728. * Preprocessor_Hash, which uses plain PHP arrays for temporary
  3729. * storage, and Preprocessor_DOM, which uses the DOM module for
  3730. * temporary storage. Preprocessor_DOM generally uses less memory;
  3731. * the speed of the two is roughly the same.
  3732. *
  3733. * If this parameter is not given, it uses Preprocessor_DOM if the
  3734. * DOM module is available, otherwise it uses Preprocessor_Hash.
  3735. *
  3736. * The entire associative array will be passed through to the constructor as
  3737. * the first parameter. Note that only Setup.php can use this variable --
  3738. * the configuration will change at runtime via $wgParser member functions, so
  3739. * the contents of this variable will be out-of-date. The variable can only be
  3740. * changed during LocalSettings.php, in particular, it can't be changed during
  3741. * an extension setup function.
  3742. */
  3743. $wgParserConf = [
  3744. 'class' => Parser::class,
  3745. # 'preprocessorClass' => Preprocessor_Hash::class,
  3746. ];
  3747. /**
  3748. * Maximum indent level of toc.
  3749. */
  3750. $wgMaxTocLevel = 999;
  3751. /**
  3752. * A complexity limit on template expansion: the maximum number of nodes visited
  3753. * by PPFrame::expand()
  3754. */
  3755. $wgMaxPPNodeCount = 1000000;
  3756. /**
  3757. * A complexity limit on template expansion: the maximum number of elements
  3758. * generated by Preprocessor::preprocessToObj(). This allows you to limit the
  3759. * amount of memory used by the Preprocessor_DOM node cache: testing indicates
  3760. * that each element uses about 160 bytes of memory on a 64-bit processor, so
  3761. * this default corresponds to about 155 MB.
  3762. *
  3763. * When the limit is exceeded, an exception is thrown.
  3764. */
  3765. $wgMaxGeneratedPPNodeCount = 1000000;
  3766. /**
  3767. * Maximum recursion depth for templates within templates.
  3768. * The current parser adds two levels to the PHP call stack for each template,
  3769. * and xdebug limits the call stack to 100 by default. So this should hopefully
  3770. * stop the parser before it hits the xdebug limit.
  3771. */
  3772. $wgMaxTemplateDepth = 40;
  3773. /**
  3774. * @see $wgMaxTemplateDepth
  3775. */
  3776. $wgMaxPPExpandDepth = 40;
  3777. /**
  3778. * URL schemes that should be recognized as valid by wfParseUrl().
  3779. *
  3780. * WARNING: Do not add 'file:' to this or internal file links will be broken.
  3781. * Instead, if you want to support file links, add 'file://'. The same applies
  3782. * to any other protocols with the same name as a namespace. See task T46011 for
  3783. * more information.
  3784. *
  3785. * @see wfParseUrl
  3786. */
  3787. $wgUrlProtocols = [
  3788. 'bitcoin:', 'ftp://', 'ftps://', 'geo:', 'git://', 'gopher://', 'http://',
  3789. 'https://', 'irc://', 'ircs://', 'magnet:', 'mailto:', 'mms://', 'news:',
  3790. 'nntp://', 'redis://', 'sftp://', 'sip:', 'sips:', 'sms:', 'ssh://',
  3791. 'svn://', 'tel:', 'telnet://', 'urn:', 'worldwind://', 'xmpp:', '//'
  3792. ];
  3793. /**
  3794. * If true, removes (by substituting) templates in signatures.
  3795. */
  3796. $wgCleanSignatures = true;
  3797. /**
  3798. * Whether to allow inline image pointing to other websites
  3799. */
  3800. $wgAllowExternalImages = false;
  3801. /**
  3802. * If the above is false, you can specify an exception here. Image URLs
  3803. * that start with this string are then rendered, while all others are not.
  3804. * You can use this to set up a trusted, simple repository of images.
  3805. * You may also specify an array of strings to allow multiple sites
  3806. *
  3807. * @par Examples:
  3808. * @code
  3809. * $wgAllowExternalImagesFrom = 'http://127.0.0.1/';
  3810. * $wgAllowExternalImagesFrom = [ 'http://127.0.0.1/', 'http://example.com' ];
  3811. * @endcode
  3812. */
  3813. $wgAllowExternalImagesFrom = '';
  3814. /**
  3815. * If $wgAllowExternalImages is false, you can allow an on-wiki
  3816. * whitelist of regular expression fragments to match the image URL
  3817. * against. If the image matches one of the regular expression fragments,
  3818. * The image will be displayed.
  3819. *
  3820. * Set this to true to enable the on-wiki whitelist (MediaWiki:External image whitelist)
  3821. * Or false to disable it
  3822. */
  3823. $wgEnableImageWhitelist = true;
  3824. /**
  3825. * A different approach to the above: simply allow the "<img>" tag to be used.
  3826. * This allows you to specify alt text and other attributes, copy-paste HTML to
  3827. * your wiki more easily, etc. However, allowing external images in any manner
  3828. * will allow anyone with editing rights to snoop on your visitors' IP
  3829. * addresses and so forth, if they wanted to, by inserting links to images on
  3830. * sites they control.
  3831. */
  3832. $wgAllowImageTag = false;
  3833. /**
  3834. * Configuration for HTML postprocessing tool. Set this to a configuration
  3835. * array to enable an external tool. By default, we now use the RemexHtml
  3836. * library; historically, Dave Raggett's "HTML Tidy" was typically used.
  3837. * See https://www.w3.org/People/Raggett/tidy/
  3838. *
  3839. * If this is null and $wgUseTidy is true, the deprecated configuration
  3840. * parameters will be used instead.
  3841. *
  3842. * If this is null and $wgUseTidy is false, a pure PHP fallback will be used.
  3843. *
  3844. * Keys are:
  3845. * - driver: May be:
  3846. * - RaggettInternalHHVM: Use the limited-functionality HHVM extension
  3847. * - RaggettInternalPHP: Use the PECL extension
  3848. * - RaggettExternal: Shell out to an external binary (tidyBin)
  3849. * - Html5Depurate: Use external Depurate service
  3850. * - Html5Internal: Use the Balancer library in PHP
  3851. * - RemexHtml: Use the RemexHtml library in PHP
  3852. *
  3853. * - tidyConfigFile: Path to configuration file for any of the Raggett drivers
  3854. * - debugComment: True to add a comment to the output with warning messages
  3855. * - tidyBin: For RaggettExternal, the path to the tidy binary.
  3856. * - tidyCommandLine: For RaggettExternal, additional command line options.
  3857. */
  3858. $wgTidyConfig = [ 'driver' => 'RemexHtml' ];
  3859. /**
  3860. * Set this to true to use the deprecated tidy configuration parameters.
  3861. * @deprecated use $wgTidyConfig
  3862. */
  3863. $wgUseTidy = false;
  3864. /**
  3865. * The path to the tidy binary.
  3866. * @deprecated Use $wgTidyConfig['tidyBin']
  3867. */
  3868. $wgTidyBin = 'tidy';
  3869. /**
  3870. * The path to the tidy config file
  3871. * @deprecated Use $wgTidyConfig['tidyConfigFile']
  3872. */
  3873. $wgTidyConf = $IP . '/includes/tidy/tidy.conf';
  3874. /**
  3875. * The command line options to the tidy binary
  3876. * @deprecated Use $wgTidyConfig['tidyCommandLine']
  3877. */
  3878. $wgTidyOpts = '';
  3879. /**
  3880. * Set this to true to use the tidy extension
  3881. * @deprecated Use $wgTidyConfig['driver']
  3882. */
  3883. $wgTidyInternal = extension_loaded( 'tidy' );
  3884. /**
  3885. * Put tidy warnings in HTML comments
  3886. * Only works for internal tidy.
  3887. */
  3888. $wgDebugTidy = false;
  3889. /**
  3890. * Allow raw, unchecked HTML in "<html>...</html>" sections.
  3891. * THIS IS VERY DANGEROUS on a publicly editable site, so USE wgGroupPermissions
  3892. * TO RESTRICT EDITING to only those that you trust
  3893. */
  3894. $wgRawHtml = false;
  3895. /**
  3896. * Set a default target for external links, e.g. _blank to pop up a new window.
  3897. *
  3898. * This will also set the "noreferrer" and "noopener" link rel to prevent the
  3899. * attack described at https://mathiasbynens.github.io/rel-noopener/ .
  3900. * Some older browsers may not support these link attributes, hence
  3901. * setting $wgExternalLinkTarget to _blank may represent a security risk
  3902. * to some of your users.
  3903. */
  3904. $wgExternalLinkTarget = false;
  3905. /**
  3906. * If true, external URL links in wiki text will be given the
  3907. * rel="nofollow" attribute as a hint to search engines that
  3908. * they should not be followed for ranking purposes as they
  3909. * are user-supplied and thus subject to spamming.
  3910. */
  3911. $wgNoFollowLinks = true;
  3912. /**
  3913. * Namespaces in which $wgNoFollowLinks doesn't apply.
  3914. * See Language.php for a list of namespaces.
  3915. */
  3916. $wgNoFollowNsExceptions = [];
  3917. /**
  3918. * If this is set to an array of domains, external links to these domain names
  3919. * (or any subdomains) will not be set to rel="nofollow" regardless of the
  3920. * value of $wgNoFollowLinks. For instance:
  3921. *
  3922. * $wgNoFollowDomainExceptions = [ 'en.wikipedia.org', 'wiktionary.org', 'mediawiki.org' ];
  3923. *
  3924. * This would add rel="nofollow" to links to de.wikipedia.org, but not
  3925. * en.wikipedia.org, wiktionary.org, en.wiktionary.org, us.en.wikipedia.org,
  3926. * etc.
  3927. *
  3928. * Defaults to mediawiki.org for the links included in the software by default.
  3929. */
  3930. $wgNoFollowDomainExceptions = [ 'mediawiki.org' ];
  3931. /**
  3932. * Allow DISPLAYTITLE to change title display
  3933. */
  3934. $wgAllowDisplayTitle = true;
  3935. /**
  3936. * For consistency, restrict DISPLAYTITLE to text that normalizes to the same
  3937. * canonical DB key. Also disallow some inline CSS rules like display: none;
  3938. * which can cause the text to be hidden or unselectable.
  3939. */
  3940. $wgRestrictDisplayTitle = true;
  3941. /**
  3942. * Maximum number of calls per parse to expensive parser functions such as
  3943. * PAGESINCATEGORY.
  3944. */
  3945. $wgExpensiveParserFunctionLimit = 100;
  3946. /**
  3947. * Preprocessor caching threshold
  3948. * Setting it to 'false' will disable the preprocessor cache.
  3949. */
  3950. $wgPreprocessorCacheThreshold = 1000;
  3951. /**
  3952. * Enable interwiki transcluding. Only when iw_trans=1 in the interwiki table.
  3953. */
  3954. $wgEnableScaryTranscluding = false;
  3955. /**
  3956. * Expiry time for transcluded templates cached in transcache database table.
  3957. * Only used $wgEnableInterwikiTranscluding is set to true.
  3958. */
  3959. $wgTranscludeCacheExpiry = 3600;
  3960. /**
  3961. * Enable the magic links feature of automatically turning ISBN xxx,
  3962. * PMID xxx, RFC xxx into links
  3963. *
  3964. * @since 1.28
  3965. */
  3966. $wgEnableMagicLinks = [
  3967. 'ISBN' => false,
  3968. 'PMID' => false,
  3969. 'RFC' => false
  3970. ];
  3971. /** @} */ # end of parser settings }
  3972. /************************************************************************//**
  3973. * @name Statistics
  3974. * @{
  3975. */
  3976. /**
  3977. * Method used to determine if a page in a content namespace should be counted
  3978. * as a valid article.
  3979. *
  3980. * Redirect pages will never be counted as valid articles.
  3981. *
  3982. * This variable can have the following values:
  3983. * - 'any': all pages as considered as valid articles
  3984. * - 'link': the page must contain a [[wiki link]] to be considered valid
  3985. *
  3986. * See also See https://www.mediawiki.org/wiki/Manual:Article_count
  3987. *
  3988. * Retroactively changing this variable will not affect the existing count,
  3989. * to update it, you will need to run the maintenance/updateArticleCount.php
  3990. * script.
  3991. */
  3992. $wgArticleCountMethod = 'link';
  3993. /**
  3994. * How many days user must be idle before he is considered inactive. Will affect
  3995. * the number shown on Special:Statistics, Special:ActiveUsers, and the
  3996. * {{NUMBEROFACTIVEUSERS}} magic word in wikitext.
  3997. * You might want to leave this as the default value, to provide comparable
  3998. * numbers between different wikis.
  3999. */
  4000. $wgActiveUserDays = 30;
  4001. /** @} */ # End of statistics }
  4002. /************************************************************************//**
  4003. * @name User accounts, authentication
  4004. * @{
  4005. */
  4006. /**
  4007. * Central ID lookup providers
  4008. * Key is the provider ID, value is a specification for ObjectFactory
  4009. * @since 1.27
  4010. */
  4011. $wgCentralIdLookupProviders = [
  4012. 'local' => [ 'class' => LocalIdLookup::class ],
  4013. ];
  4014. /**
  4015. * Central ID lookup provider to use by default
  4016. * @var string
  4017. */
  4018. $wgCentralIdLookupProvider = 'local';
  4019. /**
  4020. * Password policy for local wiki users. A user's effective policy
  4021. * is the superset of all policy statements from the policies for the
  4022. * groups where the user is a member. If more than one group policy
  4023. * include the same policy statement, the value is the max() of the
  4024. * values. Note true > false. The 'default' policy group is required,
  4025. * and serves as the minimum policy for all users. New statements can
  4026. * be added by appending to $wgPasswordPolicy['checks'].
  4027. * Statements:
  4028. * - MinimalPasswordLength - minimum length a user can set
  4029. * - MinimumPasswordLengthToLogin - passwords shorter than this will
  4030. * not be allowed to login, regardless if it is correct.
  4031. * - MaximalPasswordLength - maximum length password a user is allowed
  4032. * to attempt. Prevents DoS attacks with pbkdf2.
  4033. * - PasswordCannotMatchUsername - Password cannot match username to
  4034. * - PasswordCannotMatchBlacklist - Username/password combination cannot
  4035. * match a specific, hardcoded blacklist.
  4036. * - PasswordCannotBePopular - Blacklist passwords which are known to be
  4037. * commonly chosen. Set to integer n to ban the top n passwords.
  4038. * If you want to ban all common passwords on file, use the
  4039. * PHP_INT_MAX constant.
  4040. * @since 1.26
  4041. */
  4042. $wgPasswordPolicy = [
  4043. 'policies' => [
  4044. 'bureaucrat' => [
  4045. 'MinimalPasswordLength' => 8,
  4046. 'MinimumPasswordLengthToLogin' => 1,
  4047. 'PasswordCannotMatchUsername' => true,
  4048. 'PasswordCannotBePopular' => 25,
  4049. ],
  4050. 'sysop' => [
  4051. 'MinimalPasswordLength' => 8,
  4052. 'MinimumPasswordLengthToLogin' => 1,
  4053. 'PasswordCannotMatchUsername' => true,
  4054. 'PasswordCannotBePopular' => 25,
  4055. ],
  4056. 'bot' => [
  4057. 'MinimalPasswordLength' => 8,
  4058. 'MinimumPasswordLengthToLogin' => 1,
  4059. 'PasswordCannotMatchUsername' => true,
  4060. ],
  4061. 'default' => [
  4062. 'MinimalPasswordLength' => 1,
  4063. 'PasswordCannotMatchUsername' => true,
  4064. 'PasswordCannotMatchBlacklist' => true,
  4065. 'MaximalPasswordLength' => 4096,
  4066. ],
  4067. ],
  4068. 'checks' => [
  4069. 'MinimalPasswordLength' => 'PasswordPolicyChecks::checkMinimalPasswordLength',
  4070. 'MinimumPasswordLengthToLogin' => 'PasswordPolicyChecks::checkMinimumPasswordLengthToLogin',
  4071. 'PasswordCannotMatchUsername' => 'PasswordPolicyChecks::checkPasswordCannotMatchUsername',
  4072. 'PasswordCannotMatchBlacklist' => 'PasswordPolicyChecks::checkPasswordCannotMatchBlacklist',
  4073. 'MaximalPasswordLength' => 'PasswordPolicyChecks::checkMaximalPasswordLength',
  4074. 'PasswordCannotBePopular' => 'PasswordPolicyChecks::checkPopularPasswordBlacklist'
  4075. ],
  4076. ];
  4077. /**
  4078. * Configure AuthManager
  4079. *
  4080. * All providers are constructed using ObjectFactory, see that for the general
  4081. * structure. The array may also contain a key "sort" used to order providers:
  4082. * providers are stably sorted by this value, which should be an integer
  4083. * (default is 0).
  4084. *
  4085. * Elements are:
  4086. * - preauth: Array (keys ignored) of specifications for PreAuthenticationProviders
  4087. * - primaryauth: Array (keys ignored) of specifications for PrimaryAuthenticationProviders
  4088. * - secondaryauth: Array (keys ignored) of specifications for SecondaryAuthenticationProviders
  4089. *
  4090. * @since 1.27
  4091. * @note If this is null or empty, the value from $wgAuthManagerAutoConfig is
  4092. * used instead. Local customization should generally set this variable from
  4093. * scratch to the desired configuration. Extensions that want to
  4094. * auto-configure themselves should use $wgAuthManagerAutoConfig instead.
  4095. */
  4096. $wgAuthManagerConfig = null;
  4097. /**
  4098. * @see $wgAuthManagerConfig
  4099. * @since 1.27
  4100. */
  4101. $wgAuthManagerAutoConfig = [
  4102. 'preauth' => [
  4103. MediaWiki\Auth\LegacyHookPreAuthenticationProvider::class => [
  4104. 'class' => MediaWiki\Auth\LegacyHookPreAuthenticationProvider::class,
  4105. 'sort' => 0,
  4106. ],
  4107. MediaWiki\Auth\ThrottlePreAuthenticationProvider::class => [
  4108. 'class' => MediaWiki\Auth\ThrottlePreAuthenticationProvider::class,
  4109. 'sort' => 0,
  4110. ],
  4111. ],
  4112. 'primaryauth' => [
  4113. // TemporaryPasswordPrimaryAuthenticationProvider should come before
  4114. // any other PasswordAuthenticationRequest-based
  4115. // PrimaryAuthenticationProvider (or at least any that might return
  4116. // FAIL rather than ABSTAIN for a wrong password), or password reset
  4117. // won't work right. Do not remove this (or change the key) or
  4118. // auto-configuration of other such providers in extensions will
  4119. // probably auto-insert themselves in the wrong place.
  4120. MediaWiki\Auth\TemporaryPasswordPrimaryAuthenticationProvider::class => [
  4121. 'class' => MediaWiki\Auth\TemporaryPasswordPrimaryAuthenticationProvider::class,
  4122. 'args' => [ [
  4123. // Fall through to LocalPasswordPrimaryAuthenticationProvider
  4124. 'authoritative' => false,
  4125. ] ],
  4126. 'sort' => 0,
  4127. ],
  4128. MediaWiki\Auth\LocalPasswordPrimaryAuthenticationProvider::class => [
  4129. 'class' => MediaWiki\Auth\LocalPasswordPrimaryAuthenticationProvider::class,
  4130. 'args' => [ [
  4131. // Last one should be authoritative, or else the user will get
  4132. // a less-than-helpful error message (something like "supplied
  4133. // authentication info not supported" rather than "wrong
  4134. // password") if it too fails.
  4135. 'authoritative' => true,
  4136. ] ],
  4137. 'sort' => 100,
  4138. ],
  4139. ],
  4140. 'secondaryauth' => [
  4141. MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::class => [
  4142. 'class' => MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::class,
  4143. 'sort' => 0,
  4144. ],
  4145. MediaWiki\Auth\ResetPasswordSecondaryAuthenticationProvider::class => [
  4146. 'class' => MediaWiki\Auth\ResetPasswordSecondaryAuthenticationProvider::class,
  4147. 'sort' => 100,
  4148. ],
  4149. // Linking during login is experimental, enable at your own risk - T134952
  4150. // MediaWiki\Auth\ConfirmLinkSecondaryAuthenticationProvider::class => [
  4151. // 'class' => MediaWiki\Auth\ConfirmLinkSecondaryAuthenticationProvider::class,
  4152. // 'sort' => 100,
  4153. // ],
  4154. MediaWiki\Auth\EmailNotificationSecondaryAuthenticationProvider::class => [
  4155. 'class' => MediaWiki\Auth\EmailNotificationSecondaryAuthenticationProvider::class,
  4156. 'sort' => 200,
  4157. ],
  4158. ],
  4159. ];
  4160. /**
  4161. * Time frame for re-authentication.
  4162. *
  4163. * With only password-based authentication, you'd just ask the user to re-enter
  4164. * their password to verify certain operations like changing the password or
  4165. * changing the account's email address. But under AuthManager, the user might
  4166. * not have a password (you might even have to redirect the browser to a
  4167. * third-party service or something complex like that), you might want to have
  4168. * both factors of a two-factor authentication, and so on. So, the options are:
  4169. * - Incorporate the whole multi-step authentication flow within everything
  4170. * that needs to do this.
  4171. * - Consider it good if they used Special:UserLogin during this session within
  4172. * the last X seconds.
  4173. * - Come up with a third option.
  4174. *
  4175. * MediaWiki currently takes the second option. This setting configures the
  4176. * "X seconds".
  4177. *
  4178. * This allows for configuring different time frames for different
  4179. * "operations". The operations used in MediaWiki core include:
  4180. * - LinkAccounts
  4181. * - UnlinkAccount
  4182. * - ChangeCredentials
  4183. * - RemoveCredentials
  4184. * - ChangeEmail
  4185. *
  4186. * Additional operations may be used by extensions, either explicitly by
  4187. * calling AuthManager::securitySensitiveOperationStatus(),
  4188. * ApiAuthManagerHelper::securitySensitiveOperation() or
  4189. * SpecialPage::checkLoginSecurityLevel(), or implicitly by overriding
  4190. * SpecialPage::getLoginSecurityLevel() or by subclassing
  4191. * AuthManagerSpecialPage.
  4192. *
  4193. * The key 'default' is used if a requested operation isn't defined in the array.
  4194. *
  4195. * @since 1.27
  4196. * @var int[] operation => time in seconds. A 'default' key must always be provided.
  4197. */
  4198. $wgReauthenticateTime = [
  4199. 'default' => 300,
  4200. ];
  4201. /**
  4202. * Whether to allow security-sensitive operations when re-authentication is not possible.
  4203. *
  4204. * If AuthManager::canAuthenticateNow() is false (e.g. the current
  4205. * SessionProvider is not able to change users, such as when OAuth is in use),
  4206. * AuthManager::securitySensitiveOperationStatus() cannot sensibly return
  4207. * SEC_REAUTH. Setting an operation true here will have it return SEC_OK in
  4208. * that case, while setting it false will have it return SEC_FAIL.
  4209. *
  4210. * The key 'default' is used if a requested operation isn't defined in the array.
  4211. *
  4212. * @since 1.27
  4213. * @see $wgReauthenticateTime
  4214. * @var bool[] operation => boolean. A 'default' key must always be provided.
  4215. */
  4216. $wgAllowSecuritySensitiveOperationIfCannotReauthenticate = [
  4217. 'default' => true,
  4218. ];
  4219. /**
  4220. * List of AuthenticationRequest class names which are not changeable through
  4221. * Special:ChangeCredentials and the changeauthenticationdata API.
  4222. * This is only enforced on the client level; AuthManager itself (e.g.
  4223. * AuthManager::allowsAuthenticationDataChange calls) is not affected.
  4224. * Class names are checked for exact match (not for subclasses).
  4225. * @since 1.27
  4226. * @var string[]
  4227. */
  4228. $wgChangeCredentialsBlacklist = [
  4229. \MediaWiki\Auth\TemporaryPasswordAuthenticationRequest::class
  4230. ];
  4231. /**
  4232. * List of AuthenticationRequest class names which are not removable through
  4233. * Special:RemoveCredentials and the removeauthenticationdata API.
  4234. * This is only enforced on the client level; AuthManager itself (e.g.
  4235. * AuthManager::allowsAuthenticationDataChange calls) is not affected.
  4236. * Class names are checked for exact match (not for subclasses).
  4237. * @since 1.27
  4238. * @var string[]
  4239. */
  4240. $wgRemoveCredentialsBlacklist = [
  4241. \MediaWiki\Auth\PasswordAuthenticationRequest::class,
  4242. ];
  4243. /**
  4244. * For compatibility with old installations set to false
  4245. * @deprecated since 1.24 will be removed in future
  4246. */
  4247. $wgPasswordSalt = true;
  4248. /**
  4249. * Specifies the minimal length of a user password. If set to 0, empty pass-
  4250. * words are allowed.
  4251. * @deprecated since 1.26, use $wgPasswordPolicy's MinimalPasswordLength.
  4252. */
  4253. $wgMinimalPasswordLength = false;
  4254. /**
  4255. * Specifies the maximal length of a user password (T64685).
  4256. *
  4257. * It is not recommended to make this greater than the default, as it can
  4258. * allow DoS attacks by users setting really long passwords. In addition,
  4259. * this should not be lowered too much, as it enforces weak passwords.
  4260. *
  4261. * @warning Unlike other password settings, user with passwords greater than
  4262. * the maximum will not be able to log in.
  4263. * @deprecated since 1.26, use $wgPasswordPolicy's MaximalPasswordLength.
  4264. */
  4265. $wgMaximalPasswordLength = false;
  4266. /**
  4267. * Specifies if users should be sent to a password-reset form on login, if their
  4268. * password doesn't meet the requirements of User::isValidPassword().
  4269. * @since 1.23
  4270. */
  4271. $wgInvalidPasswordReset = true;
  4272. /**
  4273. * Default password type to use when hashing user passwords
  4274. *
  4275. * @since 1.24
  4276. */
  4277. $wgPasswordDefault = 'pbkdf2';
  4278. /**
  4279. * Configuration for built-in password types. Maps the password type
  4280. * to an array of options. The 'class' option is the Password class to
  4281. * use. All other options are class-dependent.
  4282. *
  4283. * An advanced example:
  4284. * @code
  4285. * $wgPasswordConfig['bcrypt-peppered'] = [
  4286. * 'class' => EncryptedPassword::class,
  4287. * 'underlying' => 'bcrypt',
  4288. * 'secrets' => [],
  4289. * 'cipher' => MCRYPT_RIJNDAEL_256,
  4290. * 'mode' => MCRYPT_MODE_CBC,
  4291. * 'cost' => 5,
  4292. * ];
  4293. * @endcode
  4294. *
  4295. * @since 1.24
  4296. */
  4297. $wgPasswordConfig = [
  4298. 'A' => [
  4299. 'class' => MWOldPassword::class,
  4300. ],
  4301. 'B' => [
  4302. 'class' => MWSaltedPassword::class,
  4303. ],
  4304. 'pbkdf2-legacyA' => [
  4305. 'class' => LayeredParameterizedPassword::class,
  4306. 'types' => [
  4307. 'A',
  4308. 'pbkdf2',
  4309. ],
  4310. ],
  4311. 'pbkdf2-legacyB' => [
  4312. 'class' => LayeredParameterizedPassword::class,
  4313. 'types' => [
  4314. 'B',
  4315. 'pbkdf2',
  4316. ],
  4317. ],
  4318. 'bcrypt' => [
  4319. 'class' => BcryptPassword::class,
  4320. 'cost' => 9,
  4321. ],
  4322. 'pbkdf2' => [
  4323. 'class' => Pbkdf2Password::class,
  4324. 'algo' => 'sha512',
  4325. 'cost' => '30000',
  4326. 'length' => '64',
  4327. ],
  4328. ];
  4329. /**
  4330. * Whether to allow password resets ("enter some identifying data, and we'll send an email
  4331. * with a temporary password you can use to get back into the account") identified by
  4332. * various bits of data. Setting all of these to false (or the whole variable to false)
  4333. * has the effect of disabling password resets entirely
  4334. */
  4335. $wgPasswordResetRoutes = [
  4336. 'username' => true,
  4337. 'email' => true,
  4338. ];
  4339. /**
  4340. * Maximum number of Unicode characters in signature
  4341. */
  4342. $wgMaxSigChars = 255;
  4343. /**
  4344. * Maximum number of bytes in username. You want to run the maintenance
  4345. * script ./maintenance/checkUsernames.php once you have changed this value.
  4346. */
  4347. $wgMaxNameChars = 255;
  4348. /**
  4349. * Array of usernames which may not be registered or logged in from
  4350. * Maintenance scripts can still use these
  4351. */
  4352. $wgReservedUsernames = [
  4353. 'MediaWiki default', // Default 'Main Page' and MediaWiki: message pages
  4354. 'Conversion script', // Used for the old Wikipedia software upgrade
  4355. 'Maintenance script', // Maintenance scripts which perform editing, image import script
  4356. 'Template namespace initialisation script', // Used in 1.2->1.3 upgrade
  4357. 'ScriptImporter', // Default user name used by maintenance/importSiteScripts.php
  4358. 'Unknown user', // Used in WikiImporter when importing revisions with no author
  4359. 'msg:double-redirect-fixer', // Automatic double redirect fix
  4360. 'msg:usermessage-editor', // Default user for leaving user messages
  4361. 'msg:proxyblocker', // For $wgProxyList and Special:Blockme (removed in 1.22)
  4362. 'msg:sorbs', // For $wgEnableDnsBlacklist etc.
  4363. 'msg:spambot_username', // Used by cleanupSpam.php
  4364. 'msg:autochange-username', // Used by anon category RC entries (parser functions, Lua & purges)
  4365. ];
  4366. /**
  4367. * Settings added to this array will override the default globals for the user
  4368. * preferences used by anonymous visitors and newly created accounts.
  4369. * For instance, to disable editing on double clicks:
  4370. * $wgDefaultUserOptions ['editondblclick'] = 0;
  4371. */
  4372. $wgDefaultUserOptions = [
  4373. 'ccmeonemails' => 0,
  4374. 'cols' => 80, // @deprecated since 1.29 No longer used in core
  4375. 'date' => 'default',
  4376. 'diffonly' => 0,
  4377. 'disablemail' => 0,
  4378. 'editfont' => 'monospace',
  4379. 'editondblclick' => 0,
  4380. 'editsectiononrightclick' => 0,
  4381. 'email-allow-new-users' => 1,
  4382. 'enotifminoredits' => 0,
  4383. 'enotifrevealaddr' => 0,
  4384. 'enotifusertalkpages' => 1,
  4385. 'enotifwatchlistpages' => 1,
  4386. 'extendwatchlist' => 1,
  4387. 'fancysig' => 0,
  4388. 'forceeditsummary' => 0,
  4389. 'gender' => 'unknown',
  4390. 'hideminor' => 0,
  4391. 'hidepatrolled' => 0,
  4392. 'hidecategorization' => 1,
  4393. 'imagesize' => 2,
  4394. 'minordefault' => 0,
  4395. 'newpageshidepatrolled' => 0,
  4396. 'nickname' => '',
  4397. 'norollbackdiff' => 0,
  4398. 'numberheadings' => 0,
  4399. 'previewonfirst' => 0,
  4400. 'previewontop' => 1,
  4401. 'rcdays' => 7,
  4402. 'rcenhancedfilters' => 0,
  4403. 'rcenhancedfilters-disable' => 0,
  4404. 'rclimit' => 50,
  4405. 'rows' => 25, // @deprecated since 1.29 No longer used in core
  4406. 'showhiddencats' => 0,
  4407. 'shownumberswatching' => 1,
  4408. 'showtoolbar' => 1,
  4409. 'skin' => false,
  4410. 'stubthreshold' => 0,
  4411. 'thumbsize' => 5,
  4412. 'underline' => 2,
  4413. 'uselivepreview' => 0,
  4414. 'usenewrc' => 1,
  4415. 'watchcreations' => 1,
  4416. 'watchdefault' => 1,
  4417. 'watchdeletion' => 0,
  4418. 'watchuploads' => 1,
  4419. 'watchlistdays' => 3.0,
  4420. 'watchlisthideanons' => 0,
  4421. 'watchlisthidebots' => 0,
  4422. 'watchlisthideliu' => 0,
  4423. 'watchlisthideminor' => 0,
  4424. 'watchlisthideown' => 0,
  4425. 'watchlisthidepatrolled' => 0,
  4426. 'watchlisthidecategorization' => 1,
  4427. 'watchlistreloadautomatically' => 0,
  4428. 'watchlistunwatchlinks' => 0,
  4429. 'watchmoves' => 0,
  4430. 'watchrollback' => 0,
  4431. 'wllimit' => 250,
  4432. 'useeditwarning' => 1,
  4433. 'prefershttps' => 1,
  4434. ];
  4435. /**
  4436. * An array of preferences to not show for the user
  4437. */
  4438. $wgHiddenPrefs = [];
  4439. /**
  4440. * Characters to prevent during new account creations.
  4441. * This is used in a regular expression character class during
  4442. * registration (regex metacharacters like / are escaped).
  4443. */
  4444. $wgInvalidUsernameCharacters = '@:';
  4445. /**
  4446. * Character used as a delimiter when testing for interwiki userrights
  4447. * (In Special:UserRights, it is possible to modify users on different
  4448. * databases if the delimiter is used, e.g. "Someuser@enwiki").
  4449. *
  4450. * It is recommended that you have this delimiter in
  4451. * $wgInvalidUsernameCharacters above, or you will not be able to
  4452. * modify the user rights of those users via Special:UserRights
  4453. */
  4454. $wgUserrightsInterwikiDelimiter = '@';
  4455. /**
  4456. * This is to let user authenticate using https when they come from http.
  4457. * Based on an idea by George Herbert on wikitech-l:
  4458. * https://lists.wikimedia.org/pipermail/wikitech-l/2010-October/050039.html
  4459. * @since 1.17
  4460. */
  4461. $wgSecureLogin = false;
  4462. /**
  4463. * Versioning for authentication tokens.
  4464. *
  4465. * If non-null, this is combined with the user's secret (the user_token field
  4466. * in the DB) to generate the token cookie. Changing this will invalidate all
  4467. * active sessions (i.e. it will log everyone out).
  4468. *
  4469. * @since 1.27
  4470. * @var string|null
  4471. */
  4472. $wgAuthenticationTokenVersion = null;
  4473. /**
  4474. * MediaWiki\Session\SessionProvider configuration.
  4475. *
  4476. * Value is an array of ObjectFactory specifications for the SessionProviders
  4477. * to be used. Keys in the array are ignored. Order is not significant.
  4478. *
  4479. * @since 1.27
  4480. */
  4481. $wgSessionProviders = [
  4482. MediaWiki\Session\CookieSessionProvider::class => [
  4483. 'class' => MediaWiki\Session\CookieSessionProvider::class,
  4484. 'args' => [ [
  4485. 'priority' => 30,
  4486. 'callUserSetCookiesHook' => true,
  4487. ] ],
  4488. ],
  4489. MediaWiki\Session\BotPasswordSessionProvider::class => [
  4490. 'class' => MediaWiki\Session\BotPasswordSessionProvider::class,
  4491. 'args' => [ [
  4492. 'priority' => 75,
  4493. ] ],
  4494. ],
  4495. ];
  4496. /** @} */ # end user accounts }
  4497. /************************************************************************//**
  4498. * @name User rights, access control and monitoring
  4499. * @{
  4500. */
  4501. /**
  4502. * Number of seconds before autoblock entries expire. Default 86400 = 1 day.
  4503. */
  4504. $wgAutoblockExpiry = 86400;
  4505. /**
  4506. * Set this to true to allow blocked users to edit their own user talk page.
  4507. */
  4508. $wgBlockAllowsUTEdit = true;
  4509. /**
  4510. * Allow sysops to ban users from accessing Emailuser
  4511. */
  4512. $wgSysopEmailBans = true;
  4513. /**
  4514. * Limits on the possible sizes of range blocks.
  4515. *
  4516. * CIDR notation is hard to understand, it's easy to mistakenly assume that a
  4517. * /1 is a small range and a /31 is a large range. For IPv4, setting a limit of
  4518. * half the number of bits avoids such errors, and allows entire ISPs to be
  4519. * blocked using a small number of range blocks.
  4520. *
  4521. * For IPv6, RFC 3177 recommends that a /48 be allocated to every residential
  4522. * customer, so range blocks larger than /64 (half the number of bits) will
  4523. * plainly be required. RFC 4692 implies that a very large ISP may be
  4524. * allocated a /19 if a generous HD-Ratio of 0.8 is used, so we will use that
  4525. * as our limit. As of 2012, blocking the whole world would require a /4 range.
  4526. */
  4527. $wgBlockCIDRLimit = [
  4528. 'IPv4' => 16, # Blocks larger than a /16 (64k addresses) will not be allowed
  4529. 'IPv6' => 19,
  4530. ];
  4531. /**
  4532. * If true, blocked users will not be allowed to login. When using this with
  4533. * a public wiki, the effect of logging out blocked users may actually be
  4534. * avers: unless the user's address is also blocked (e.g. auto-block),
  4535. * logging the user out will again allow reading and editing, just as for
  4536. * anonymous visitors.
  4537. */
  4538. $wgBlockDisablesLogin = false;
  4539. /**
  4540. * Pages anonymous user may see, set as an array of pages titles.
  4541. *
  4542. * @par Example:
  4543. * @code
  4544. * $wgWhitelistRead = array ( "Main Page", "Wikipedia:Help");
  4545. * @endcode
  4546. *
  4547. * Special:Userlogin and Special:ChangePassword are always whitelisted.
  4548. *
  4549. * @note This will only work if $wgGroupPermissions['*']['read'] is false --
  4550. * see below. Otherwise, ALL pages are accessible, regardless of this setting.
  4551. *
  4552. * @note Also that this will only protect _pages in the wiki_. Uploaded files
  4553. * will remain readable. You can use img_auth.php to protect uploaded files,
  4554. * see https://www.mediawiki.org/wiki/Manual:Image_Authorization
  4555. *
  4556. * @note Extensions should not modify this, but use the TitleReadWhitelist
  4557. * hook instead.
  4558. */
  4559. $wgWhitelistRead = false;
  4560. /**
  4561. * Pages anonymous user may see, set as an array of regular expressions.
  4562. *
  4563. * This function will match the regexp against the title name, which
  4564. * is without underscore.
  4565. *
  4566. * @par Example:
  4567. * To whitelist [[Main Page]]:
  4568. * @code
  4569. * $wgWhitelistReadRegexp = [ "/Main Page/" ];
  4570. * @endcode
  4571. *
  4572. * @note Unless ^ and/or $ is specified, a regular expression might match
  4573. * pages not intended to be whitelisted. The above example will also
  4574. * whitelist a page named 'Security Main Page'.
  4575. *
  4576. * @par Example:
  4577. * To allow reading any page starting with 'User' regardless of the case:
  4578. * @code
  4579. * $wgWhitelistReadRegexp = [ "@^UsEr.*@i" ];
  4580. * @endcode
  4581. * Will allow both [[User is banned]] and [[User:JohnDoe]]
  4582. *
  4583. * @note This will only work if $wgGroupPermissions['*']['read'] is false --
  4584. * see below. Otherwise, ALL pages are accessible, regardless of this setting.
  4585. */
  4586. $wgWhitelistReadRegexp = false;
  4587. /**
  4588. * Should editors be required to have a validated e-mail
  4589. * address before being allowed to edit?
  4590. */
  4591. $wgEmailConfirmToEdit = false;
  4592. /**
  4593. * Should MediaWiki attempt to protect user's privacy when doing redirects?
  4594. * Keep this true if access counts to articles are made public.
  4595. */
  4596. $wgHideIdentifiableRedirects = true;
  4597. /**
  4598. * Permission keys given to users in each group.
  4599. *
  4600. * This is an array where the keys are all groups and each value is an
  4601. * array of the format (right => boolean).
  4602. *
  4603. * The second format is used to support per-namespace permissions.
  4604. * Note that this feature does not fully work for all permission types.
  4605. *
  4606. * All users are implicitly in the '*' group including anonymous visitors;
  4607. * logged-in users are all implicitly in the 'user' group. These will be
  4608. * combined with the permissions of all groups that a given user is listed
  4609. * in in the user_groups table.
  4610. *
  4611. * Note: Don't set $wgGroupPermissions = []; unless you know what you're
  4612. * doing! This will wipe all permissions, and may mean that your users are
  4613. * unable to perform certain essential tasks or access new functionality
  4614. * when new permissions are introduced and default grants established.
  4615. *
  4616. * Functionality to make pages inaccessible has not been extensively tested
  4617. * for security. Use at your own risk!
  4618. *
  4619. * This replaces $wgWhitelistAccount and $wgWhitelistEdit
  4620. */
  4621. $wgGroupPermissions = [];
  4622. /** @cond file_level_code */
  4623. // Implicit group for all visitors
  4624. $wgGroupPermissions['*']['createaccount'] = true;
  4625. $wgGroupPermissions['*']['read'] = true;
  4626. $wgGroupPermissions['*']['edit'] = true;
  4627. $wgGroupPermissions['*']['createpage'] = true;
  4628. $wgGroupPermissions['*']['createtalk'] = true;
  4629. $wgGroupPermissions['*']['writeapi'] = true;
  4630. $wgGroupPermissions['*']['viewmywatchlist'] = true;
  4631. $wgGroupPermissions['*']['editmywatchlist'] = true;
  4632. $wgGroupPermissions['*']['viewmyprivateinfo'] = true;
  4633. $wgGroupPermissions['*']['editmyprivateinfo'] = true;
  4634. $wgGroupPermissions['*']['editmyoptions'] = true;
  4635. # $wgGroupPermissions['*']['patrolmarks'] = false; // let anons see what was patrolled
  4636. // Implicit group for all logged-in accounts
  4637. $wgGroupPermissions['user']['move'] = true;
  4638. $wgGroupPermissions['user']['move-subpages'] = true;
  4639. $wgGroupPermissions['user']['move-rootuserpages'] = true; // can move root userpages
  4640. $wgGroupPermissions['user']['move-categorypages'] = true;
  4641. $wgGroupPermissions['user']['movefile'] = true;
  4642. $wgGroupPermissions['user']['read'] = true;
  4643. $wgGroupPermissions['user']['edit'] = true;
  4644. $wgGroupPermissions['user']['createpage'] = true;
  4645. $wgGroupPermissions['user']['createtalk'] = true;
  4646. $wgGroupPermissions['user']['writeapi'] = true;
  4647. $wgGroupPermissions['user']['upload'] = true;
  4648. $wgGroupPermissions['user']['reupload'] = true;
  4649. $wgGroupPermissions['user']['reupload-shared'] = true;
  4650. $wgGroupPermissions['user']['minoredit'] = true;
  4651. $wgGroupPermissions['user']['editmyusercss'] = true;
  4652. $wgGroupPermissions['user']['editmyuserjson'] = true;
  4653. $wgGroupPermissions['user']['editmyuserjs'] = true;
  4654. $wgGroupPermissions['user']['purge'] = true;
  4655. $wgGroupPermissions['user']['sendemail'] = true;
  4656. $wgGroupPermissions['user']['applychangetags'] = true;
  4657. $wgGroupPermissions['user']['changetags'] = true;
  4658. $wgGroupPermissions['user']['editcontentmodel'] = true;
  4659. // Implicit group for accounts that pass $wgAutoConfirmAge
  4660. $wgGroupPermissions['autoconfirmed']['autoconfirmed'] = true;
  4661. $wgGroupPermissions['autoconfirmed']['editsemiprotected'] = true;
  4662. // Users with bot privilege can have their edits hidden
  4663. // from various log pages by default
  4664. $wgGroupPermissions['bot']['bot'] = true;
  4665. $wgGroupPermissions['bot']['autoconfirmed'] = true;
  4666. $wgGroupPermissions['bot']['editsemiprotected'] = true;
  4667. $wgGroupPermissions['bot']['nominornewtalk'] = true;
  4668. $wgGroupPermissions['bot']['autopatrol'] = true;
  4669. $wgGroupPermissions['bot']['suppressredirect'] = true;
  4670. $wgGroupPermissions['bot']['apihighlimits'] = true;
  4671. $wgGroupPermissions['bot']['writeapi'] = true;
  4672. // Most extra permission abilities go to this group
  4673. $wgGroupPermissions['sysop']['block'] = true;
  4674. $wgGroupPermissions['sysop']['createaccount'] = true;
  4675. $wgGroupPermissions['sysop']['delete'] = true;
  4676. // can be separately configured for pages with > $wgDeleteRevisionsLimit revs
  4677. $wgGroupPermissions['sysop']['bigdelete'] = true;
  4678. // can view deleted history entries, but not see or restore the text
  4679. $wgGroupPermissions['sysop']['deletedhistory'] = true;
  4680. // can view deleted revision text
  4681. $wgGroupPermissions['sysop']['deletedtext'] = true;
  4682. $wgGroupPermissions['sysop']['undelete'] = true;
  4683. $wgGroupPermissions['sysop']['editinterface'] = true;
  4684. $wgGroupPermissions['sysop']['editusercss'] = true;
  4685. $wgGroupPermissions['sysop']['edituserjson'] = true;
  4686. $wgGroupPermissions['sysop']['edituserjs'] = true;
  4687. $wgGroupPermissions['sysop']['import'] = true;
  4688. $wgGroupPermissions['sysop']['importupload'] = true;
  4689. $wgGroupPermissions['sysop']['move'] = true;
  4690. $wgGroupPermissions['sysop']['move-subpages'] = true;
  4691. $wgGroupPermissions['sysop']['move-rootuserpages'] = true;
  4692. $wgGroupPermissions['sysop']['move-categorypages'] = true;
  4693. $wgGroupPermissions['sysop']['patrol'] = true;
  4694. $wgGroupPermissions['sysop']['autopatrol'] = true;
  4695. $wgGroupPermissions['sysop']['protect'] = true;
  4696. $wgGroupPermissions['sysop']['editprotected'] = true;
  4697. $wgGroupPermissions['sysop']['rollback'] = true;
  4698. $wgGroupPermissions['sysop']['upload'] = true;
  4699. $wgGroupPermissions['sysop']['reupload'] = true;
  4700. $wgGroupPermissions['sysop']['reupload-shared'] = true;
  4701. $wgGroupPermissions['sysop']['unwatchedpages'] = true;
  4702. $wgGroupPermissions['sysop']['autoconfirmed'] = true;
  4703. $wgGroupPermissions['sysop']['editsemiprotected'] = true;
  4704. $wgGroupPermissions['sysop']['ipblock-exempt'] = true;
  4705. $wgGroupPermissions['sysop']['blockemail'] = true;
  4706. $wgGroupPermissions['sysop']['markbotedits'] = true;
  4707. $wgGroupPermissions['sysop']['apihighlimits'] = true;
  4708. $wgGroupPermissions['sysop']['browsearchive'] = true;
  4709. $wgGroupPermissions['sysop']['noratelimit'] = true;
  4710. $wgGroupPermissions['sysop']['movefile'] = true;
  4711. $wgGroupPermissions['sysop']['unblockself'] = true;
  4712. $wgGroupPermissions['sysop']['suppressredirect'] = true;
  4713. # $wgGroupPermissions['sysop']['pagelang'] = true;
  4714. # $wgGroupPermissions['sysop']['upload_by_url'] = true;
  4715. $wgGroupPermissions['sysop']['mergehistory'] = true;
  4716. $wgGroupPermissions['sysop']['managechangetags'] = true;
  4717. $wgGroupPermissions['sysop']['deletechangetags'] = true;
  4718. // Permission to change users' group assignments
  4719. $wgGroupPermissions['bureaucrat']['userrights'] = true;
  4720. $wgGroupPermissions['bureaucrat']['noratelimit'] = true;
  4721. // Permission to change users' groups assignments across wikis
  4722. # $wgGroupPermissions['bureaucrat']['userrights-interwiki'] = true;
  4723. // Permission to export pages including linked pages regardless of $wgExportMaxLinkDepth
  4724. # $wgGroupPermissions['bureaucrat']['override-export-depth'] = true;
  4725. # $wgGroupPermissions['sysop']['deletelogentry'] = true;
  4726. # $wgGroupPermissions['sysop']['deleterevision'] = true;
  4727. // To hide usernames from users and Sysops
  4728. # $wgGroupPermissions['suppress']['hideuser'] = true;
  4729. // To hide revisions/log items from users and Sysops
  4730. # $wgGroupPermissions['suppress']['suppressrevision'] = true;
  4731. // To view revisions/log items hidden from users and Sysops
  4732. # $wgGroupPermissions['suppress']['viewsuppressed'] = true;
  4733. // For private suppression log access
  4734. # $wgGroupPermissions['suppress']['suppressionlog'] = true;
  4735. /**
  4736. * The developer group is deprecated, but can be activated if need be
  4737. * to use the 'lockdb' and 'unlockdb' special pages. Those require
  4738. * that a lock file be defined and creatable/removable by the web
  4739. * server.
  4740. */
  4741. # $wgGroupPermissions['developer']['siteadmin'] = true;
  4742. /** @endcond */
  4743. /**
  4744. * Permission keys revoked from users in each group.
  4745. *
  4746. * This acts the same way as wgGroupPermissions above, except that
  4747. * if the user is in a group here, the permission will be removed from them.
  4748. *
  4749. * Improperly setting this could mean that your users will be unable to perform
  4750. * certain essential tasks, so use at your own risk!
  4751. */
  4752. $wgRevokePermissions = [];
  4753. /**
  4754. * Implicit groups, aren't shown on Special:Listusers or somewhere else
  4755. */
  4756. $wgImplicitGroups = [ '*', 'user', 'autoconfirmed' ];
  4757. /**
  4758. * A map of group names that the user is in, to group names that those users
  4759. * are allowed to add or revoke.
  4760. *
  4761. * Setting the list of groups to add or revoke to true is equivalent to "any
  4762. * group".
  4763. *
  4764. * @par Example:
  4765. * To allow sysops to add themselves to the "bot" group:
  4766. * @code
  4767. * $wgGroupsAddToSelf = [ 'sysop' => [ 'bot' ] ];
  4768. * @endcode
  4769. *
  4770. * @par Example:
  4771. * Implicit groups may be used for the source group, for instance:
  4772. * @code
  4773. * $wgGroupsRemoveFromSelf = [ '*' => true ];
  4774. * @endcode
  4775. * This allows users in the '*' group (i.e. any user) to remove themselves from
  4776. * any group that they happen to be in.
  4777. */
  4778. $wgGroupsAddToSelf = [];
  4779. /**
  4780. * @see $wgGroupsAddToSelf
  4781. */
  4782. $wgGroupsRemoveFromSelf = [];
  4783. /**
  4784. * Set of available actions that can be restricted via action=protect
  4785. * You probably shouldn't change this.
  4786. * Translated through restriction-* messages.
  4787. * Title::getRestrictionTypes() will remove restrictions that are not
  4788. * applicable to a specific title (create and upload)
  4789. */
  4790. $wgRestrictionTypes = [ 'create', 'edit', 'move', 'upload' ];
  4791. /**
  4792. * Rights which can be required for each protection level (via action=protect)
  4793. *
  4794. * You can add a new protection level that requires a specific
  4795. * permission by manipulating this array. The ordering of elements
  4796. * dictates the order on the protection form's lists.
  4797. *
  4798. * - '' will be ignored (i.e. unprotected)
  4799. * - 'autoconfirmed' is quietly rewritten to 'editsemiprotected' for backwards compatibility
  4800. * - 'sysop' is quietly rewritten to 'editprotected' for backwards compatibility
  4801. */
  4802. $wgRestrictionLevels = [ '', 'autoconfirmed', 'sysop' ];
  4803. /**
  4804. * Restriction levels that can be used with cascading protection
  4805. *
  4806. * A page can only be protected with cascading protection if the
  4807. * requested restriction level is included in this array.
  4808. *
  4809. * 'autoconfirmed' is quietly rewritten to 'editsemiprotected' for backwards compatibility.
  4810. * 'sysop' is quietly rewritten to 'editprotected' for backwards compatibility.
  4811. */
  4812. $wgCascadingRestrictionLevels = [ 'sysop' ];
  4813. /**
  4814. * Restriction levels that should be considered "semiprotected"
  4815. *
  4816. * Certain places in the interface recognize a dichotomy between "protected"
  4817. * and "semiprotected", without further distinguishing the specific levels. In
  4818. * general, if anyone can be eligible to edit a protection level merely by
  4819. * reaching some condition in $wgAutopromote, it should probably be considered
  4820. * "semiprotected".
  4821. *
  4822. * 'autoconfirmed' is quietly rewritten to 'editsemiprotected' for backwards compatibility.
  4823. * 'sysop' is not changed, since it really shouldn't be here.
  4824. */
  4825. $wgSemiprotectedRestrictionLevels = [ 'autoconfirmed' ];
  4826. /**
  4827. * Set the minimum permissions required to edit pages in each
  4828. * namespace. If you list more than one permission, a user must
  4829. * have all of them to edit pages in that namespace.
  4830. *
  4831. * @note NS_MEDIAWIKI is implicitly restricted to 'editinterface'.
  4832. */
  4833. $wgNamespaceProtection = [];
  4834. /**
  4835. * Pages in namespaces in this array can not be used as templates.
  4836. *
  4837. * Elements MUST be numeric namespace ids, you can safely use the MediaWiki
  4838. * namespaces constants (NS_USER, NS_MAIN...).
  4839. *
  4840. * Among other things, this may be useful to enforce read-restrictions
  4841. * which may otherwise be bypassed by using the template mechanism.
  4842. */
  4843. $wgNonincludableNamespaces = [];
  4844. /**
  4845. * Number of seconds an account is required to age before it's given the
  4846. * implicit 'autoconfirm' group membership. This can be used to limit
  4847. * privileges of new accounts.
  4848. *
  4849. * Accounts created by earlier versions of the software may not have a
  4850. * recorded creation date, and will always be considered to pass the age test.
  4851. *
  4852. * When left at 0, all registered accounts will pass.
  4853. *
  4854. * @par Example:
  4855. * Set automatic confirmation to 10 minutes (which is 600 seconds):
  4856. * @code
  4857. * $wgAutoConfirmAge = 600; // ten minutes
  4858. * @endcode
  4859. * Set age to one day:
  4860. * @code
  4861. * $wgAutoConfirmAge = 3600*24; // one day
  4862. * @endcode
  4863. */
  4864. $wgAutoConfirmAge = 0;
  4865. /**
  4866. * Number of edits an account requires before it is autoconfirmed.
  4867. * Passing both this AND the time requirement is needed. Example:
  4868. *
  4869. * @par Example:
  4870. * @code
  4871. * $wgAutoConfirmCount = 50;
  4872. * @endcode
  4873. */
  4874. $wgAutoConfirmCount = 0;
  4875. /**
  4876. * Array containing the conditions of automatic promotion of a user to specific groups.
  4877. *
  4878. * The basic syntax for `$wgAutopromote` is:
  4879. *
  4880. * $wgAutopromote = array(
  4881. * 'groupname' => cond,
  4882. * 'group2' => cond2,
  4883. * );
  4884. *
  4885. * A `cond` may be:
  4886. * - a single condition without arguments:
  4887. * Note that Autopromote wraps a single non-array value into an array
  4888. * e.g. `APCOND_EMAILCONFIRMED` OR
  4889. * array( `APCOND_EMAILCONFIRMED` )
  4890. * - a single condition with arguments:
  4891. * e.g. `array( APCOND_EDITCOUNT, 100 )`
  4892. * - a set of conditions:
  4893. * e.g. `array( 'operand', cond1, cond2, ... )`
  4894. *
  4895. * When constructing a set of conditions, the following conditions are available:
  4896. * - `&` (**AND**):
  4897. * promote if user matches **ALL** conditions
  4898. * - `|` (**OR**):
  4899. * promote if user matches **ANY** condition
  4900. * - `^` (**XOR**):
  4901. * promote if user matches **ONLY ONE OF THE CONDITIONS**
  4902. * - `!` (**NOT**):
  4903. * promote if user matces **NO** condition
  4904. * - array( APCOND_EMAILCONFIRMED ):
  4905. * true if user has a confirmed e-mail
  4906. * - array( APCOND_EDITCOUNT, number of edits ):
  4907. * true if user has the at least the number of edits as the passed parameter
  4908. * - array( APCOND_AGE, seconds since registration ):
  4909. * true if the length of time since the user created his/her account
  4910. * is at least the same length of time as the passed parameter
  4911. * - array( APCOND_AGE_FROM_EDIT, seconds since first edit ):
  4912. * true if the length of time since the user made his/her first edit
  4913. * is at least the same length of time as the passed parameter
  4914. * - array( APCOND_INGROUPS, group1, group2, ... ):
  4915. * true if the user is a member of each of the passed groups
  4916. * - array( APCOND_ISIP, ip ):
  4917. * true if the user has the passed IP address
  4918. * - array( APCOND_IPINRANGE, range ):
  4919. * true if the user has an IP address in the range of the passed parameter
  4920. * - array( APCOND_BLOCKED ):
  4921. * true if the user is blocked
  4922. * - array( APCOND_ISBOT ):
  4923. * true if the user is a bot
  4924. * - similar constructs can be defined by extensions
  4925. *
  4926. * The sets of conditions are evaluated recursively, so you can use nested sets of conditions
  4927. * linked by operands.
  4928. *
  4929. * Note that if $wgEmailAuthentication is disabled, APCOND_EMAILCONFIRMED will be true for any
  4930. * user who has provided an e-mail address.
  4931. */
  4932. $wgAutopromote = [
  4933. 'autoconfirmed' => [ '&',
  4934. [ APCOND_EDITCOUNT, &$wgAutoConfirmCount ],
  4935. [ APCOND_AGE, &$wgAutoConfirmAge ],
  4936. ],
  4937. ];
  4938. /**
  4939. * Automatically add a usergroup to any user who matches certain conditions.
  4940. *
  4941. * Does not add the user to the group again if it has been removed.
  4942. * Also, does not remove the group if the user no longer meets the criteria.
  4943. *
  4944. * The format is:
  4945. * @code
  4946. * [ event => criteria, ... ]
  4947. * @endcode
  4948. * Where event is either:
  4949. * - 'onEdit' (when user edits)
  4950. *
  4951. * Criteria has the same format as $wgAutopromote
  4952. *
  4953. * @see $wgAutopromote
  4954. * @since 1.18
  4955. */
  4956. $wgAutopromoteOnce = [
  4957. 'onEdit' => [],
  4958. ];
  4959. /**
  4960. * Put user rights log entries for autopromotion in recent changes?
  4961. * @since 1.18
  4962. */
  4963. $wgAutopromoteOnceLogInRC = true;
  4964. /**
  4965. * $wgAddGroups and $wgRemoveGroups can be used to give finer control over who
  4966. * can assign which groups at Special:Userrights.
  4967. *
  4968. * @par Example:
  4969. * Bureaucrats can add any group:
  4970. * @code
  4971. * $wgAddGroups['bureaucrat'] = true;
  4972. * @endcode
  4973. * Bureaucrats can only remove bots and sysops:
  4974. * @code
  4975. * $wgRemoveGroups['bureaucrat'] = [ 'bot', 'sysop' ];
  4976. * @endcode
  4977. * Sysops can make bots:
  4978. * @code
  4979. * $wgAddGroups['sysop'] = [ 'bot' ];
  4980. * @endcode
  4981. * Sysops can disable other sysops in an emergency, and disable bots:
  4982. * @code
  4983. * $wgRemoveGroups['sysop'] = [ 'sysop', 'bot' ];
  4984. * @endcode
  4985. */
  4986. $wgAddGroups = [];
  4987. /**
  4988. * @see $wgAddGroups
  4989. */
  4990. $wgRemoveGroups = [];
  4991. /**
  4992. * A list of available rights, in addition to the ones defined by the core.
  4993. * For extensions only.
  4994. */
  4995. $wgAvailableRights = [];
  4996. /**
  4997. * Optional to restrict deletion of pages with higher revision counts
  4998. * to users with the 'bigdelete' permission. (Default given to sysops.)
  4999. */
  5000. $wgDeleteRevisionsLimit = 0;
  5001. /**
  5002. * The maximum number of edits a user can have and
  5003. * can still be hidden by users with the hideuser permission.
  5004. * This is limited for performance reason.
  5005. * Set to false to disable the limit.
  5006. * @since 1.23
  5007. */
  5008. $wgHideUserContribLimit = 1000;
  5009. /**
  5010. * Number of accounts each IP address may create per specified period(s).
  5011. *
  5012. * @par Example:
  5013. * @code
  5014. * $wgAccountCreationThrottle = [
  5015. * // no more than 100 per month
  5016. * [
  5017. * 'count' => 100,
  5018. * 'seconds' => 30*86400,
  5019. * ],
  5020. * // no more than 10 per day
  5021. * [
  5022. * 'count' => 10,
  5023. * 'seconds' => 86400,
  5024. * ],
  5025. * ];
  5026. * @endcode
  5027. *
  5028. * @warning Requires $wgMainCacheType to be enabled
  5029. */
  5030. $wgAccountCreationThrottle = [ [
  5031. 'count' => 0,
  5032. 'seconds' => 86400,
  5033. ] ];
  5034. /**
  5035. * Edits matching these regular expressions in body text
  5036. * will be recognised as spam and rejected automatically.
  5037. *
  5038. * There's no administrator override on-wiki, so be careful what you set. :)
  5039. * May be an array of regexes or a single string for backwards compatibility.
  5040. *
  5041. * @see https://en.wikipedia.org/wiki/Regular_expression
  5042. *
  5043. * @note Each regex needs a beginning/end delimiter, eg: # or /
  5044. */
  5045. $wgSpamRegex = [];
  5046. /**
  5047. * Same as the above except for edit summaries
  5048. */
  5049. $wgSummarySpamRegex = [];
  5050. /**
  5051. * Whether to use DNS blacklists in $wgDnsBlacklistUrls to check for open
  5052. * proxies
  5053. * @since 1.16
  5054. */
  5055. $wgEnableDnsBlacklist = false;
  5056. /**
  5057. * List of DNS blacklists to use, if $wgEnableDnsBlacklist is true.
  5058. *
  5059. * This is an array of either a URL or an array with the URL and a key (should
  5060. * the blacklist require a key).
  5061. *
  5062. * @par Example:
  5063. * @code
  5064. * $wgDnsBlacklistUrls = [
  5065. * // String containing URL
  5066. * 'http.dnsbl.sorbs.net.',
  5067. * // Array with URL and key, for services that require a key
  5068. * [ 'dnsbl.httpbl.net.', 'mykey' ],
  5069. * // Array with just the URL. While this works, it is recommended that you
  5070. * // just use a string as shown above
  5071. * [ 'opm.tornevall.org.' ]
  5072. * ];
  5073. * @endcode
  5074. *
  5075. * @note You should end the domain name with a . to avoid searching your
  5076. * eventual domain search suffixes.
  5077. * @since 1.16
  5078. */
  5079. $wgDnsBlacklistUrls = [ 'http.dnsbl.sorbs.net.' ];
  5080. /**
  5081. * Proxy whitelist, list of addresses that are assumed to be non-proxy despite
  5082. * what the other methods might say.
  5083. */
  5084. $wgProxyWhitelist = [];
  5085. /**
  5086. * IP ranges that should be considered soft-blocked (anon-only, account
  5087. * creation allowed). The intent is to use this to prevent anonymous edits from
  5088. * shared resources such as Wikimedia Labs.
  5089. * @since 1.29
  5090. * @var string[]
  5091. */
  5092. $wgSoftBlockRanges = [];
  5093. /**
  5094. * Whether to look at the X-Forwarded-For header's list of (potentially spoofed)
  5095. * IPs and apply IP blocks to them. This allows for IP blocks to work with correctly-configured
  5096. * (transparent) proxies without needing to block the proxies themselves.
  5097. */
  5098. $wgApplyIpBlocksToXff = false;
  5099. /**
  5100. * Simple rate limiter options to brake edit floods.
  5101. *
  5102. * Maximum number actions allowed in the given number of seconds; after that
  5103. * the violating client receives HTTP 500 error pages until the period
  5104. * elapses.
  5105. *
  5106. * @par Example:
  5107. * Limits per configured per action and then type of users.
  5108. * @code
  5109. * $wgRateLimits = [
  5110. * 'edit' => [
  5111. * 'anon' => [ x, y ], // any and all anonymous edits (aggregate)
  5112. * 'user' => [ x, y ], // each logged-in user
  5113. * 'newbie' => [ x, y ], // each new autoconfirmed accounts; overrides 'user'
  5114. * 'ip' => [ x, y ], // each anon and recent account
  5115. * 'subnet' => [ x, y ], // ... within a /24 subnet in IPv4 or /64 in IPv6
  5116. * 'groupName' => [ x, y ], // by group membership
  5117. * ]
  5118. * ];
  5119. * @endcode
  5120. *
  5121. * @par Normally, the 'noratelimit' right allows a user to bypass any rate
  5122. * limit checks. This can be disabled on a per-action basis by setting the
  5123. * special '&can-bypass' key to false in that action's configuration.
  5124. * @code
  5125. * $wgRateLimits = [
  5126. * 'some-action' => [
  5127. * '&can-bypass' => false,
  5128. * 'user' => [ x, y ],
  5129. * ];
  5130. * @endcode
  5131. *
  5132. * @warning Requires that $wgMainCacheType is set to something persistent
  5133. */
  5134. $wgRateLimits = [
  5135. // Page edits
  5136. 'edit' => [
  5137. 'ip' => [ 8, 60 ],
  5138. 'newbie' => [ 8, 60 ],
  5139. 'user' => [ 90, 60 ],
  5140. ],
  5141. // Page moves
  5142. 'move' => [
  5143. 'newbie' => [ 2, 120 ],
  5144. 'user' => [ 8, 60 ],
  5145. ],
  5146. // File uploads
  5147. 'upload' => [
  5148. 'ip' => [ 8, 60 ],
  5149. 'newbie' => [ 8, 60 ],
  5150. ],
  5151. // Page rollbacks
  5152. 'rollback' => [
  5153. 'user' => [ 10, 60 ],
  5154. 'newbie' => [ 5, 120 ]
  5155. ],
  5156. // Triggering password resets emails
  5157. 'mailpassword' => [
  5158. 'ip' => [ 5, 3600 ],
  5159. ],
  5160. // Emailing other users using MediaWiki
  5161. 'emailuser' => [
  5162. 'ip' => [ 5, 86400 ],
  5163. 'newbie' => [ 5, 86400 ],
  5164. 'user' => [ 20, 86400 ],
  5165. ],
  5166. // Purging pages
  5167. 'purge' => [
  5168. 'ip' => [ 30, 60 ],
  5169. 'user' => [ 30, 60 ],
  5170. ],
  5171. // Purges of link tables
  5172. 'linkpurge' => [
  5173. 'ip' => [ 30, 60 ],
  5174. 'user' => [ 30, 60 ],
  5175. ],
  5176. // Files rendered via thumb.php or thumb_handler.php
  5177. 'renderfile' => [
  5178. 'ip' => [ 700, 30 ],
  5179. 'user' => [ 700, 30 ],
  5180. ],
  5181. // Same as above but for non-standard thumbnails
  5182. 'renderfile-nonstandard' => [
  5183. 'ip' => [ 70, 30 ],
  5184. 'user' => [ 70, 30 ],
  5185. ],
  5186. // Stashing edits into cache before save
  5187. 'stashedit' => [
  5188. 'ip' => [ 30, 60 ],
  5189. 'newbie' => [ 30, 60 ],
  5190. ],
  5191. // Adding or removing change tags
  5192. 'changetag' => [
  5193. 'ip' => [ 8, 60 ],
  5194. 'newbie' => [ 8, 60 ],
  5195. ],
  5196. // Changing the content model of a page
  5197. 'editcontentmodel' => [
  5198. 'newbie' => [ 2, 120 ],
  5199. 'user' => [ 8, 60 ],
  5200. ],
  5201. ];
  5202. /**
  5203. * Array of IPs / CIDR ranges which should be excluded from rate limits.
  5204. * This may be useful for whitelisting NAT gateways for conferences, etc.
  5205. */
  5206. $wgRateLimitsExcludedIPs = [];
  5207. /**
  5208. * Log IP addresses in the recentchanges table; can be accessed only by
  5209. * extensions (e.g. CheckUser) or a DB admin
  5210. * Used for retroactive autoblocks
  5211. */
  5212. $wgPutIPinRC = true;
  5213. /**
  5214. * Integer defining default number of entries to show on
  5215. * special pages which are query-pages such as Special:Whatlinkshere.
  5216. */
  5217. $wgQueryPageDefaultLimit = 50;
  5218. /**
  5219. * Limit password attempts to X attempts per Y seconds per IP per account.
  5220. *
  5221. * Value is an array of arrays. Each sub-array must have a key for count
  5222. * (ie count of how many attempts before throttle) and a key for seconds.
  5223. * If the key 'allIPs' (case sensitive) is present, then the limit is
  5224. * just per account instead of per IP per account.
  5225. *
  5226. * @since 1.27 allIps support and multiple limits added in 1.27. Prior
  5227. * to 1.27 this only supported having a single throttle.
  5228. * @warning Requires $wgMainCacheType to be enabled
  5229. */
  5230. $wgPasswordAttemptThrottle = [
  5231. // Short term limit
  5232. [ 'count' => 5, 'seconds' => 300 ],
  5233. // Long term limit. We need to balance the risk
  5234. // of somebody using this as a DoS attack to lock someone
  5235. // out of their account, and someone doing a brute force attack.
  5236. [ 'count' => 150, 'seconds' => 60 * 60 * 48 ],
  5237. ];
  5238. /**
  5239. * @var array Map of (grant => right => boolean)
  5240. * Users authorize consumers (like Apps) to act on their behalf but only with
  5241. * a subset of the user's normal account rights (signed off on by the user).
  5242. * The possible rights to grant to a consumer are bundled into groups called
  5243. * "grants". Each grant defines some rights it lets consumers inherit from the
  5244. * account they may act on behalf of. Note that a user granting a right does
  5245. * nothing if that user does not actually have that right to begin with.
  5246. * @since 1.27
  5247. */
  5248. $wgGrantPermissions = [];
  5249. // @TODO: clean up grants
  5250. // @TODO: auto-include read/editsemiprotected rights?
  5251. $wgGrantPermissions['basic']['autoconfirmed'] = true;
  5252. $wgGrantPermissions['basic']['autopatrol'] = true;
  5253. $wgGrantPermissions['basic']['editsemiprotected'] = true;
  5254. $wgGrantPermissions['basic']['ipblock-exempt'] = true;
  5255. $wgGrantPermissions['basic']['nominornewtalk'] = true;
  5256. $wgGrantPermissions['basic']['patrolmarks'] = true;
  5257. $wgGrantPermissions['basic']['purge'] = true;
  5258. $wgGrantPermissions['basic']['read'] = true;
  5259. $wgGrantPermissions['basic']['skipcaptcha'] = true;
  5260. $wgGrantPermissions['basic']['writeapi'] = true;
  5261. $wgGrantPermissions['highvolume']['bot'] = true;
  5262. $wgGrantPermissions['highvolume']['apihighlimits'] = true;
  5263. $wgGrantPermissions['highvolume']['noratelimit'] = true;
  5264. $wgGrantPermissions['highvolume']['markbotedits'] = true;
  5265. $wgGrantPermissions['editpage']['edit'] = true;
  5266. $wgGrantPermissions['editpage']['minoredit'] = true;
  5267. $wgGrantPermissions['editpage']['applychangetags'] = true;
  5268. $wgGrantPermissions['editpage']['changetags'] = true;
  5269. $wgGrantPermissions['editprotected'] = $wgGrantPermissions['editpage'];
  5270. $wgGrantPermissions['editprotected']['editprotected'] = true;
  5271. // FIXME: Rename editmycssjs to editmyconfig
  5272. $wgGrantPermissions['editmycssjs'] = $wgGrantPermissions['editpage'];
  5273. $wgGrantPermissions['editmycssjs']['editmyusercss'] = true;
  5274. $wgGrantPermissions['editmycssjs']['editmyuserjson'] = true;
  5275. $wgGrantPermissions['editmycssjs']['editmyuserjs'] = true;
  5276. $wgGrantPermissions['editmyoptions']['editmyoptions'] = true;
  5277. $wgGrantPermissions['editinterface'] = $wgGrantPermissions['editpage'];
  5278. $wgGrantPermissions['editinterface']['editinterface'] = true;
  5279. $wgGrantPermissions['editinterface']['editusercss'] = true;
  5280. $wgGrantPermissions['editinterface']['edituserjson'] = true;
  5281. $wgGrantPermissions['editinterface']['edituserjs'] = true;
  5282. $wgGrantPermissions['createeditmovepage'] = $wgGrantPermissions['editpage'];
  5283. $wgGrantPermissions['createeditmovepage']['createpage'] = true;
  5284. $wgGrantPermissions['createeditmovepage']['createtalk'] = true;
  5285. $wgGrantPermissions['createeditmovepage']['move'] = true;
  5286. $wgGrantPermissions['createeditmovepage']['move-rootuserpages'] = true;
  5287. $wgGrantPermissions['createeditmovepage']['move-subpages'] = true;
  5288. $wgGrantPermissions['createeditmovepage']['move-categorypages'] = true;
  5289. $wgGrantPermissions['uploadfile']['upload'] = true;
  5290. $wgGrantPermissions['uploadfile']['reupload-own'] = true;
  5291. $wgGrantPermissions['uploadeditmovefile'] = $wgGrantPermissions['uploadfile'];
  5292. $wgGrantPermissions['uploadeditmovefile']['reupload'] = true;
  5293. $wgGrantPermissions['uploadeditmovefile']['reupload-shared'] = true;
  5294. $wgGrantPermissions['uploadeditmovefile']['upload_by_url'] = true;
  5295. $wgGrantPermissions['uploadeditmovefile']['movefile'] = true;
  5296. $wgGrantPermissions['uploadeditmovefile']['suppressredirect'] = true;
  5297. $wgGrantPermissions['patrol']['patrol'] = true;
  5298. $wgGrantPermissions['rollback']['rollback'] = true;
  5299. $wgGrantPermissions['blockusers']['block'] = true;
  5300. $wgGrantPermissions['blockusers']['blockemail'] = true;
  5301. $wgGrantPermissions['viewdeleted']['browsearchive'] = true;
  5302. $wgGrantPermissions['viewdeleted']['deletedhistory'] = true;
  5303. $wgGrantPermissions['viewdeleted']['deletedtext'] = true;
  5304. $wgGrantPermissions['viewrestrictedlogs']['suppressionlog'] = true;
  5305. $wgGrantPermissions['delete'] = $wgGrantPermissions['editpage'] +
  5306. $wgGrantPermissions['viewdeleted'];
  5307. $wgGrantPermissions['delete']['delete'] = true;
  5308. $wgGrantPermissions['delete']['bigdelete'] = true;
  5309. $wgGrantPermissions['delete']['deletelogentry'] = true;
  5310. $wgGrantPermissions['delete']['deleterevision'] = true;
  5311. $wgGrantPermissions['delete']['undelete'] = true;
  5312. $wgGrantPermissions['protect'] = $wgGrantPermissions['editprotected'];
  5313. $wgGrantPermissions['protect']['protect'] = true;
  5314. $wgGrantPermissions['viewmywatchlist']['viewmywatchlist'] = true;
  5315. $wgGrantPermissions['editmywatchlist']['editmywatchlist'] = true;
  5316. $wgGrantPermissions['sendemail']['sendemail'] = true;
  5317. $wgGrantPermissions['createaccount']['createaccount'] = true;
  5318. $wgGrantPermissions['privateinfo']['viewmyprivateinfo'] = true;
  5319. /**
  5320. * @var array Map of grants to their UI grouping
  5321. * @since 1.27
  5322. */
  5323. $wgGrantPermissionGroups = [
  5324. // Hidden grants are implicitly present
  5325. 'basic' => 'hidden',
  5326. 'editpage' => 'page-interaction',
  5327. 'createeditmovepage' => 'page-interaction',
  5328. 'editprotected' => 'page-interaction',
  5329. 'patrol' => 'page-interaction',
  5330. 'uploadfile' => 'file-interaction',
  5331. 'uploadeditmovefile' => 'file-interaction',
  5332. 'sendemail' => 'email',
  5333. 'viewmywatchlist' => 'watchlist-interaction',
  5334. 'editviewmywatchlist' => 'watchlist-interaction',
  5335. 'editmycssjs' => 'customization',
  5336. 'editmyoptions' => 'customization',
  5337. 'editinterface' => 'administration',
  5338. 'rollback' => 'administration',
  5339. 'blockusers' => 'administration',
  5340. 'delete' => 'administration',
  5341. 'viewdeleted' => 'administration',
  5342. 'viewrestrictedlogs' => 'administration',
  5343. 'protect' => 'administration',
  5344. 'createaccount' => 'administration',
  5345. 'highvolume' => 'high-volume',
  5346. 'privateinfo' => 'private-information',
  5347. ];
  5348. /**
  5349. * @var bool Whether to enable bot passwords
  5350. * @since 1.27
  5351. */
  5352. $wgEnableBotPasswords = true;
  5353. /**
  5354. * Cluster for the bot_passwords table
  5355. * @var string|bool If false, the normal cluster will be used
  5356. * @since 1.27
  5357. */
  5358. $wgBotPasswordsCluster = false;
  5359. /**
  5360. * Database name for the bot_passwords table
  5361. *
  5362. * To use a database with a table prefix, set this variable to
  5363. * "{$database}-{$prefix}".
  5364. * @var string|bool If false, the normal database will be used
  5365. * @since 1.27
  5366. */
  5367. $wgBotPasswordsDatabase = false;
  5368. /** @} */ # end of user rights settings
  5369. /************************************************************************//**
  5370. * @name Proxy scanner settings
  5371. * @{
  5372. */
  5373. /**
  5374. * This should always be customised in LocalSettings.php
  5375. */
  5376. $wgSecretKey = false;
  5377. /**
  5378. * Big list of banned IP addresses.
  5379. *
  5380. * This can have the following formats:
  5381. * - An array of addresses, either in the values
  5382. * or the keys (for backward compatibility, deprecated since 1.30)
  5383. * - A string, in that case this is the path to a file
  5384. * containing the list of IP addresses, one per line
  5385. */
  5386. $wgProxyList = [];
  5387. /** @} */ # end of proxy scanner settings
  5388. /************************************************************************//**
  5389. * @name Cookie settings
  5390. * @{
  5391. */
  5392. /**
  5393. * Default cookie lifetime, in seconds. Setting to 0 makes all cookies session-only.
  5394. */
  5395. $wgCookieExpiration = 30 * 86400;
  5396. /**
  5397. * Default login cookie lifetime, in seconds. Setting
  5398. * $wgExtendLoginCookieExpiration to null will use $wgCookieExpiration to
  5399. * calculate the cookie lifetime. As with $wgCookieExpiration, 0 will make
  5400. * login cookies session-only.
  5401. */
  5402. $wgExtendedLoginCookieExpiration = 180 * 86400;
  5403. /**
  5404. * Set to set an explicit domain on the login cookies eg, "justthis.domain.org"
  5405. * or ".any.subdomain.net"
  5406. */
  5407. $wgCookieDomain = '';
  5408. /**
  5409. * Set this variable if you want to restrict cookies to a certain path within
  5410. * the domain specified by $wgCookieDomain.
  5411. */
  5412. $wgCookiePath = '/';
  5413. /**
  5414. * Whether the "secure" flag should be set on the cookie. This can be:
  5415. * - true: Set secure flag
  5416. * - false: Don't set secure flag
  5417. * - "detect": Set the secure flag if $wgServer is set to an HTTPS URL
  5418. */
  5419. $wgCookieSecure = 'detect';
  5420. /**
  5421. * By default, MediaWiki checks if the client supports cookies during the
  5422. * login process, so that it can display an informative error message if
  5423. * cookies are disabled. Set this to true if you want to disable this cookie
  5424. * check.
  5425. */
  5426. $wgDisableCookieCheck = false;
  5427. /**
  5428. * Cookies generated by MediaWiki have names starting with this prefix. Set it
  5429. * to a string to use a custom prefix. Setting it to false causes the database
  5430. * name to be used as a prefix.
  5431. */
  5432. $wgCookiePrefix = false;
  5433. /**
  5434. * Set authentication cookies to HttpOnly to prevent access by JavaScript,
  5435. * in browsers that support this feature. This can mitigates some classes of
  5436. * XSS attack.
  5437. */
  5438. $wgCookieHttpOnly = true;
  5439. /**
  5440. * A list of cookies that vary the cache (for use by extensions)
  5441. */
  5442. $wgCacheVaryCookies = [];
  5443. /**
  5444. * Override to customise the session name
  5445. */
  5446. $wgSessionName = false;
  5447. /**
  5448. * Whether to set a cookie when a user is autoblocked. Doing so means that a blocked user, even
  5449. * after logging out and moving to a new IP address, will still be blocked. This cookie will contain
  5450. * an authentication code if $wgSecretKey is set, or otherwise will just be the block ID (in
  5451. * which case there is a possibility of an attacker discovering the names of revdeleted users, so
  5452. * it is best to use this in conjunction with $wgSecretKey being set).
  5453. */
  5454. $wgCookieSetOnAutoblock = false;
  5455. /** @} */ # end of cookie settings }
  5456. /************************************************************************//**
  5457. * @name LaTeX (mathematical formulas)
  5458. * @{
  5459. */
  5460. /**
  5461. * To use inline TeX, you need to compile 'texvc' (in the 'math' subdirectory of
  5462. * the MediaWiki package and have latex, dvips, gs (ghostscript), andconvert
  5463. * (ImageMagick) installed and available in the PATH.
  5464. * Please see math/README for more information.
  5465. */
  5466. $wgUseTeX = false;
  5467. /** @} */ # end LaTeX }
  5468. /************************************************************************//**
  5469. * @name Profiling, testing and debugging
  5470. *
  5471. * To enable profiling, edit StartProfiler.php
  5472. *
  5473. * @{
  5474. */
  5475. /**
  5476. * Filename for debug logging. See https://www.mediawiki.org/wiki/How_to_debug
  5477. * The debug log file should be not be publicly accessible if it is used, as it
  5478. * may contain private data.
  5479. */
  5480. $wgDebugLogFile = '';
  5481. /**
  5482. * Prefix for debug log lines
  5483. */
  5484. $wgDebugLogPrefix = '';
  5485. /**
  5486. * If true, instead of redirecting, show a page with a link to the redirect
  5487. * destination. This allows for the inspection of PHP error messages, and easy
  5488. * resubmission of form data. For developer use only.
  5489. */
  5490. $wgDebugRedirects = false;
  5491. /**
  5492. * If true, log debugging data from action=raw and load.php.
  5493. * This is normally false to avoid overlapping debug entries due to gen=css
  5494. * and gen=js requests.
  5495. */
  5496. $wgDebugRawPage = false;
  5497. /**
  5498. * Send debug data to an HTML comment in the output.
  5499. *
  5500. * This may occasionally be useful when supporting a non-technical end-user.
  5501. * It's more secure than exposing the debug log file to the web, since the
  5502. * output only contains private data for the current user. But it's not ideal
  5503. * for development use since data is lost on fatal errors and redirects.
  5504. */
  5505. $wgDebugComments = false;
  5506. /**
  5507. * Write SQL queries to the debug log.
  5508. *
  5509. * This setting is only used $wgLBFactoryConf['class'] is set to
  5510. * '\Wikimedia\Rdbms\LBFactorySimple' and $wgDBservers is an empty array; otherwise
  5511. * the DBO_DEBUG flag must be set in the 'flags' option of the database
  5512. * connection to achieve the same functionality.
  5513. */
  5514. $wgDebugDumpSql = false;
  5515. /**
  5516. * Performance expectations for DB usage
  5517. *
  5518. * @since 1.26
  5519. */
  5520. $wgTrxProfilerLimits = [
  5521. // HTTP GET/HEAD requests.
  5522. // Master queries should not happen on GET requests
  5523. 'GET' => [
  5524. 'masterConns' => 0,
  5525. 'writes' => 0,
  5526. 'readQueryTime' => 5
  5527. ],
  5528. // HTTP POST requests.
  5529. // Master reads and writes will happen for a subset of these.
  5530. 'POST' => [
  5531. 'readQueryTime' => 5,
  5532. 'writeQueryTime' => 1,
  5533. 'maxAffected' => 1000
  5534. ],
  5535. 'POST-nonwrite' => [
  5536. 'masterConns' => 0,
  5537. 'writes' => 0,
  5538. 'readQueryTime' => 5
  5539. ],
  5540. // Deferred updates that run after HTTP response is sent for GET requests
  5541. 'PostSend-GET' => [
  5542. 'readQueryTime' => 5,
  5543. 'writeQueryTime' => 1,
  5544. 'maxAffected' => 1000,
  5545. // Log master queries under the post-send entry point as they are discouraged
  5546. 'masterConns' => 0,
  5547. 'writes' => 0,
  5548. ],
  5549. // Deferred updates that run after HTTP response is sent for POST requests
  5550. 'PostSend-POST' => [
  5551. 'readQueryTime' => 5,
  5552. 'writeQueryTime' => 1,
  5553. 'maxAffected' => 1000
  5554. ],
  5555. // Background job runner
  5556. 'JobRunner' => [
  5557. 'readQueryTime' => 30,
  5558. 'writeQueryTime' => 5,
  5559. 'maxAffected' => 500 // ballpark of $wgUpdateRowsPerQuery
  5560. ],
  5561. // Command-line scripts
  5562. 'Maintenance' => [
  5563. 'writeQueryTime' => 5,
  5564. 'maxAffected' => 1000
  5565. ]
  5566. ];
  5567. /**
  5568. * Map of string log group names to log destinations.
  5569. *
  5570. * If set, wfDebugLog() output for that group will go to that file instead
  5571. * of the regular $wgDebugLogFile. Useful for enabling selective logging
  5572. * in production.
  5573. *
  5574. * Log destinations may be one of the following:
  5575. * - false to completely remove from the output, including from $wgDebugLogFile.
  5576. * - string values specifying a filename or URI.
  5577. * - associative array with keys:
  5578. * - 'destination' desired filename or URI.
  5579. * - 'sample' an integer value, specifying a sampling factor (optional)
  5580. * - 'level' A \Psr\Log\LogLevel constant, indicating the minimum level
  5581. * to log (optional, since 1.25)
  5582. *
  5583. * @par Example:
  5584. * @code
  5585. * $wgDebugLogGroups['redis'] = '/var/log/mediawiki/redis.log';
  5586. * @endcode
  5587. *
  5588. * @par Advanced example:
  5589. * @code
  5590. * $wgDebugLogGroups['memcached'] = [
  5591. * 'destination' => '/var/log/mediawiki/memcached.log',
  5592. * 'sample' => 1000, // log 1 message out of every 1,000.
  5593. * 'level' => \Psr\Log\LogLevel::WARNING
  5594. * ];
  5595. * @endcode
  5596. */
  5597. $wgDebugLogGroups = [];
  5598. /**
  5599. * Default service provider for creating Psr\Log\LoggerInterface instances.
  5600. *
  5601. * The value should be an array suitable for use with
  5602. * ObjectFactory::getObjectFromSpec(). The created object is expected to
  5603. * implement the MediaWiki\Logger\Spi interface. See ObjectFactory for additional
  5604. * details.
  5605. *
  5606. * Alternately the MediaWiki\Logger\LoggerFactory::registerProvider method can
  5607. * be called to inject an MediaWiki\Logger\Spi instance into the LoggerFactory
  5608. * and bypass the use of this configuration variable entirely.
  5609. *
  5610. * @par To completely disable logging:
  5611. * @code
  5612. * $wgMWLoggerDefaultSpi = [ 'class' => \MediaWiki\Logger\NullSpi::class ];
  5613. * @endcode
  5614. *
  5615. * @since 1.25
  5616. * @var array $wgMWLoggerDefaultSpi
  5617. * @see MwLogger
  5618. */
  5619. $wgMWLoggerDefaultSpi = [
  5620. 'class' => \MediaWiki\Logger\LegacySpi::class,
  5621. ];
  5622. /**
  5623. * Display debug data at the bottom of the main content area.
  5624. *
  5625. * Useful for developers and technical users trying to working on a closed wiki.
  5626. */
  5627. $wgShowDebug = false;
  5628. /**
  5629. * Prefix debug messages with relative timestamp. Very-poor man's profiler.
  5630. * Since 1.19 also includes memory usage.
  5631. */
  5632. $wgDebugTimestamps = false;
  5633. /**
  5634. * Print HTTP headers for every request in the debug information.
  5635. */
  5636. $wgDebugPrintHttpHeaders = true;
  5637. /**
  5638. * Show the contents of $wgHooks in Special:Version
  5639. */
  5640. $wgSpecialVersionShowHooks = false;
  5641. /**
  5642. * Whether to show "we're sorry, but there has been a database error" pages.
  5643. * Displaying errors aids in debugging, but may display information useful
  5644. * to an attacker.
  5645. */
  5646. $wgShowSQLErrors = false;
  5647. /**
  5648. * If set to true, uncaught exceptions will print a complete stack trace
  5649. * to output. This should only be used for debugging, as it may reveal
  5650. * private information in function parameters due to PHP's backtrace
  5651. * formatting.
  5652. */
  5653. $wgShowExceptionDetails = false;
  5654. /**
  5655. * If true, show a backtrace for database errors
  5656. *
  5657. * @note This setting only applies when connection errors and query errors are
  5658. * reported in the normal manner. $wgShowExceptionDetails applies in other cases,
  5659. * including those in which an uncaught exception is thrown from within the
  5660. * exception handler.
  5661. */
  5662. $wgShowDBErrorBacktrace = false;
  5663. /**
  5664. * If true, send the exception backtrace to the error log
  5665. */
  5666. $wgLogExceptionBacktrace = true;
  5667. /**
  5668. * If true, the MediaWiki error handler passes errors/warnings to the default error handler
  5669. * after logging them. The setting is ignored when the track_errors php.ini flag is true.
  5670. */
  5671. $wgPropagateErrors = true;
  5672. /**
  5673. * Expose backend server host names through the API and various HTML comments
  5674. */
  5675. $wgShowHostnames = false;
  5676. /**
  5677. * Override server hostname detection with a hardcoded value.
  5678. * Should be a string, default false.
  5679. * @since 1.20
  5680. */
  5681. $wgOverrideHostname = false;
  5682. /**
  5683. * If set to true MediaWiki will throw notices for some possible error
  5684. * conditions and for deprecated functions.
  5685. */
  5686. $wgDevelopmentWarnings = false;
  5687. /**
  5688. * Release limitation to wfDeprecated warnings, if set to a release number
  5689. * development warnings will not be generated for deprecations added in releases
  5690. * after the limit.
  5691. */
  5692. $wgDeprecationReleaseLimit = false;
  5693. /**
  5694. * Only record profiling info for pages that took longer than this
  5695. * @deprecated since 1.25: set $wgProfiler['threshold'] instead.
  5696. */
  5697. $wgProfileLimit = 0.0;
  5698. /**
  5699. * Don't put non-profiling info into log file
  5700. *
  5701. * @deprecated since 1.23, set the log file in
  5702. * $wgDebugLogGroups['profileoutput'] instead.
  5703. */
  5704. $wgProfileOnly = false;
  5705. /**
  5706. * Destination of statsd metrics.
  5707. *
  5708. * A host or host:port of a statsd server. Port defaults to 8125.
  5709. *
  5710. * If not set, statsd metrics will not be collected.
  5711. *
  5712. * @see wfLogProfilingData
  5713. * @since 1.25
  5714. */
  5715. $wgStatsdServer = false;
  5716. /**
  5717. * Prefix for metric names sent to $wgStatsdServer.
  5718. *
  5719. * @see MediaWikiServices::getStatsdDataFactory
  5720. * @see BufferingStatsdDataFactory
  5721. * @since 1.25
  5722. */
  5723. $wgStatsdMetricPrefix = 'MediaWiki';
  5724. /**
  5725. * Sampling rate for statsd metrics as an associative array of patterns and rates.
  5726. * Patterns are Unix shell patterns (e.g. 'MediaWiki.api.*').
  5727. * Rates are sampling probabilities (e.g. 0.1 means 1 in 10 events are sampled).
  5728. * @since 1.28
  5729. */
  5730. $wgStatsdSamplingRates = [
  5731. 'wanobjectcache:*' => 0.001
  5732. ];
  5733. /**
  5734. * InfoAction retrieves a list of transclusion links (both to and from).
  5735. * This number puts a limit on that query in the case of highly transcluded
  5736. * templates.
  5737. */
  5738. $wgPageInfoTransclusionLimit = 50;
  5739. /**
  5740. * Set this to an integer to only do synchronous site_stats updates
  5741. * one every *this many* updates. The other requests go into pending
  5742. * delta values in $wgMemc. Make sure that $wgMemc is a global cache.
  5743. * If set to -1, updates *only* go to $wgMemc (useful for daemons).
  5744. */
  5745. $wgSiteStatsAsyncFactor = false;
  5746. /**
  5747. * Parser test suite files to be run by parserTests.php when no specific
  5748. * filename is passed to it.
  5749. *
  5750. * Extensions using extension.json will have any *.txt file in a
  5751. * tests/parser/ directory automatically run.
  5752. *
  5753. * Core tests can be added to ParserTestRunner::$coreTestFiles.
  5754. *
  5755. * Use full paths.
  5756. *
  5757. * @deprecated since 1.30
  5758. */
  5759. $wgParserTestFiles = [];
  5760. /**
  5761. * Allow running of javascript test suites via [[Special:JavaScriptTest]] (such as QUnit).
  5762. */
  5763. $wgEnableJavaScriptTest = false;
  5764. /**
  5765. * Overwrite the caching key prefix with custom value.
  5766. * @since 1.19
  5767. */
  5768. $wgCachePrefix = false;
  5769. /**
  5770. * Display the new debugging toolbar. This also enables profiling on database
  5771. * queries and other useful output.
  5772. * Will be ignored if $wgUseFileCache or $wgUseSquid is enabled.
  5773. *
  5774. * @since 1.19
  5775. */
  5776. $wgDebugToolbar = false;
  5777. /** @} */ # end of profiling, testing and debugging }
  5778. /************************************************************************//**
  5779. * @name Search
  5780. * @{
  5781. */
  5782. /**
  5783. * Set this to true to disable the full text search feature.
  5784. */
  5785. $wgDisableTextSearch = false;
  5786. /**
  5787. * Set to true to have nicer highlighted text in search results,
  5788. * by default off due to execution overhead
  5789. */
  5790. $wgAdvancedSearchHighlighting = false;
  5791. /**
  5792. * Regexp to match word boundaries, defaults for non-CJK languages
  5793. * should be empty for CJK since the words are not separate
  5794. */
  5795. $wgSearchHighlightBoundaries = '[\p{Z}\p{P}\p{C}]';
  5796. /**
  5797. * Template for OpenSearch suggestions, defaults to API action=opensearch
  5798. *
  5799. * Sites with heavy load would typically have these point to a custom
  5800. * PHP wrapper to avoid firing up mediawiki for every keystroke
  5801. *
  5802. * Placeholders: {searchTerms}
  5803. *
  5804. * @deprecated since 1.25 Use $wgOpenSearchTemplates['application/x-suggestions+json'] instead
  5805. */
  5806. $wgOpenSearchTemplate = false;
  5807. /**
  5808. * Templates for OpenSearch suggestions, defaults to API action=opensearch
  5809. *
  5810. * Sites with heavy load would typically have these point to a custom
  5811. * PHP wrapper to avoid firing up mediawiki for every keystroke
  5812. *
  5813. * Placeholders: {searchTerms}
  5814. */
  5815. $wgOpenSearchTemplates = [
  5816. 'application/x-suggestions+json' => false,
  5817. 'application/x-suggestions+xml' => false,
  5818. ];
  5819. /**
  5820. * Enable OpenSearch suggestions requested by MediaWiki. Set this to
  5821. * false if you've disabled scripts that use api?action=opensearch and
  5822. * want reduce load caused by cached scripts still pulling suggestions.
  5823. * It will let the API fallback by responding with an empty array.
  5824. */
  5825. $wgEnableOpenSearchSuggest = true;
  5826. /**
  5827. * Integer defining default number of entries to show on
  5828. * OpenSearch call.
  5829. */
  5830. $wgOpenSearchDefaultLimit = 10;
  5831. /**
  5832. * Minimum length of extract in <Description>. Actual extracts will last until the end of sentence.
  5833. */
  5834. $wgOpenSearchDescriptionLength = 100;
  5835. /**
  5836. * Expiry time for search suggestion responses
  5837. */
  5838. $wgSearchSuggestCacheExpiry = 1200;
  5839. /**
  5840. * If you've disabled search semi-permanently, this also disables updates to the
  5841. * table. If you ever re-enable, be sure to rebuild the search table.
  5842. */
  5843. $wgDisableSearchUpdate = false;
  5844. /**
  5845. * List of namespaces which are searched by default.
  5846. *
  5847. * @par Example:
  5848. * @code
  5849. * $wgNamespacesToBeSearchedDefault[NS_MAIN] = true;
  5850. * $wgNamespacesToBeSearchedDefault[NS_PROJECT] = true;
  5851. * @endcode
  5852. */
  5853. $wgNamespacesToBeSearchedDefault = [
  5854. NS_MAIN => true,
  5855. ];
  5856. /**
  5857. * Disable the internal MySQL-based search, to allow it to be
  5858. * implemented by an extension instead.
  5859. */
  5860. $wgDisableInternalSearch = false;
  5861. /**
  5862. * Set this to a URL to forward search requests to some external location.
  5863. * If the URL includes '$1', this will be replaced with the URL-encoded
  5864. * search term.
  5865. *
  5866. * @par Example:
  5867. * To forward to Google you'd have something like:
  5868. * @code
  5869. * $wgSearchForwardUrl =
  5870. * 'https://www.google.com/search?q=$1' .
  5871. * '&domains=https://example.com' .
  5872. * '&sitesearch=https://example.com' .
  5873. * '&ie=utf-8&oe=utf-8';
  5874. * @endcode
  5875. */
  5876. $wgSearchForwardUrl = null;
  5877. /**
  5878. * Search form behavior.
  5879. * - true = use Go & Search buttons
  5880. * - false = use Go button & Advanced search link
  5881. */
  5882. $wgUseTwoButtonsSearchForm = true;
  5883. /**
  5884. * Array of namespaces to generate a Google sitemap for when the
  5885. * maintenance/generateSitemap.php script is run, or false if one is to be
  5886. * generated for all namespaces.
  5887. */
  5888. $wgSitemapNamespaces = false;
  5889. /**
  5890. * Custom namespace priorities for sitemaps. Setting this will allow you to
  5891. * set custom priorities to namespaces when sitemaps are generated using the
  5892. * maintenance/generateSitemap.php script.
  5893. *
  5894. * This should be a map of namespace IDs to priority
  5895. * @par Example:
  5896. * @code
  5897. * $wgSitemapNamespacesPriorities = [
  5898. * NS_USER => '0.9',
  5899. * NS_HELP => '0.0',
  5900. * ];
  5901. * @endcode
  5902. */
  5903. $wgSitemapNamespacesPriorities = false;
  5904. /**
  5905. * If true, searches for IP addresses will be redirected to that IP's
  5906. * contributions page. E.g. searching for "1.2.3.4" will redirect to
  5907. * [[Special:Contributions/1.2.3.4]]
  5908. */
  5909. $wgEnableSearchContributorsByIP = true;
  5910. /** @} */ # end of search settings
  5911. /************************************************************************//**
  5912. * @name Edit user interface
  5913. * @{
  5914. */
  5915. /**
  5916. * Path to the GNU diff3 utility. If the file doesn't exist, edit conflicts will
  5917. * fall back to the old behavior (no merging).
  5918. */
  5919. $wgDiff3 = '/usr/bin/diff3';
  5920. /**
  5921. * Path to the GNU diff utility.
  5922. */
  5923. $wgDiff = '/usr/bin/diff';
  5924. /**
  5925. * Which namespaces have special treatment where they should be preview-on-open
  5926. * Internally only Category: pages apply, but using this extensions (e.g. Semantic MediaWiki)
  5927. * can specify namespaces of pages they have special treatment for
  5928. */
  5929. $wgPreviewOnOpenNamespaces = [
  5930. NS_CATEGORY => true
  5931. ];
  5932. /**
  5933. * Enable the UniversalEditButton for browsers that support it
  5934. * (currently only Firefox with an extension)
  5935. * See http://universaleditbutton.org for more background information
  5936. */
  5937. $wgUniversalEditButton = true;
  5938. /**
  5939. * If user doesn't specify any edit summary when making a an edit, MediaWiki
  5940. * will try to automatically create one. This feature can be disabled by set-
  5941. * ting this variable false.
  5942. */
  5943. $wgUseAutomaticEditSummaries = true;
  5944. /** @} */ # end edit UI }
  5945. /************************************************************************//**
  5946. * @name Maintenance
  5947. * See also $wgSiteNotice
  5948. * @{
  5949. */
  5950. /**
  5951. * @cond file_level_code
  5952. * Set $wgCommandLineMode if it's not set already, to avoid notices
  5953. */
  5954. if ( !isset( $wgCommandLineMode ) ) {
  5955. $wgCommandLineMode = false;
  5956. }
  5957. /** @endcond */
  5958. /**
  5959. * For colorized maintenance script output, is your terminal background dark ?
  5960. */
  5961. $wgCommandLineDarkBg = false;
  5962. /**
  5963. * Set this to a string to put the wiki into read-only mode. The text will be
  5964. * used as an explanation to users.
  5965. *
  5966. * This prevents most write operations via the web interface. Cache updates may
  5967. * still be possible. To prevent database writes completely, use the read_only
  5968. * option in MySQL.
  5969. */
  5970. $wgReadOnly = null;
  5971. /**
  5972. * Set this to true to put the wiki watchlists into read-only mode.
  5973. * @var bool
  5974. * @since 1.31
  5975. */
  5976. $wgReadOnlyWatchedItemStore = false;
  5977. /**
  5978. * If this lock file exists (size > 0), the wiki will be forced into read-only mode.
  5979. * Its contents will be shown to users as part of the read-only warning
  5980. * message.
  5981. *
  5982. * Will default to "{$wgUploadDirectory}/lock_yBgMBwiR" in Setup.php
  5983. */
  5984. $wgReadOnlyFile = false;
  5985. /**
  5986. * When you run the web-based upgrade utility, it will tell you what to set
  5987. * this to in order to authorize the upgrade process. It will subsequently be
  5988. * used as a password, to authorize further upgrades.
  5989. *
  5990. * For security, do not set this to a guessable string. Use the value supplied
  5991. * by the install/upgrade process. To cause the upgrader to generate a new key,
  5992. * delete the old key from LocalSettings.php.
  5993. */
  5994. $wgUpgradeKey = false;
  5995. /**
  5996. * Fully specified path to git binary
  5997. */
  5998. $wgGitBin = '/usr/bin/git';
  5999. /**
  6000. * Map GIT repository URLs to viewer URLs to provide links in Special:Version
  6001. *
  6002. * Key is a pattern passed to preg_match() and preg_replace(),
  6003. * without the delimiters (which are #) and must match the whole URL.
  6004. * The value is the replacement for the key (it can contain $1, etc.)
  6005. * %h will be replaced by the short SHA-1 (7 first chars) and %H by the
  6006. * full SHA-1 of the HEAD revision.
  6007. * %r will be replaced with a URL-encoded version of $1.
  6008. * %R will be replaced with $1 and no URL-encoding
  6009. *
  6010. * @since 1.20
  6011. */
  6012. $wgGitRepositoryViewers = [
  6013. 'https://(?:[a-z0-9_]+@)?gerrit.wikimedia.org/r/(?:p/)?(.*)' =>
  6014. 'https://gerrit.wikimedia.org/g/%R/+/%H',
  6015. 'ssh://(?:[a-z0-9_]+@)?gerrit.wikimedia.org:29418/(.*)' =>
  6016. 'https://gerrit.wikimedia.org/g/%R/+/%H',
  6017. ];
  6018. /** @} */ # End of maintenance }
  6019. /************************************************************************//**
  6020. * @name Recent changes, new pages, watchlist and history
  6021. * @{
  6022. */
  6023. /**
  6024. * Recentchanges items are periodically purged; entries older than this many
  6025. * seconds will go.
  6026. * Default: 90 days = about three months
  6027. */
  6028. $wgRCMaxAge = 90 * 24 * 3600;
  6029. /**
  6030. * Page watchers inactive for more than this many seconds are considered inactive.
  6031. * Used mainly by action=info. Default: 180 days = about six months.
  6032. * @since 1.26
  6033. */
  6034. $wgWatchersMaxAge = 180 * 24 * 3600;
  6035. /**
  6036. * If active watchers (per above) are this number or less, do not disclose it.
  6037. * Left to 1, prevents unprivileged users from knowing for sure that there are 0.
  6038. * Set to -1 if you want to always complement watchers count with this info.
  6039. * @since 1.26
  6040. */
  6041. $wgUnwatchedPageSecret = 1;
  6042. /**
  6043. * Filter $wgRCLinkDays by $wgRCMaxAge to avoid showing links for numbers
  6044. * higher than what will be stored. Note that this is disabled by default
  6045. * because we sometimes do have RC data which is beyond the limit for some
  6046. * reason, and some users may use the high numbers to display that data which
  6047. * is still there.
  6048. */
  6049. $wgRCFilterByAge = false;
  6050. /**
  6051. * List of Limits options to list in the Special:Recentchanges and
  6052. * Special:Recentchangeslinked pages.
  6053. */
  6054. $wgRCLinkLimits = [ 50, 100, 250, 500 ];
  6055. /**
  6056. * List of Days options to list in the Special:Recentchanges and
  6057. * Special:Recentchangeslinked pages.
  6058. */
  6059. $wgRCLinkDays = [ 1, 3, 7, 14, 30 ];
  6060. /**
  6061. * Configuration for feeds to which notifications about recent changes will be sent.
  6062. *
  6063. * The following feed classes are available by default:
  6064. * - 'UDPRCFeedEngine' - sends recent changes over UDP to the specified server.
  6065. * - 'RedisPubSubFeedEngine' - send recent changes to Redis.
  6066. *
  6067. * Only 'class' or 'uri' is required. If 'uri' is set instead of 'class', then
  6068. * RecentChange::getEngine() is used to determine the class. All options are
  6069. * passed to the constructor.
  6070. *
  6071. * Common options:
  6072. * - 'class' -- The class to use for this feed (must implement RCFeed).
  6073. * - 'omit_bots' -- Exclude bot edits from the feed. (default: false)
  6074. * - 'omit_anon' -- Exclude anonymous edits from the feed. (default: false)
  6075. * - 'omit_user' -- Exclude edits by registered users from the feed. (default: false)
  6076. * - 'omit_minor' -- Exclude minor edits from the feed. (default: false)
  6077. * - 'omit_patrolled' -- Exclude patrolled edits from the feed. (default: false)
  6078. *
  6079. * FormattedRCFeed-specific options:
  6080. * - 'uri' -- [required] The address to which the messages are sent.
  6081. * The uri scheme of this string will be looked up in $wgRCEngines
  6082. * to determine which RCFeedEngine class to use.
  6083. * - 'formatter' -- [required] The class (implementing RCFeedFormatter) which will
  6084. * produce the text to send. This can also be an object of the class.
  6085. * Formatters available by default: JSONRCFeedFormatter, XMLRCFeedFormatter,
  6086. * IRCColourfulRCFeedFormatter.
  6087. *
  6088. * IRCColourfulRCFeedFormatter-specific options:
  6089. * - 'add_interwiki_prefix' -- whether the titles should be prefixed with
  6090. * the first entry in the $wgLocalInterwikis array (or the value of
  6091. * $wgLocalInterwiki, if set)
  6092. *
  6093. * JSONRCFeedFormatter-specific options:
  6094. * - 'channel' -- if set, the 'channel' parameter is also set in JSON values.
  6095. *
  6096. * @example $wgRCFeeds['example'] = [
  6097. * 'uri' => 'udp://localhost:1336',
  6098. * 'formatter' => 'JSONRCFeedFormatter',
  6099. * 'add_interwiki_prefix' => false,
  6100. * 'omit_bots' => true,
  6101. * ];
  6102. * @example $wgRCFeeds['example'] = [
  6103. * 'uri' => 'udp://localhost:1338',
  6104. * 'formatter' => 'IRCColourfulRCFeedFormatter',
  6105. * 'add_interwiki_prefix' => false,
  6106. * 'omit_bots' => true,
  6107. * ];
  6108. * @example $wgRCFeeds['example'] = [
  6109. * 'class' => ExampleRCFeed::class,
  6110. * ];
  6111. * @since 1.22
  6112. */
  6113. $wgRCFeeds = [];
  6114. /**
  6115. * Used by RecentChange::getEngine to find the correct engine for a given URI scheme.
  6116. * Keys are scheme names, values are names of FormattedRCFeed sub classes.
  6117. * @since 1.22
  6118. */
  6119. $wgRCEngines = [
  6120. 'redis' => RedisPubSubFeedEngine::class,
  6121. 'udp' => UDPRCFeedEngine::class,
  6122. ];
  6123. /**
  6124. * Treat category membership changes as a RecentChange.
  6125. * Changes are mentioned in RC for page actions as follows:
  6126. * - creation: pages created with categories are mentioned
  6127. * - edit: category additions/removals to existing pages are mentioned
  6128. * - move: nothing is mentioned (unless templates used depend on the title)
  6129. * - deletion: nothing is mentioned
  6130. * - undeletion: nothing is mentioned
  6131. *
  6132. * @since 1.27
  6133. */
  6134. $wgRCWatchCategoryMembership = false;
  6135. /**
  6136. * Use RC Patrolling to check for vandalism (from recent changes and watchlists)
  6137. * New pages and new files are included.
  6138. *
  6139. * @note If you disable all patrolling features, you probably also want to
  6140. * remove 'patrol' from $wgFilterLogTypes so a show/hide link isn't shown on
  6141. * Special:Log.
  6142. */
  6143. $wgUseRCPatrol = true;
  6144. /**
  6145. * Whether a preference is displayed for structured change filters.
  6146. * If false, no preference is displayed and structured change filters are disabled.
  6147. * If true, structured change filters are *enabled* by default, and a preference is displayed
  6148. * that lets users disable them.
  6149. *
  6150. * Temporary variable during development and will be removed.
  6151. *
  6152. * @since 1.30
  6153. */
  6154. $wgStructuredChangeFiltersShowPreference = false;
  6155. /**
  6156. * Whether to enable RCFilters app on Special:Watchlist
  6157. *
  6158. * Temporary variable during development and will be removed.
  6159. */
  6160. $wgStructuredChangeFiltersOnWatchlist = false;
  6161. /**
  6162. * Polling rate, in seconds, used by the 'live update' and 'view newest' features
  6163. * of the RCFilters app on SpecialRecentChanges and Special:Watchlist.
  6164. * 0 to disable completely.
  6165. */
  6166. $wgStructuredChangeFiltersLiveUpdatePollingRate = 3;
  6167. /**
  6168. * Use new page patrolling to check new pages on Special:Newpages
  6169. *
  6170. * @note If you disable all patrolling features, you probably also want to
  6171. * remove 'patrol' from $wgFilterLogTypes so a show/hide link isn't shown on
  6172. * Special:Log.
  6173. */
  6174. $wgUseNPPatrol = true;
  6175. /**
  6176. * Use file patrolling to check new files on Special:Newfiles
  6177. *
  6178. * @note If you disable all patrolling features, you probably also want to
  6179. * remove 'patrol' from $wgFilterLogTypes so a show/hide link isn't shown on
  6180. * Special:Log.
  6181. *
  6182. * @since 1.27
  6183. */
  6184. $wgUseFilePatrol = true;
  6185. /**
  6186. * Provide syndication feeds (RSS, Atom) for, e.g., Recentchanges, Newpages
  6187. */
  6188. $wgFeed = true;
  6189. /**
  6190. * Set maximum number of results to return in syndication feeds (RSS, Atom) for
  6191. * eg Recentchanges, Newpages.
  6192. */
  6193. $wgFeedLimit = 50;
  6194. /**
  6195. * _Minimum_ timeout for cached Recentchanges feed, in seconds.
  6196. * A cached version will continue to be served out even if changes
  6197. * are made, until this many seconds runs out since the last render.
  6198. *
  6199. * If set to 0, feed caching is disabled. Use this for debugging only;
  6200. * feed generation can be pretty slow with diffs.
  6201. */
  6202. $wgFeedCacheTimeout = 60;
  6203. /**
  6204. * When generating Recentchanges RSS/Atom feed, diffs will not be generated for
  6205. * pages larger than this size.
  6206. */
  6207. $wgFeedDiffCutoff = 32768;
  6208. /**
  6209. * Override the site's default RSS/ATOM feed for recentchanges that appears on
  6210. * every page. Some sites might have a different feed they'd like to promote
  6211. * instead of the RC feed (maybe like a "Recent New Articles" or "Breaking news" one).
  6212. * Should be a format as key (either 'rss' or 'atom') and an URL to the feed
  6213. * as value.
  6214. * @par Example:
  6215. * Configure the 'atom' feed to https://example.com/somefeed.xml
  6216. * @code
  6217. * $wgSiteFeed['atom'] = "https://example.com/somefeed.xml";
  6218. * @endcode
  6219. */
  6220. $wgOverrideSiteFeed = [];
  6221. /**
  6222. * Available feeds objects.
  6223. * Should probably only be defined when a page is syndicated ie when
  6224. * $wgOut->isSyndicated() is true.
  6225. */
  6226. $wgFeedClasses = [
  6227. 'rss' => RSSFeed::class,
  6228. 'atom' => AtomFeed::class,
  6229. ];
  6230. /**
  6231. * Which feed types should we provide by default? This can include 'rss',
  6232. * 'atom', neither, or both.
  6233. */
  6234. $wgAdvertisedFeedTypes = [ 'atom' ];
  6235. /**
  6236. * Show watching users in recent changes, watchlist and page history views
  6237. */
  6238. $wgRCShowWatchingUsers = false; # UPO
  6239. /**
  6240. * Show the amount of changed characters in recent changes
  6241. */
  6242. $wgRCShowChangedSize = true;
  6243. /**
  6244. * If the difference between the character counts of the text
  6245. * before and after the edit is below that value, the value will be
  6246. * highlighted on the RC page.
  6247. */
  6248. $wgRCChangedSizeThreshold = 500;
  6249. /**
  6250. * Show "Updated (since my last visit)" marker in RC view, watchlist and history
  6251. * view for watched pages with new changes
  6252. */
  6253. $wgShowUpdatedMarker = true;
  6254. /**
  6255. * Disable links to talk pages of anonymous users (IPs) in listings on special
  6256. * pages like page history, Special:Recentchanges, etc.
  6257. */
  6258. $wgDisableAnonTalk = false;
  6259. /**
  6260. * Allow filtering by change tag in recentchanges, history, etc
  6261. * Has no effect if no tags are defined in valid_tag.
  6262. */
  6263. $wgUseTagFilter = true;
  6264. /**
  6265. * List of core tags to enable. Available tags are:
  6266. * - 'mw-contentmodelchange': Edit changes content model of a page
  6267. * - 'mw-new-redirect': Edit makes new redirect page (new page or by changing content page)
  6268. * - 'mw-removed-redirect': Edit changes an existing redirect into a non-redirect
  6269. * - 'mw-changed-redirect-target': Edit changes redirect target
  6270. * - 'mw-blank': Edit completely blanks the page
  6271. * - 'mw-replace': Edit removes more than 90% of the content
  6272. * - 'mw-rollback': Edit is a rollback, made through the rollback link or rollback API
  6273. * - 'mw-undo': Edit made through an undo link
  6274. *
  6275. * @var array
  6276. * @since 1.31
  6277. */
  6278. $wgSoftwareTags = [
  6279. 'mw-contentmodelchange' => true,
  6280. 'mw-new-redirect' => true,
  6281. 'mw-removed-redirect' => true,
  6282. 'mw-changed-redirect-target' => true,
  6283. 'mw-blank' => true,
  6284. 'mw-replace' => true,
  6285. 'mw-rollback' => true,
  6286. 'mw-undo' => true,
  6287. ];
  6288. /**
  6289. * If set to an integer, pages that are watched by this many users or more
  6290. * will not require the unwatchedpages permission to view the number of
  6291. * watchers.
  6292. *
  6293. * @since 1.21
  6294. */
  6295. $wgUnwatchedPageThreshold = false;
  6296. /**
  6297. * Flags (letter symbols) shown in recent changes and watchlist to indicate
  6298. * certain types of edits.
  6299. *
  6300. * To register a new one:
  6301. * @code
  6302. * $wgRecentChangesFlags['flag'] => [
  6303. * // message for the letter displayed next to rows on changes lists
  6304. * 'letter' => 'letter-msg',
  6305. * // message for the tooltip of the letter
  6306. * 'title' => 'tooltip-msg',
  6307. * // optional (defaults to 'tooltip-msg'), message to use in the legend box
  6308. * 'legend' => 'legend-msg',
  6309. * // optional (defaults to 'flag'), CSS class to put on changes lists rows
  6310. * 'class' => 'css-class',
  6311. * // optional (defaults to 'any'), how top-level flag is determined. 'any'
  6312. * // will set the top-level flag if any line contains the flag, 'all' will
  6313. * // only be set if all lines contain the flag.
  6314. * 'grouping' => 'any',
  6315. * ];
  6316. * @endcode
  6317. *
  6318. * @since 1.22
  6319. */
  6320. $wgRecentChangesFlags = [
  6321. 'newpage' => [
  6322. 'letter' => 'newpageletter',
  6323. 'title' => 'recentchanges-label-newpage',
  6324. 'legend' => 'recentchanges-legend-newpage',
  6325. 'grouping' => 'any',
  6326. ],
  6327. 'minor' => [
  6328. 'letter' => 'minoreditletter',
  6329. 'title' => 'recentchanges-label-minor',
  6330. 'legend' => 'recentchanges-legend-minor',
  6331. 'class' => 'minoredit',
  6332. 'grouping' => 'all',
  6333. ],
  6334. 'bot' => [
  6335. 'letter' => 'boteditletter',
  6336. 'title' => 'recentchanges-label-bot',
  6337. 'legend' => 'recentchanges-legend-bot',
  6338. 'class' => 'botedit',
  6339. 'grouping' => 'all',
  6340. ],
  6341. 'unpatrolled' => [
  6342. 'letter' => 'unpatrolledletter',
  6343. 'title' => 'recentchanges-label-unpatrolled',
  6344. 'legend' => 'recentchanges-legend-unpatrolled',
  6345. 'grouping' => 'any',
  6346. ],
  6347. ];
  6348. /** @} */ # end RC/watchlist }
  6349. /************************************************************************//**
  6350. * @name Copyright and credits settings
  6351. * @{
  6352. */
  6353. /**
  6354. * Override for copyright metadata.
  6355. *
  6356. * This is the name of the page containing information about the wiki's copyright status,
  6357. * which will be added as a link in the footer if it is specified. It overrides
  6358. * $wgRightsUrl if both are specified.
  6359. */
  6360. $wgRightsPage = null;
  6361. /**
  6362. * Set this to specify an external URL containing details about the content license used on your
  6363. * wiki.
  6364. * If $wgRightsPage is set then this setting is ignored.
  6365. */
  6366. $wgRightsUrl = null;
  6367. /**
  6368. * If either $wgRightsUrl or $wgRightsPage is specified then this variable gives the text for the
  6369. * link.
  6370. * If using $wgRightsUrl then this value must be specified. If using $wgRightsPage then the name
  6371. * of the page will also be used as the link if this variable is not set.
  6372. */
  6373. $wgRightsText = null;
  6374. /**
  6375. * Override for copyright metadata.
  6376. */
  6377. $wgRightsIcon = null;
  6378. /**
  6379. * Set this to true if you want detailed copyright information forms on Upload.
  6380. */
  6381. $wgUseCopyrightUpload = false;
  6382. /**
  6383. * Set this to the number of authors that you want to be credited below an
  6384. * article text. Set it to zero to hide the attribution block, and a negative
  6385. * number (like -1) to show all authors. Note that this will require 2-3 extra
  6386. * database hits, which can have a not insignificant impact on performance for
  6387. * large wikis.
  6388. */
  6389. $wgMaxCredits = 0;
  6390. /**
  6391. * If there are more than $wgMaxCredits authors, show $wgMaxCredits of them.
  6392. * Otherwise, link to a separate credits page.
  6393. */
  6394. $wgShowCreditsIfMax = true;
  6395. /** @} */ # end of copyright and credits settings }
  6396. /************************************************************************//**
  6397. * @name Import / Export
  6398. * @{
  6399. */
  6400. /**
  6401. * List of interwiki prefixes for wikis we'll accept as sources for
  6402. * Special:Import and API action=import. Since complete page history can be
  6403. * imported, these should be 'trusted'.
  6404. *
  6405. * This can either be a regular array, or an associative map specifying
  6406. * subprojects on the interwiki map of the target wiki, or a mix of the two,
  6407. * e.g.
  6408. * @code
  6409. * $wgImportSources = [
  6410. * 'wikipedia' => [ 'cs', 'en', 'fr', 'zh' ],
  6411. * 'wikispecies',
  6412. * 'wikia' => [ 'animanga', 'brickipedia', 'desserts' ],
  6413. * ];
  6414. * @endcode
  6415. *
  6416. * If you have a very complex import sources setup, you can lazy-load it using
  6417. * the ImportSources hook.
  6418. *
  6419. * If a user has the 'import' permission but not the 'importupload' permission,
  6420. * they will only be able to run imports through this transwiki interface.
  6421. */
  6422. $wgImportSources = [];
  6423. /**
  6424. * Optional default target namespace for interwiki imports.
  6425. * Can use this to create an incoming "transwiki"-style queue.
  6426. * Set to numeric key, not the name.
  6427. *
  6428. * Users may override this in the Special:Import dialog.
  6429. */
  6430. $wgImportTargetNamespace = null;
  6431. /**
  6432. * If set to false, disables the full-history option on Special:Export.
  6433. * This is currently poorly optimized for long edit histories, so is
  6434. * disabled on Wikimedia's sites.
  6435. */
  6436. $wgExportAllowHistory = true;
  6437. /**
  6438. * If set nonzero, Special:Export requests for history of pages with
  6439. * more revisions than this will be rejected. On some big sites things
  6440. * could get bogged down by very very long pages.
  6441. */
  6442. $wgExportMaxHistory = 0;
  6443. /**
  6444. * Return distinct author list (when not returning full history)
  6445. */
  6446. $wgExportAllowListContributors = false;
  6447. /**
  6448. * If non-zero, Special:Export accepts a "pagelink-depth" parameter
  6449. * up to this specified level, which will cause it to include all
  6450. * pages linked to from the pages you specify. Since this number
  6451. * can become *insanely large* and could easily break your wiki,
  6452. * it's disabled by default for now.
  6453. *
  6454. * @warning There's a HARD CODED limit of 5 levels of recursion to prevent a
  6455. * crazy-big export from being done by someone setting the depth number too
  6456. * high. In other words, last resort safety net.
  6457. */
  6458. $wgExportMaxLinkDepth = 0;
  6459. /**
  6460. * Whether to allow the "export all pages in namespace" option
  6461. */
  6462. $wgExportFromNamespaces = false;
  6463. /**
  6464. * Whether to allow exporting the entire wiki into a single file
  6465. */
  6466. $wgExportAllowAll = false;
  6467. /**
  6468. * Maximum number of pages returned by the GetPagesFromCategory and
  6469. * GetPagesFromNamespace functions.
  6470. *
  6471. * @since 1.27
  6472. */
  6473. $wgExportPagelistLimit = 5000;
  6474. /** @} */ # end of import/export }
  6475. /*************************************************************************//**
  6476. * @name Extensions
  6477. * @{
  6478. */
  6479. /**
  6480. * A list of callback functions which are called once MediaWiki is fully
  6481. * initialised
  6482. */
  6483. $wgExtensionFunctions = [];
  6484. /**
  6485. * Extension messages files.
  6486. *
  6487. * Associative array mapping extension name to the filename where messages can be
  6488. * found. The file should contain variable assignments. Any of the variables
  6489. * present in languages/messages/MessagesEn.php may be defined, but $messages
  6490. * is the most common.
  6491. *
  6492. * Variables defined in extensions will override conflicting variables defined
  6493. * in the core.
  6494. *
  6495. * Since MediaWiki 1.23, use of this variable to define messages is discouraged; instead, store
  6496. * messages in JSON format and use $wgMessagesDirs. For setting other variables than
  6497. * $messages, $wgExtensionMessagesFiles should still be used. Use a DIFFERENT key because
  6498. * any entry having a key that also exists in $wgMessagesDirs will be ignored.
  6499. *
  6500. * Extensions using the JSON message format can preserve backward compatibility with
  6501. * earlier versions of MediaWiki by using a compatibility shim, such as one generated
  6502. * by the generateJsonI18n.php maintenance script, listing it under the SAME key
  6503. * as for the $wgMessagesDirs entry.
  6504. *
  6505. * @par Example:
  6506. * @code
  6507. * $wgExtensionMessagesFiles['ConfirmEdit'] = __DIR__.'/ConfirmEdit.i18n.php';
  6508. * @endcode
  6509. */
  6510. $wgExtensionMessagesFiles = [];
  6511. /**
  6512. * Extension messages directories.
  6513. *
  6514. * Associative array mapping extension name to the path of the directory where message files can
  6515. * be found. The message files are expected to be JSON files named for their language code, e.g.
  6516. * en.json, de.json, etc. Extensions with messages in multiple places may specify an array of
  6517. * message directories.
  6518. *
  6519. * Message directories in core should be added to LocalisationCache::getMessagesDirs()
  6520. *
  6521. * @par Simple example:
  6522. * @code
  6523. * $wgMessagesDirs['Example'] = __DIR__ . '/i18n';
  6524. * @endcode
  6525. *
  6526. * @par Complex example:
  6527. * @code
  6528. * $wgMessagesDirs['Example'] = [
  6529. * __DIR__ . '/lib/ve/i18n',
  6530. * __DIR__ . '/lib/oojs-ui/i18n',
  6531. * __DIR__ . '/i18n',
  6532. * ]
  6533. * @endcode
  6534. * @since 1.23
  6535. */
  6536. $wgMessagesDirs = [];
  6537. /**
  6538. * Array of files with list(s) of extension entry points to be used in
  6539. * maintenance/mergeMessageFileList.php
  6540. * @since 1.22
  6541. */
  6542. $wgExtensionEntryPointListFiles = [];
  6543. /**
  6544. * Parser output hooks.
  6545. * This is an associative array where the key is an extension-defined tag
  6546. * (typically the extension name), and the value is a PHP callback.
  6547. * These will be called as an OutputPageParserOutput hook, if the relevant
  6548. * tag has been registered with the parser output object.
  6549. *
  6550. * Registration is done with $pout->addOutputHook( $tag, $data ).
  6551. *
  6552. * The callback has the form:
  6553. * @code
  6554. * function outputHook( $outputPage, $parserOutput, $data ) { ... }
  6555. * @endcode
  6556. */
  6557. $wgParserOutputHooks = [];
  6558. /**
  6559. * Whether to include the NewPP limit report as a HTML comment
  6560. */
  6561. $wgEnableParserLimitReporting = true;
  6562. /**
  6563. * List of valid skin names
  6564. *
  6565. * The key should be the name in all lower case, the value should be a properly
  6566. * cased name for the skin. This value will be prefixed with "Skin" to create
  6567. * the class name of the skin to load. Use Skin::getSkinNames() as an accessor
  6568. * if you wish to have access to the full list.
  6569. */
  6570. $wgValidSkinNames = [];
  6571. /**
  6572. * Special page list. This is an associative array mapping the (canonical) names of
  6573. * special pages to either a class name to be instantiated, or a callback to use for
  6574. * creating the special page object. In both cases, the result must be an instance of
  6575. * SpecialPage.
  6576. */
  6577. $wgSpecialPages = [];
  6578. /**
  6579. * Array mapping class names to filenames, for autoloading.
  6580. */
  6581. $wgAutoloadClasses = [];
  6582. /**
  6583. * Switch controlling legacy case-insensitive classloading.
  6584. * Do not disable if your wiki must support data created by PHP4, or by
  6585. * MediaWiki 1.4 or earlier.
  6586. */
  6587. $wgAutoloadAttemptLowercase = true;
  6588. /**
  6589. * An array of information about installed extensions keyed by their type.
  6590. *
  6591. * All but 'name', 'path' and 'author' can be omitted.
  6592. *
  6593. * @code
  6594. * $wgExtensionCredits[$type][] = [
  6595. * 'path' => __FILE__,
  6596. * 'name' => 'Example extension',
  6597. * 'namemsg' => 'exampleextension-name',
  6598. * 'author' => [
  6599. * 'Foo Barstein',
  6600. * ],
  6601. * 'version' => '1.9.0',
  6602. * 'url' => 'https://example.org/example-extension/',
  6603. * 'descriptionmsg' => 'exampleextension-desc',
  6604. * 'license-name' => 'GPL-2.0-or-later',
  6605. * ];
  6606. * @endcode
  6607. *
  6608. * The extensions are listed on Special:Version. This page also looks for a file
  6609. * named COPYING or LICENSE (optional .txt extension) and provides a link to
  6610. * view said file. When the 'license-name' key is specified, this file is
  6611. * interpreted as wikitext.
  6612. *
  6613. * - $type: One of 'specialpage', 'parserhook', 'variable', 'media', 'antispam',
  6614. * 'skin', 'api', or 'other', or any additional types as specified through the
  6615. * ExtensionTypes hook as used in SpecialVersion::getExtensionTypes().
  6616. *
  6617. * - name: Name of extension as an inline string instead of localizable message.
  6618. * Do not omit this even if 'namemsg' is provided, as it is used to override
  6619. * the path Special:Version uses to find extension's license info, and is
  6620. * required for backwards-compatibility with MediaWiki 1.23 and older.
  6621. *
  6622. * - namemsg (since MW 1.24): A message key for a message containing the
  6623. * extension's name, if the name is localizable. (For example, skin names
  6624. * usually are.)
  6625. *
  6626. * - author: A string or an array of strings. Authors can be linked using
  6627. * the regular wikitext link syntax. To have an internationalized version of
  6628. * "and others" show, add an element "...". This element can also be linked,
  6629. * for instance "[https://example ...]".
  6630. *
  6631. * - descriptionmsg: A message key or an an array with message key and parameters:
  6632. * `'descriptionmsg' => 'exampleextension-desc',`
  6633. *
  6634. * - description: Description of extension as an inline string instead of
  6635. * localizable message (omit in favour of 'descriptionmsg').
  6636. *
  6637. * - license-name: Short name of the license (used as label for the link), such
  6638. * as "GPL-2.0-or-later" or "MIT" (https://spdx.org/licenses/ for a list of identifiers).
  6639. */
  6640. $wgExtensionCredits = [];
  6641. /**
  6642. * Authentication plugin.
  6643. * @var $wgAuth AuthPlugin
  6644. * @deprecated since 1.27 use $wgAuthManagerConfig instead
  6645. */
  6646. $wgAuth = null;
  6647. /**
  6648. * Global list of hooks.
  6649. *
  6650. * The key is one of the events made available by MediaWiki, you can find
  6651. * a description for most of them in docs/hooks.txt. The array is used
  6652. * internally by Hook:run().
  6653. *
  6654. * The value can be one of:
  6655. *
  6656. * - A function name:
  6657. * @code
  6658. * $wgHooks['event_name'][] = $function;
  6659. * @endcode
  6660. * - A function with some data:
  6661. * @code
  6662. * $wgHooks['event_name'][] = [ $function, $data ];
  6663. * @endcode
  6664. * - A an object method:
  6665. * @code
  6666. * $wgHooks['event_name'][] = [ $object, 'method' ];
  6667. * @endcode
  6668. * - A closure:
  6669. * @code
  6670. * $wgHooks['event_name'][] = function ( $hookParam ) {
  6671. * // Handler code goes here.
  6672. * };
  6673. * @endcode
  6674. *
  6675. * @warning You should always append to an event array or you will end up
  6676. * deleting a previous registered hook.
  6677. *
  6678. * @warning Hook handlers should be registered at file scope. Registering
  6679. * handlers after file scope can lead to unexpected results due to caching.
  6680. */
  6681. $wgHooks = [];
  6682. /**
  6683. * List of service wiring files to be loaded by the default instance of MediaWikiServices.
  6684. * Each file listed here is expected to return an associative array mapping service names
  6685. * to instantiator functions. Extensions may add wiring files to define their own services.
  6686. * However, this cannot be used to replace existing services - use the MediaWikiServices
  6687. * hook for that.
  6688. *
  6689. * @see MediaWikiServices
  6690. * @see ServiceContainer::loadWiringFiles() for details on loading service instantiator functions.
  6691. * @see docs/injection.txt for an overview of dependency injection in MediaWiki.
  6692. */
  6693. $wgServiceWiringFiles = [
  6694. __DIR__ . '/ServiceWiring.php'
  6695. ];
  6696. /**
  6697. * Maps jobs to their handlers; extensions
  6698. * can add to this to provide custom jobs.
  6699. * A job handler should either be a class name to be instantiated,
  6700. * or (since 1.30) a callback to use for creating the job object.
  6701. */
  6702. $wgJobClasses = [
  6703. 'refreshLinks' => RefreshLinksJob::class,
  6704. 'deleteLinks' => DeleteLinksJob::class,
  6705. 'htmlCacheUpdate' => HTMLCacheUpdateJob::class,
  6706. 'sendMail' => EmaillingJob::class,
  6707. 'enotifNotify' => EnotifNotifyJob::class,
  6708. 'fixDoubleRedirect' => DoubleRedirectJob::class,
  6709. 'AssembleUploadChunks' => AssembleUploadChunksJob::class,
  6710. 'PublishStashedFile' => PublishStashedFileJob::class,
  6711. 'ThumbnailRender' => ThumbnailRenderJob::class,
  6712. 'recentChangesUpdate' => RecentChangesUpdateJob::class,
  6713. 'refreshLinksPrioritized' => RefreshLinksJob::class,
  6714. 'refreshLinksDynamic' => RefreshLinksJob::class,
  6715. 'activityUpdateJob' => ActivityUpdateJob::class,
  6716. 'categoryMembershipChange' => CategoryMembershipChangeJob::class,
  6717. 'clearUserWatchlist' => ClearUserWatchlistJob::class,
  6718. 'cdnPurge' => CdnPurgeJob::class,
  6719. 'userGroupExpiry' => UserGroupExpiryJob::class,
  6720. 'clearWatchlistNotifications' => ClearWatchlistNotificationsJob::class,
  6721. 'enqueue' => EnqueueJob::class, // local queue for multi-DC setups
  6722. 'null' => NullJob::class,
  6723. ];
  6724. /**
  6725. * Jobs that must be explicitly requested, i.e. aren't run by job runners unless
  6726. * special flags are set. The values here are keys of $wgJobClasses.
  6727. *
  6728. * These can be:
  6729. * - Very long-running jobs.
  6730. * - Jobs that you would never want to run as part of a page rendering request.
  6731. * - Jobs that you want to run on specialized machines ( like transcoding, or a particular
  6732. * machine on your cluster has 'outside' web access you could restrict uploadFromUrl )
  6733. * These settings should be global to all wikis.
  6734. */
  6735. $wgJobTypesExcludedFromDefaultQueue = [ 'AssembleUploadChunks', 'PublishStashedFile' ];
  6736. /**
  6737. * Map of job types to how many job "work items" should be run per second
  6738. * on each job runner process. The meaning of "work items" varies per job,
  6739. * but typically would be something like "pages to update". A single job
  6740. * may have a variable number of work items, as is the case with batch jobs.
  6741. * This is used by runJobs.php and not jobs run via $wgJobRunRate.
  6742. * These settings should be global to all wikis.
  6743. * @var float[]
  6744. */
  6745. $wgJobBackoffThrottling = [];
  6746. /**
  6747. * Make job runners commit changes for replica DB-lag prone jobs one job at a time.
  6748. * This is useful if there are many job workers that race on replica DB lag checks.
  6749. * If set, jobs taking this many seconds of DB write time have serialized commits.
  6750. *
  6751. * Note that affected jobs may have worse lock contention. Also, if they affect
  6752. * several DBs at once they may have a smaller chance of being atomic due to the
  6753. * possibility of connection loss while queueing up to commit. Affected jobs may
  6754. * also fail due to the commit lock acquisition timeout.
  6755. *
  6756. * @var float|bool
  6757. * @since 1.26
  6758. */
  6759. $wgJobSerialCommitThreshold = false;
  6760. /**
  6761. * Map of job types to configuration arrays.
  6762. * This determines which queue class and storage system is used for each job type.
  6763. * Job types that do not have explicit configuration will use the 'default' config.
  6764. * These settings should be global to all wikis.
  6765. */
  6766. $wgJobTypeConf = [
  6767. 'default' => [ 'class' => JobQueueDB::class, 'order' => 'random', 'claimTTL' => 3600 ],
  6768. ];
  6769. /**
  6770. * Which aggregator to use for tracking which queues have jobs.
  6771. * These settings should be global to all wikis.
  6772. */
  6773. $wgJobQueueAggregator = [
  6774. 'class' => JobQueueAggregatorNull::class
  6775. ];
  6776. /**
  6777. * Whether to include the number of jobs that are queued
  6778. * for the API's maxlag parameter.
  6779. * The total number of jobs will be divided by this to get an
  6780. * estimated second of maxlag. Typically bots backoff at maxlag=5,
  6781. * so setting this to the max number of jobs that should be in your
  6782. * queue divided by 5 should have the effect of stopping bots once
  6783. * that limit is hit.
  6784. *
  6785. * @since 1.29
  6786. */
  6787. $wgJobQueueIncludeInMaxLagFactor = false;
  6788. /**
  6789. * Additional functions to be performed with updateSpecialPages.
  6790. * Expensive Querypages are already updated.
  6791. */
  6792. $wgSpecialPageCacheUpdates = [
  6793. 'Statistics' => [ SiteStatsUpdate::class, 'cacheUpdate' ]
  6794. ];
  6795. /**
  6796. * Page property link table invalidation lists. When a page property
  6797. * changes, this may require other link tables to be updated (eg
  6798. * adding __HIDDENCAT__ means the hiddencat tracking category will
  6799. * have been added, so the categorylinks table needs to be rebuilt).
  6800. * This array can be added to by extensions.
  6801. */
  6802. $wgPagePropLinkInvalidations = [
  6803. 'hiddencat' => 'categorylinks',
  6804. ];
  6805. /** @} */ # End extensions }
  6806. /*************************************************************************//**
  6807. * @name Categories
  6808. * @{
  6809. */
  6810. /**
  6811. * Use experimental, DMOZ-like category browser
  6812. */
  6813. $wgUseCategoryBrowser = false;
  6814. /**
  6815. * On category pages, show thumbnail gallery for images belonging to that
  6816. * category instead of listing them as articles.
  6817. */
  6818. $wgCategoryMagicGallery = true;
  6819. /**
  6820. * Paging limit for categories
  6821. */
  6822. $wgCategoryPagingLimit = 200;
  6823. /**
  6824. * Specify how category names should be sorted, when listed on a category page.
  6825. * A sorting scheme is also known as a collation.
  6826. *
  6827. * Available values are:
  6828. *
  6829. * - uppercase: Converts the category name to upper case, and sorts by that.
  6830. *
  6831. * - identity: Does no conversion. Sorts by binary value of the string.
  6832. *
  6833. * - uca-default: Provides access to the Unicode Collation Algorithm with
  6834. * the default element table. This is a compromise collation which sorts
  6835. * all languages in a mediocre way. However, it is better than "uppercase".
  6836. *
  6837. * To use the uca-default collation, you must have PHP's intl extension
  6838. * installed. See https://secure.php.net/manual/en/intl.setup.php . The details of the
  6839. * resulting collation will depend on the version of ICU installed on the
  6840. * server.
  6841. *
  6842. * After you change this, you must run maintenance/updateCollation.php to fix
  6843. * the sort keys in the database.
  6844. *
  6845. * Extensions can define there own collations by subclassing Collation
  6846. * and using the Collation::factory hook.
  6847. */
  6848. $wgCategoryCollation = 'uppercase';
  6849. /** @} */ # End categories }
  6850. /*************************************************************************//**
  6851. * @name Logging
  6852. * @{
  6853. */
  6854. /**
  6855. * The logging system has two levels: an event type, which describes the
  6856. * general category and can be viewed as a named subset of all logs; and
  6857. * an action, which is a specific kind of event that can exist in that
  6858. * log type.
  6859. */
  6860. $wgLogTypes = [
  6861. '',
  6862. 'block',
  6863. 'protect',
  6864. 'rights',
  6865. 'delete',
  6866. 'upload',
  6867. 'move',
  6868. 'import',
  6869. 'patrol',
  6870. 'merge',
  6871. 'suppress',
  6872. 'tag',
  6873. 'managetags',
  6874. 'contentmodel',
  6875. ];
  6876. /**
  6877. * This restricts log access to those who have a certain right
  6878. * Users without this will not see it in the option menu and can not view it
  6879. * Restricted logs are not added to recent changes
  6880. * Logs should remain non-transcludable
  6881. * Format: logtype => permissiontype
  6882. */
  6883. $wgLogRestrictions = [
  6884. 'suppress' => 'suppressionlog'
  6885. ];
  6886. /**
  6887. * Show/hide links on Special:Log will be shown for these log types.
  6888. *
  6889. * This is associative array of log type => boolean "hide by default"
  6890. *
  6891. * See $wgLogTypes for a list of available log types.
  6892. *
  6893. * @par Example:
  6894. * @code
  6895. * $wgFilterLogTypes = [ 'move' => true, 'import' => false ];
  6896. * @endcode
  6897. *
  6898. * Will display show/hide links for the move and import logs. Move logs will be
  6899. * hidden by default unless the link is clicked. Import logs will be shown by
  6900. * default, and hidden when the link is clicked.
  6901. *
  6902. * A message of the form log-show-hide-[type] should be added, and will be used
  6903. * for the link text.
  6904. */
  6905. $wgFilterLogTypes = [
  6906. 'patrol' => true,
  6907. 'tag' => true,
  6908. ];
  6909. /**
  6910. * Lists the message key string for each log type. The localized messages
  6911. * will be listed in the user interface.
  6912. *
  6913. * Extensions with custom log types may add to this array.
  6914. *
  6915. * @since 1.19, if you follow the naming convention log-name-TYPE,
  6916. * where TYPE is your log type, yoy don't need to use this array.
  6917. */
  6918. $wgLogNames = [
  6919. '' => 'all-logs-page',
  6920. 'block' => 'blocklogpage',
  6921. 'protect' => 'protectlogpage',
  6922. 'rights' => 'rightslog',
  6923. 'delete' => 'dellogpage',
  6924. 'upload' => 'uploadlogpage',
  6925. 'move' => 'movelogpage',
  6926. 'import' => 'importlogpage',
  6927. 'patrol' => 'patrol-log-page',
  6928. 'merge' => 'mergelog',
  6929. 'suppress' => 'suppressionlog',
  6930. ];
  6931. /**
  6932. * Lists the message key string for descriptive text to be shown at the
  6933. * top of each log type.
  6934. *
  6935. * Extensions with custom log types may add to this array.
  6936. *
  6937. * @since 1.19, if you follow the naming convention log-description-TYPE,
  6938. * where TYPE is your log type, yoy don't need to use this array.
  6939. */
  6940. $wgLogHeaders = [
  6941. '' => 'alllogstext',
  6942. 'block' => 'blocklogtext',
  6943. 'delete' => 'dellogpagetext',
  6944. 'import' => 'importlogpagetext',
  6945. 'merge' => 'mergelogpagetext',
  6946. 'move' => 'movelogpagetext',
  6947. 'patrol' => 'patrol-log-header',
  6948. 'protect' => 'protectlogtext',
  6949. 'rights' => 'rightslogtext',
  6950. 'suppress' => 'suppressionlogtext',
  6951. 'upload' => 'uploadlogpagetext',
  6952. ];
  6953. /**
  6954. * Lists the message key string for formatting individual events of each
  6955. * type and action when listed in the logs.
  6956. *
  6957. * Extensions with custom log types may add to this array.
  6958. */
  6959. $wgLogActions = [];
  6960. /**
  6961. * The same as above, but here values are names of classes,
  6962. * not messages.
  6963. * @see LogPage::actionText
  6964. * @see LogFormatter
  6965. */
  6966. $wgLogActionsHandlers = [
  6967. 'block/block' => BlockLogFormatter::class,
  6968. 'block/reblock' => BlockLogFormatter::class,
  6969. 'block/unblock' => BlockLogFormatter::class,
  6970. 'contentmodel/change' => ContentModelLogFormatter::class,
  6971. 'contentmodel/new' => ContentModelLogFormatter::class,
  6972. 'delete/delete' => DeleteLogFormatter::class,
  6973. 'delete/delete_redir' => DeleteLogFormatter::class,
  6974. 'delete/event' => DeleteLogFormatter::class,
  6975. 'delete/restore' => DeleteLogFormatter::class,
  6976. 'delete/revision' => DeleteLogFormatter::class,
  6977. 'import/interwiki' => ImportLogFormatter::class,
  6978. 'import/upload' => ImportLogFormatter::class,
  6979. 'managetags/activate' => LogFormatter::class,
  6980. 'managetags/create' => LogFormatter::class,
  6981. 'managetags/deactivate' => LogFormatter::class,
  6982. 'managetags/delete' => LogFormatter::class,
  6983. 'merge/merge' => MergeLogFormatter::class,
  6984. 'move/move' => MoveLogFormatter::class,
  6985. 'move/move_redir' => MoveLogFormatter::class,
  6986. 'patrol/patrol' => PatrolLogFormatter::class,
  6987. 'patrol/autopatrol' => PatrolLogFormatter::class,
  6988. 'protect/modify' => ProtectLogFormatter::class,
  6989. 'protect/move_prot' => ProtectLogFormatter::class,
  6990. 'protect/protect' => ProtectLogFormatter::class,
  6991. 'protect/unprotect' => ProtectLogFormatter::class,
  6992. 'rights/autopromote' => RightsLogFormatter::class,
  6993. 'rights/rights' => RightsLogFormatter::class,
  6994. 'suppress/block' => BlockLogFormatter::class,
  6995. 'suppress/delete' => DeleteLogFormatter::class,
  6996. 'suppress/event' => DeleteLogFormatter::class,
  6997. 'suppress/reblock' => BlockLogFormatter::class,
  6998. 'suppress/revision' => DeleteLogFormatter::class,
  6999. 'tag/update' => TagLogFormatter::class,
  7000. 'upload/overwrite' => UploadLogFormatter::class,
  7001. 'upload/revert' => UploadLogFormatter::class,
  7002. 'upload/upload' => UploadLogFormatter::class,
  7003. ];
  7004. /**
  7005. * List of log types that can be filtered by action types
  7006. *
  7007. * To each action is associated the list of log_action
  7008. * subtypes to search for, usually one, but not necessarily so
  7009. * Extensions may append to this array
  7010. * @since 1.27
  7011. */
  7012. $wgActionFilteredLogs = [
  7013. 'block' => [
  7014. 'block' => [ 'block' ],
  7015. 'reblock' => [ 'reblock' ],
  7016. 'unblock' => [ 'unblock' ],
  7017. ],
  7018. 'contentmodel' => [
  7019. 'change' => [ 'change' ],
  7020. 'new' => [ 'new' ],
  7021. ],
  7022. 'delete' => [
  7023. 'delete' => [ 'delete' ],
  7024. 'delete_redir' => [ 'delete_redir' ],
  7025. 'restore' => [ 'restore' ],
  7026. 'event' => [ 'event' ],
  7027. 'revision' => [ 'revision' ],
  7028. ],
  7029. 'import' => [
  7030. 'interwiki' => [ 'interwiki' ],
  7031. 'upload' => [ 'upload' ],
  7032. ],
  7033. 'managetags' => [
  7034. 'create' => [ 'create' ],
  7035. 'delete' => [ 'delete' ],
  7036. 'activate' => [ 'activate' ],
  7037. 'deactivate' => [ 'deactivate' ],
  7038. ],
  7039. 'move' => [
  7040. 'move' => [ 'move' ],
  7041. 'move_redir' => [ 'move_redir' ],
  7042. ],
  7043. 'newusers' => [
  7044. 'create' => [ 'create', 'newusers' ],
  7045. 'create2' => [ 'create2' ],
  7046. 'autocreate' => [ 'autocreate' ],
  7047. 'byemail' => [ 'byemail' ],
  7048. ],
  7049. 'patrol' => [
  7050. 'patrol' => [ 'patrol' ],
  7051. 'autopatrol' => [ 'autopatrol' ],
  7052. ],
  7053. 'protect' => [
  7054. 'protect' => [ 'protect' ],
  7055. 'modify' => [ 'modify' ],
  7056. 'unprotect' => [ 'unprotect' ],
  7057. 'move_prot' => [ 'move_prot' ],
  7058. ],
  7059. 'rights' => [
  7060. 'rights' => [ 'rights' ],
  7061. 'autopromote' => [ 'autopromote' ],
  7062. ],
  7063. 'suppress' => [
  7064. 'event' => [ 'event' ],
  7065. 'revision' => [ 'revision' ],
  7066. 'delete' => [ 'delete' ],
  7067. 'block' => [ 'block' ],
  7068. 'reblock' => [ 'reblock' ],
  7069. ],
  7070. 'upload' => [
  7071. 'upload' => [ 'upload' ],
  7072. 'overwrite' => [ 'overwrite' ],
  7073. ],
  7074. ];
  7075. /**
  7076. * Maintain a log of newusers at Log/newusers?
  7077. */
  7078. $wgNewUserLog = true;
  7079. /** @} */ # end logging }
  7080. /*************************************************************************//**
  7081. * @name Special pages (general and miscellaneous)
  7082. * @{
  7083. */
  7084. /**
  7085. * Allow special page inclusions such as {{Special:Allpages}}
  7086. */
  7087. $wgAllowSpecialInclusion = true;
  7088. /**
  7089. * Set this to an array of special page names to prevent
  7090. * maintenance/updateSpecialPages.php from updating those pages.
  7091. */
  7092. $wgDisableQueryPageUpdate = false;
  7093. /**
  7094. * On Special:Unusedimages, consider images "used", if they are put
  7095. * into a category. Default (false) is not to count those as used.
  7096. */
  7097. $wgCountCategorizedImagesAsUsed = false;
  7098. /**
  7099. * Maximum number of links to a redirect page listed on
  7100. * Special:Whatlinkshere/RedirectDestination
  7101. */
  7102. $wgMaxRedirectLinksRetrieved = 500;
  7103. /** @} */ # end special pages }
  7104. /*************************************************************************//**
  7105. * @name Actions
  7106. * @{
  7107. */
  7108. /**
  7109. * Array of allowed values for the "title=foo&action=<action>" parameter. Syntax is:
  7110. * 'foo' => 'ClassName' Load the specified class which subclasses Action
  7111. * 'foo' => true Load the class FooAction which subclasses Action
  7112. * If something is specified in the getActionOverrides()
  7113. * of the relevant Page object it will be used
  7114. * instead of the default class.
  7115. * 'foo' => false The action is disabled; show an error message
  7116. * Unsetting core actions will probably cause things to complain loudly.
  7117. */
  7118. $wgActions = [
  7119. 'credits' => true,
  7120. 'delete' => true,
  7121. 'edit' => true,
  7122. 'editchangetags' => SpecialPageAction::class,
  7123. 'history' => true,
  7124. 'info' => true,
  7125. 'markpatrolled' => true,
  7126. 'protect' => true,
  7127. 'purge' => true,
  7128. 'raw' => true,
  7129. 'render' => true,
  7130. 'revert' => true,
  7131. 'revisiondelete' => SpecialPageAction::class,
  7132. 'rollback' => true,
  7133. 'submit' => true,
  7134. 'unprotect' => true,
  7135. 'unwatch' => true,
  7136. 'view' => true,
  7137. 'watch' => true,
  7138. ];
  7139. /** @} */ # end actions }
  7140. /*************************************************************************//**
  7141. * @name Robot (search engine crawler) policy
  7142. * See also $wgNoFollowLinks.
  7143. * @{
  7144. */
  7145. /**
  7146. * Default robot policy. The default policy is to encourage indexing and fol-
  7147. * lowing of links. It may be overridden on a per-namespace and/or per-page
  7148. * basis.
  7149. */
  7150. $wgDefaultRobotPolicy = 'index,follow';
  7151. /**
  7152. * Robot policies per namespaces. The default policy is given above, the array
  7153. * is made of namespace constants as defined in includes/Defines.php. You can-
  7154. * not specify a different default policy for NS_SPECIAL: it is always noindex,
  7155. * nofollow. This is because a number of special pages (e.g., ListPages) have
  7156. * many permutations of options that display the same data under redundant
  7157. * URLs, so search engine spiders risk getting lost in a maze of twisty special
  7158. * pages, all alike, and never reaching your actual content.
  7159. *
  7160. * @par Example:
  7161. * @code
  7162. * $wgNamespaceRobotPolicies = [ NS_TALK => 'noindex' ];
  7163. * @endcode
  7164. */
  7165. $wgNamespaceRobotPolicies = [];
  7166. /**
  7167. * Robot policies per article. These override the per-namespace robot policies.
  7168. * Must be in the form of an array where the key part is a properly canonicalised
  7169. * text form title and the value is a robot policy.
  7170. *
  7171. * @par Example:
  7172. * @code
  7173. * $wgArticleRobotPolicies = [
  7174. * 'Main Page' => 'noindex,follow',
  7175. * 'User:Bob' => 'index,follow',
  7176. * ];
  7177. * @endcode
  7178. *
  7179. * @par Example that DOES NOT WORK because the names are not canonical text
  7180. * forms:
  7181. * @code
  7182. * $wgArticleRobotPolicies = [
  7183. * # Underscore, not space!
  7184. * 'Main_Page' => 'noindex,follow',
  7185. * # "Project", not the actual project name!
  7186. * 'Project:X' => 'index,follow',
  7187. * # Needs to be "Abc", not "abc" (unless $wgCapitalLinks is false for that namespace)!
  7188. * 'abc' => 'noindex,nofollow'
  7189. * ];
  7190. * @endcode
  7191. */
  7192. $wgArticleRobotPolicies = [];
  7193. /**
  7194. * An array of namespace keys in which the __INDEX__/__NOINDEX__ magic words
  7195. * will not function, so users can't decide whether pages in that namespace are
  7196. * indexed by search engines. If set to null, default to $wgContentNamespaces.
  7197. *
  7198. * @par Example:
  7199. * @code
  7200. * $wgExemptFromUserRobotsControl = [ NS_MAIN, NS_TALK, NS_PROJECT ];
  7201. * @endcode
  7202. */
  7203. $wgExemptFromUserRobotsControl = null;
  7204. /** @} */ # End robot policy }
  7205. /************************************************************************//**
  7206. * @name AJAX and API
  7207. * Note: The AJAX entry point which this section refers to is gradually being
  7208. * replaced by the API entry point, api.php. They are essentially equivalent.
  7209. * Both of them are used for dynamic client-side features, via XHR.
  7210. * @{
  7211. */
  7212. /**
  7213. * Enable the MediaWiki API for convenient access to
  7214. * machine-readable data via api.php
  7215. *
  7216. * See https://www.mediawiki.org/wiki/API
  7217. *
  7218. * @deprecated since 1.31
  7219. */
  7220. $wgEnableAPI = true;
  7221. /**
  7222. * Allow the API to be used to perform write operations
  7223. * (page edits, rollback, etc.) when an authorised user
  7224. * accesses it
  7225. *
  7226. * @deprecated since 1.31
  7227. */
  7228. $wgEnableWriteAPI = true;
  7229. /**
  7230. *
  7231. * WARNING: SECURITY THREAT - debug use only
  7232. *
  7233. * Disables many security checks in the API for debugging purposes.
  7234. * This flag should never be used on the production servers, as it introduces
  7235. * a number of potential security holes. Even when enabled, the validation
  7236. * will still be performed, but instead of failing, API will return a warning.
  7237. * Also, there will always be a warning notifying that this flag is set.
  7238. * At this point, the flag allows GET requests to go through for modules
  7239. * requiring POST.
  7240. *
  7241. * @since 1.21
  7242. */
  7243. $wgDebugAPI = false;
  7244. /**
  7245. * API module extensions.
  7246. *
  7247. * Associative array mapping module name to modules specs;
  7248. * Each module spec is an associative array containing at least
  7249. * the 'class' key for the module's class, and optionally a
  7250. * 'factory' key for the factory function to use for the module.
  7251. *
  7252. * That factory function will be called with two parameters,
  7253. * the parent module (an instance of ApiBase, usually ApiMain)
  7254. * and the name the module was registered under. The return
  7255. * value must be an instance of the class given in the 'class'
  7256. * field.
  7257. *
  7258. * For backward compatibility, the module spec may also be a
  7259. * simple string containing the module's class name. In that
  7260. * case, the class' constructor will be called with the parent
  7261. * module and module name as parameters, as described above.
  7262. *
  7263. * Examples for registering API modules:
  7264. *
  7265. * @code
  7266. * $wgAPIModules['foo'] = 'ApiFoo';
  7267. * $wgAPIModules['bar'] = [
  7268. * 'class' => ApiBar::class,
  7269. * 'factory' => function( $main, $name ) { ... }
  7270. * ];
  7271. * $wgAPIModules['xyzzy'] = [
  7272. * 'class' => ApiXyzzy::class,
  7273. * 'factory' => [ XyzzyFactory::class, 'newApiModule' ]
  7274. * ];
  7275. * @endcode
  7276. *
  7277. * Extension modules may override the core modules.
  7278. * See ApiMain::$Modules for a list of the core modules.
  7279. */
  7280. $wgAPIModules = [];
  7281. /**
  7282. * API format module extensions.
  7283. * Associative array mapping format module name to module specs (see $wgAPIModules).
  7284. * Extension modules may override the core modules.
  7285. *
  7286. * See ApiMain::$Formats for a list of the core format modules.
  7287. */
  7288. $wgAPIFormatModules = [];
  7289. /**
  7290. * API Query meta module extensions.
  7291. * Associative array mapping meta module name to module specs (see $wgAPIModules).
  7292. * Extension modules may override the core modules.
  7293. *
  7294. * See ApiQuery::$QueryMetaModules for a list of the core meta modules.
  7295. */
  7296. $wgAPIMetaModules = [];
  7297. /**
  7298. * API Query prop module extensions.
  7299. * Associative array mapping prop module name to module specs (see $wgAPIModules).
  7300. * Extension modules may override the core modules.
  7301. *
  7302. * See ApiQuery::$QueryPropModules for a list of the core prop modules.
  7303. */
  7304. $wgAPIPropModules = [];
  7305. /**
  7306. * API Query list module extensions.
  7307. * Associative array mapping list module name to module specs (see $wgAPIModules).
  7308. * Extension modules may override the core modules.
  7309. *
  7310. * See ApiQuery::$QueryListModules for a list of the core list modules.
  7311. */
  7312. $wgAPIListModules = [];
  7313. /**
  7314. * Maximum amount of rows to scan in a DB query in the API
  7315. * The default value is generally fine
  7316. */
  7317. $wgAPIMaxDBRows = 5000;
  7318. /**
  7319. * The maximum size (in bytes) of an API result.
  7320. * @warning Do not set this lower than $wgMaxArticleSize*1024
  7321. */
  7322. $wgAPIMaxResultSize = 8388608;
  7323. /**
  7324. * The maximum number of uncached diffs that can be retrieved in one API
  7325. * request. Set this to 0 to disable API diffs altogether
  7326. */
  7327. $wgAPIMaxUncachedDiffs = 1;
  7328. /**
  7329. * Maximum amount of DB lag on a majority of DB replica DBs to tolerate
  7330. * before forcing bots to retry any write requests via API errors.
  7331. * This should be lower than the 'max lag' value in $wgLBFactoryConf.
  7332. */
  7333. $wgAPIMaxLagThreshold = 7;
  7334. /**
  7335. * Log file or URL (TCP or UDP) to log API requests to, or false to disable
  7336. * API request logging
  7337. */
  7338. $wgAPIRequestLog = false;
  7339. /**
  7340. * Set the timeout for the API help text cache. If set to 0, caching disabled
  7341. */
  7342. $wgAPICacheHelpTimeout = 60 * 60;
  7343. /**
  7344. * The ApiQueryQueryPages module should skip pages that are redundant to true
  7345. * API queries.
  7346. */
  7347. $wgAPIUselessQueryPages = [
  7348. 'MIMEsearch', // aiprop=mime
  7349. 'LinkSearch', // list=exturlusage
  7350. 'FileDuplicateSearch', // prop=duplicatefiles
  7351. ];
  7352. /**
  7353. * Enable AJAX framework
  7354. *
  7355. * @deprecated (officially) since MediaWiki 1.31
  7356. */
  7357. $wgUseAjax = true;
  7358. /**
  7359. * List of Ajax-callable functions.
  7360. * Extensions acting as Ajax callbacks must register here
  7361. * @deprecated (officially) since 1.27; use the API instead
  7362. */
  7363. $wgAjaxExportList = [];
  7364. /**
  7365. * Enable AJAX check for file overwrite, pre-upload
  7366. */
  7367. $wgAjaxUploadDestCheck = true;
  7368. /**
  7369. * Enable previewing licences via AJAX. Also requires $wgEnableAPI to be true.
  7370. */
  7371. $wgAjaxLicensePreview = true;
  7372. /**
  7373. * Have clients send edits to be prepared when filling in edit summaries.
  7374. * This gives the server a head start on the expensive parsing operation.
  7375. */
  7376. $wgAjaxEditStash = true;
  7377. /**
  7378. * Settings for incoming cross-site AJAX requests:
  7379. * Newer browsers support cross-site AJAX when the target resource allows requests
  7380. * from the origin domain by the Access-Control-Allow-Origin header.
  7381. * This is currently only used by the API (requests to api.php)
  7382. * $wgCrossSiteAJAXdomains can be set using a wildcard syntax:
  7383. *
  7384. * - '*' matches any number of characters
  7385. * - '?' matches any 1 character
  7386. *
  7387. * @par Example:
  7388. * @code
  7389. * $wgCrossSiteAJAXdomains = [
  7390. * 'www.mediawiki.org',
  7391. * '*.wikipedia.org',
  7392. * '*.wikimedia.org',
  7393. * '*.wiktionary.org',
  7394. * ];
  7395. * @endcode
  7396. */
  7397. $wgCrossSiteAJAXdomains = [];
  7398. /**
  7399. * Domains that should not be allowed to make AJAX requests,
  7400. * even if they match one of the domains allowed by $wgCrossSiteAJAXdomains
  7401. * Uses the same syntax as $wgCrossSiteAJAXdomains
  7402. */
  7403. $wgCrossSiteAJAXdomainExceptions = [];
  7404. /** @} */ # End AJAX and API }
  7405. /************************************************************************//**
  7406. * @name Shell and process control
  7407. * @{
  7408. */
  7409. /**
  7410. * Maximum amount of virtual memory available to shell processes under linux, in KB.
  7411. */
  7412. $wgMaxShellMemory = 307200;
  7413. /**
  7414. * Maximum file size created by shell processes under linux, in KB
  7415. * ImageMagick convert for example can be fairly hungry for scratch space
  7416. */
  7417. $wgMaxShellFileSize = 102400;
  7418. /**
  7419. * Maximum CPU time in seconds for shell processes under Linux
  7420. */
  7421. $wgMaxShellTime = 180;
  7422. /**
  7423. * Maximum wall clock time (i.e. real time, of the kind the clock on the wall
  7424. * would measure) in seconds for shell processes under Linux
  7425. */
  7426. $wgMaxShellWallClockTime = 180;
  7427. /**
  7428. * Under Linux: a cgroup directory used to constrain memory usage of shell
  7429. * commands. The directory must be writable by the user which runs MediaWiki.
  7430. *
  7431. * If specified, this is used instead of ulimit, which is inaccurate, and
  7432. * causes malloc() to return NULL, which exposes bugs in C applications, making
  7433. * them segfault or deadlock.
  7434. *
  7435. * A wrapper script will create a cgroup for each shell command that runs, as
  7436. * a subgroup of the specified cgroup. If the memory limit is exceeded, the
  7437. * kernel will send a SIGKILL signal to a process in the subgroup.
  7438. *
  7439. * @par Example:
  7440. * @code
  7441. * mkdir -p /sys/fs/cgroup/memory/mediawiki
  7442. * mkdir -m 0777 /sys/fs/cgroup/memory/mediawiki/job
  7443. * echo '$wgShellCgroup = "/sys/fs/cgroup/memory/mediawiki/job";' >> LocalSettings.php
  7444. * @endcode
  7445. *
  7446. * The reliability of cgroup cleanup can be improved by installing a
  7447. * notify_on_release script in the root cgroup, see e.g.
  7448. * https://gerrit.wikimedia.org/r/#/c/40784
  7449. */
  7450. $wgShellCgroup = false;
  7451. /**
  7452. * Executable path of the PHP cli binary. Should be set up on install.
  7453. */
  7454. $wgPhpCli = '/usr/bin/php';
  7455. /**
  7456. * Locale for LC_ALL, to provide a known environment for locale-sensitive operations
  7457. *
  7458. * For Unix-like operating systems, this should be set to C.UTF-8 or an
  7459. * equivalent to provide the most consistent behavior for locale-sensitive
  7460. * C library operations across different-language wikis. If that locale is not
  7461. * available, use another locale that has a UTF-8 character set.
  7462. *
  7463. * This setting mainly affects the behavior of C library functions, including:
  7464. * - String collation (order when sorting using locale-sensitive comparison)
  7465. * - For example, whether "Å" and "A" are considered to be the same letter or
  7466. * different letters and if different whether it comes after "A" or after
  7467. * "Z", and whether sorting is case sensitive.
  7468. * - String character set (how characters beyond basic ASCII are represented)
  7469. * - We need this to be a UTF-8 character set to work around
  7470. * https://bugs.php.net/bug.php?id=45132
  7471. * - Language used for low-level error messages.
  7472. * - Formatting of date/time and numeric values (e.g. '.' versus ',' as the
  7473. * decimal separator)
  7474. *
  7475. * MediaWiki provides its own methods and classes to perform many
  7476. * locale-sensitive operations, which are designed to be able to vary locale
  7477. * based on wiki language or user preference:
  7478. * - MediaWiki's Collation class should generally be used instead of the C
  7479. * library collation functions when locale-sensitive sorting is needed.
  7480. * - MediaWiki's Message class should be used for localization of messages
  7481. * displayed to the user.
  7482. * - MediaWiki's Language class should be used for formatting numeric and
  7483. * date/time values.
  7484. *
  7485. * @note If multiple wikis are being served from the same process (e.g. the
  7486. * same fastCGI or Apache server), this setting must be the same on all those
  7487. * wikis.
  7488. */
  7489. $wgShellLocale = 'C.UTF-8';
  7490. /**
  7491. * Method to use to restrict shell commands
  7492. *
  7493. * Supported options:
  7494. * - 'autodetect': Autodetect if any restriction methods are available
  7495. * - 'firejail': Use firejail <https://firejail.wordpress.com/>
  7496. * - false: Don't use any restrictions
  7497. *
  7498. * @note If using firejail with MediaWiki running in a home directory different
  7499. * from the webserver user, firejail 0.9.44+ is required.
  7500. *
  7501. * @since 1.31
  7502. * @var string|bool
  7503. */
  7504. $wgShellRestrictionMethod = false;
  7505. /** @} */ # End shell }
  7506. /************************************************************************//**
  7507. * @name HTTP client
  7508. * @{
  7509. */
  7510. /**
  7511. * Timeout for HTTP requests done internally, in seconds.
  7512. * @var int
  7513. */
  7514. $wgHTTPTimeout = 25;
  7515. /**
  7516. * Timeout for HTTP requests done internally for transwiki imports, in seconds.
  7517. * @since 1.29
  7518. */
  7519. $wgHTTPImportTimeout = 25;
  7520. /**
  7521. * Timeout for Asynchronous (background) HTTP requests, in seconds.
  7522. */
  7523. $wgAsyncHTTPTimeout = 25;
  7524. /**
  7525. * Proxy to use for CURL requests.
  7526. */
  7527. $wgHTTPProxy = false;
  7528. /**
  7529. * Local virtual hosts.
  7530. *
  7531. * This lists domains that are configured as virtual hosts on the same machine.
  7532. *
  7533. * This affects the following:
  7534. * - MWHttpRequest: If a request is to be made to a domain listed here, or any
  7535. * subdomain thereof, then no proxy will be used.
  7536. * Command-line scripts are not affected by this setting and will always use
  7537. * the proxy if it is configured.
  7538. *
  7539. * @since 1.25
  7540. */
  7541. $wgLocalVirtualHosts = [];
  7542. /**
  7543. * Timeout for connections done internally (in seconds)
  7544. * Only works for curl
  7545. */
  7546. $wgHTTPConnectTimeout = 5e0;
  7547. /** @} */ # End HTTP client }
  7548. /************************************************************************//**
  7549. * @name Job queue
  7550. * @{
  7551. */
  7552. /**
  7553. * Number of jobs to perform per request. May be less than one in which case
  7554. * jobs are performed probabalistically. If this is zero, jobs will not be done
  7555. * during ordinary apache requests. In this case, maintenance/runJobs.php should
  7556. * be run periodically.
  7557. */
  7558. $wgJobRunRate = 1;
  7559. /**
  7560. * When $wgJobRunRate > 0, try to run jobs asynchronously, spawning a new process
  7561. * to handle the job execution, instead of blocking the request until the job
  7562. * execution finishes.
  7563. *
  7564. * @since 1.23
  7565. */
  7566. $wgRunJobsAsync = false;
  7567. /**
  7568. * Number of rows to update per job
  7569. */
  7570. $wgUpdateRowsPerJob = 300;
  7571. /**
  7572. * Number of rows to update per query
  7573. */
  7574. $wgUpdateRowsPerQuery = 100;
  7575. /** @} */ # End job queue }
  7576. /************************************************************************//**
  7577. * @name Miscellaneous
  7578. * @{
  7579. */
  7580. /**
  7581. * Name of the external diff engine to use. Supported values:
  7582. * * string: path to an external diff executable
  7583. * * false: wikidiff2 PHP/HHVM module if installed, otherwise the default PHP implementation
  7584. * * 'wikidiff', 'wikidiff2', and 'wikidiff3' are treated as false for backwards compatibility
  7585. */
  7586. $wgExternalDiffEngine = false;
  7587. /**
  7588. * wikidiff2 supports detection of changes in moved paragraphs.
  7589. * This setting controls the maximum number of paragraphs to compare before it bails out.
  7590. * Supported values:
  7591. * * 0: detection of moved paragraphs is disabled
  7592. * * int > 0: maximum number of paragraphs to compare
  7593. * Note: number of paragraph comparisons is in O(n^2).
  7594. * This setting is only effective if the wikidiff2 PHP/HHVM module is used as diffengine.
  7595. * See $wgExternalDiffEngine.
  7596. *
  7597. * @since 1.30
  7598. */
  7599. $wgWikiDiff2MovedParagraphDetectionCutoff = 0;
  7600. /**
  7601. * Disable redirects to special pages and interwiki redirects, which use a 302
  7602. * and have no "redirected from" link.
  7603. *
  7604. * @note This is only for articles with #REDIRECT in them. URL's containing a
  7605. * local interwiki prefix (or a non-canonical special page name) are still hard
  7606. * redirected regardless of this setting.
  7607. */
  7608. $wgDisableHardRedirects = false;
  7609. /**
  7610. * LinkHolderArray batch size
  7611. * For debugging
  7612. */
  7613. $wgLinkHolderBatchSize = 1000;
  7614. /**
  7615. * By default MediaWiki does not register links pointing to same server in
  7616. * externallinks dataset, use this value to override:
  7617. */
  7618. $wgRegisterInternalExternals = false;
  7619. /**
  7620. * Maximum number of pages to move at once when moving subpages with a page.
  7621. */
  7622. $wgMaximumMovedPages = 100;
  7623. /**
  7624. * Fix double redirects after a page move.
  7625. * Tends to conflict with page move vandalism, use only on a private wiki.
  7626. */
  7627. $wgFixDoubleRedirects = false;
  7628. /**
  7629. * Allow redirection to another page when a user logs in.
  7630. * To enable, set to a string like 'Main Page'
  7631. */
  7632. $wgRedirectOnLogin = null;
  7633. /**
  7634. * Configuration for processing pool control, for use in high-traffic wikis.
  7635. * An implementation is provided in the PoolCounter extension.
  7636. *
  7637. * This configuration array maps pool types to an associative array. The only
  7638. * defined key in the associative array is "class", which gives the class name.
  7639. * The remaining elements are passed through to the class as constructor
  7640. * parameters.
  7641. *
  7642. * @par Example using local redis instance:
  7643. * @code
  7644. * $wgPoolCounterConf = [ 'ArticleView' => [
  7645. * 'class' => PoolCounterRedis::class,
  7646. * 'timeout' => 15, // wait timeout in seconds
  7647. * 'workers' => 1, // maximum number of active threads in each pool
  7648. * 'maxqueue' => 5, // maximum number of total threads in each pool
  7649. * 'servers' => [ '127.0.0.1' ],
  7650. * 'redisConfig' => []
  7651. * ] ];
  7652. * @endcode
  7653. *
  7654. * @par Example using C daemon from https://www.mediawiki.org/wiki/Extension:PoolCounter:
  7655. * @code
  7656. * $wgPoolCounterConf = [ 'ArticleView' => [
  7657. * 'class' => PoolCounter_Client::class,
  7658. * 'timeout' => 15, // wait timeout in seconds
  7659. * 'workers' => 5, // maximum number of active threads in each pool
  7660. * 'maxqueue' => 50, // maximum number of total threads in each pool
  7661. * ... any extension-specific options...
  7662. * ] ];
  7663. * @endcode
  7664. */
  7665. $wgPoolCounterConf = null;
  7666. /**
  7667. * To disable file delete/restore temporarily
  7668. */
  7669. $wgUploadMaintenance = false;
  7670. /**
  7671. * Associative array mapping namespace IDs to the name of the content model pages in that namespace
  7672. * should have by default (use the CONTENT_MODEL_XXX constants). If no special content type is
  7673. * defined for a given namespace, pages in that namespace will use the CONTENT_MODEL_WIKITEXT
  7674. * (except for the special case of JS and CS pages).
  7675. *
  7676. * @since 1.21
  7677. */
  7678. $wgNamespaceContentModels = [];
  7679. /**
  7680. * How to react if a plain text version of a non-text Content object is requested using
  7681. * ContentHandler::getContentText():
  7682. *
  7683. * * 'ignore': return null
  7684. * * 'fail': throw an MWException
  7685. * * 'serialize': serialize to default format
  7686. *
  7687. * @since 1.21
  7688. */
  7689. $wgContentHandlerTextFallback = 'ignore';
  7690. /**
  7691. * Set to false to disable use of the database fields introduced by the ContentHandler facility.
  7692. * This way, the ContentHandler facility can be used without any additional information in the
  7693. * database. A page's content model is then derived solely from the page's title. This however
  7694. * means that changing a page's default model (e.g. using $wgNamespaceContentModels) will break
  7695. * the page and/or make the content inaccessible. This also means that pages can not be moved to
  7696. * a title that would default to a different content model.
  7697. *
  7698. * Overall, with $wgContentHandlerUseDB = false, no database updates are needed, but content
  7699. * handling is less robust and less flexible.
  7700. *
  7701. * @since 1.21
  7702. */
  7703. $wgContentHandlerUseDB = true;
  7704. /**
  7705. * Determines which types of text are parsed as wikitext. This does not imply that these kinds
  7706. * of texts are also rendered as wikitext, it only means that links, magic words, etc will have
  7707. * the effect on the database they would have on a wikitext page.
  7708. *
  7709. * @todo On the long run, it would be nice to put categories etc into a separate structure,
  7710. * or at least parse only the contents of comments in the scripts.
  7711. *
  7712. * @since 1.21
  7713. */
  7714. $wgTextModelsToParse = [
  7715. CONTENT_MODEL_WIKITEXT, // Just for completeness, wikitext will always be parsed.
  7716. CONTENT_MODEL_JAVASCRIPT, // Make categories etc work, people put them into comments.
  7717. CONTENT_MODEL_CSS, // Make categories etc work, people put them into comments.
  7718. ];
  7719. /**
  7720. * Register handlers for specific types of sites.
  7721. *
  7722. * @since 1.20
  7723. */
  7724. $wgSiteTypes = [
  7725. 'mediawiki' => MediaWikiSite::class,
  7726. ];
  7727. /**
  7728. * Whether the page_props table has a pp_sortkey column. Set to false in case
  7729. * the respective database schema change was not applied.
  7730. * @since 1.23
  7731. */
  7732. $wgPagePropsHaveSortkey = true;
  7733. /**
  7734. * Port where you have HTTPS running
  7735. * Supports HTTPS on non-standard ports
  7736. * @see T67184
  7737. * @since 1.24
  7738. */
  7739. $wgHttpsPort = 443;
  7740. /**
  7741. * Secret for session storage.
  7742. * This should be set in LocalSettings.php, otherwise wgSecretKey will
  7743. * be used.
  7744. * @since 1.27
  7745. */
  7746. $wgSessionSecret = false;
  7747. /**
  7748. * If for some reason you can't install the PHP OpenSSL or mcrypt extensions,
  7749. * you can set this to true to make MediaWiki work again at the cost of storing
  7750. * sensitive session data insecurely. But it would be much more secure to just
  7751. * install the OpenSSL extension.
  7752. * @since 1.27
  7753. */
  7754. $wgSessionInsecureSecrets = false;
  7755. /**
  7756. * Secret for hmac-based key derivation function (fast,
  7757. * cryptographically secure random numbers).
  7758. * This should be set in LocalSettings.php, otherwise wgSecretKey will
  7759. * be used.
  7760. * See also: $wgHKDFAlgorithm
  7761. * @since 1.24
  7762. */
  7763. $wgHKDFSecret = false;
  7764. /**
  7765. * Algorithm for hmac-based key derivation function (fast,
  7766. * cryptographically secure random numbers).
  7767. * See also: $wgHKDFSecret
  7768. * @since 1.24
  7769. */
  7770. $wgHKDFAlgorithm = 'sha256';
  7771. /**
  7772. * Enable page language feature
  7773. * Allows setting page language in database
  7774. * @var bool
  7775. * @since 1.24
  7776. */
  7777. $wgPageLanguageUseDB = false;
  7778. /**
  7779. * Global configuration variable for Virtual REST Services.
  7780. *
  7781. * Use the 'path' key to define automatically mounted services. The value for this
  7782. * key is a map of path prefixes to service configuration. The latter is an array of:
  7783. * - class : the fully qualified class name
  7784. * - options : map of arguments to the class constructor
  7785. * Such services will be available to handle queries under their path from the VRS
  7786. * singleton, e.g. MediaWikiServices::getInstance()->getVirtualRESTServiceClient();
  7787. *
  7788. * Auto-mounting example for Parsoid:
  7789. *
  7790. * $wgVirtualRestConfig['paths']['/parsoid/'] = [
  7791. * 'class' => ParsoidVirtualRESTService::class,
  7792. * 'options' => [
  7793. * 'url' => 'http://localhost:8000',
  7794. * 'prefix' => 'enwiki',
  7795. * 'domain' => 'en.wikipedia.org'
  7796. * ]
  7797. * ];
  7798. *
  7799. * Parameters for different services can also be declared inside the 'modules' value,
  7800. * which is to be treated as an associative array. The parameters in 'global' will be
  7801. * merged with service-specific ones. The result will then be passed to
  7802. * VirtualRESTService::__construct() in the module.
  7803. *
  7804. * Example config for Parsoid:
  7805. *
  7806. * $wgVirtualRestConfig['modules']['parsoid'] = [
  7807. * 'url' => 'http://localhost:8000',
  7808. * 'prefix' => 'enwiki',
  7809. * 'domain' => 'en.wikipedia.org',
  7810. * ];
  7811. *
  7812. * @var array
  7813. * @since 1.25
  7814. */
  7815. $wgVirtualRestConfig = [
  7816. 'paths' => [],
  7817. 'modules' => [],
  7818. 'global' => [
  7819. # Timeout in seconds
  7820. 'timeout' => 360,
  7821. # 'domain' is set to $wgCanonicalServer in Setup.php
  7822. 'forwardCookies' => false,
  7823. 'HTTPProxy' => null
  7824. ]
  7825. ];
  7826. /**
  7827. * Controls whether zero-result search queries with suggestions should display results for
  7828. * these suggestions.
  7829. *
  7830. * @var bool
  7831. * @since 1.26
  7832. */
  7833. $wgSearchRunSuggestedQuery = true;
  7834. /**
  7835. * Where popular password file is located.
  7836. *
  7837. * Default in core contains 10,000 most popular. This config
  7838. * allows you to change which file, in case you want to generate
  7839. * a password file with > 10000 entries in it.
  7840. *
  7841. * @see maintenance/createCommonPasswordCdb.php
  7842. * @since 1.27
  7843. * @var string path to file
  7844. */
  7845. $wgPopularPasswordFile = __DIR__ . '/../serialized/commonpasswords.cdb';
  7846. /*
  7847. * Max time (in seconds) a user-generated transaction can spend in writes.
  7848. * If exceeded, the transaction is rolled back with an error instead of being committed.
  7849. *
  7850. * @var int|bool Disabled if false
  7851. * @since 1.27
  7852. */
  7853. $wgMaxUserDBWriteDuration = false;
  7854. /*
  7855. * Max time (in seconds) a job-generated transaction can spend in writes.
  7856. * If exceeded, the transaction is rolled back with an error instead of being committed.
  7857. *
  7858. * @var int|bool Disabled if false
  7859. * @since 1.30
  7860. */
  7861. $wgMaxJobDBWriteDuration = false;
  7862. /**
  7863. * Mapping of event channels (or channel categories) to EventRelayer configuration.
  7864. *
  7865. * By setting up a PubSub system (like Kafka) and enabling a corresponding EventRelayer class
  7866. * that uses it, MediaWiki can broadcast events to all subscribers. Certain features like WAN
  7867. * cache purging and CDN cache purging will emit events to this system. Appropriate listers can
  7868. * subscribe to the channel and take actions based on the events. For example, a local daemon
  7869. * can run on each CDN cache node and perfom local purges based on the URL purge channel events.
  7870. *
  7871. * Some extensions may want to use "channel categories" so that different channels can also share
  7872. * the same custom relayer instance (e.g. when it's likely to be overriden). They can use
  7873. * EventRelayerGroup::getRelayer() based on the category but call notify() on various different
  7874. * actual channels. One reason for this would be that some system have very different performance
  7875. * vs durability needs, so one system (e.g. Kafka) may not be suitable for all uses.
  7876. *
  7877. * The 'default' key is for all channels (or channel categories) without an explicit entry here.
  7878. *
  7879. * @since 1.27
  7880. */
  7881. $wgEventRelayerConfig = [
  7882. 'default' => [
  7883. 'class' => EventRelayerNull::class,
  7884. ]
  7885. ];
  7886. /**
  7887. * Share data about this installation with MediaWiki developers
  7888. *
  7889. * When set to true, MediaWiki will periodically ping https://www.mediawiki.org/ with basic
  7890. * data about this MediaWiki instance. This data includes, for example, the type of system,
  7891. * PHP version, and chosen database backend. The Wikimedia Foundation shares this data with
  7892. * MediaWiki developers to help guide future development efforts.
  7893. *
  7894. * For details about what data is sent, see: https://www.mediawiki.org/wiki/Manual:$wgPingback
  7895. *
  7896. * @var bool
  7897. * @since 1.28
  7898. */
  7899. $wgPingback = false;
  7900. /**
  7901. * List of urls which appear often to be triggering CSP reports
  7902. * but do not appear to be caused by actual content, but by client
  7903. * software inserting scripts (i.e. Ad-Ware).
  7904. * List based on results from Wikimedia logs.
  7905. *
  7906. * @since 1.28
  7907. */
  7908. $wgCSPFalsePositiveUrls = [
  7909. 'https://3hub.co' => true,
  7910. 'https://morepro.info' => true,
  7911. 'https://p.ato.mx' => true,
  7912. 'https://s.ato.mx' => true,
  7913. 'https://adserver.adtech.de' => true,
  7914. 'https://ums.adtechus.com' => true,
  7915. 'https://cas.criteo.com' => true,
  7916. 'https://cat.nl.eu.criteo.com' => true,
  7917. 'https://atpixel.alephd.com' => true,
  7918. 'https://rtb.metrigo.com' => true,
  7919. 'https://d5p.de17a.com' => true,
  7920. 'https://ad.lkqd.net/vpaid/vpaid.js' => true,
  7921. ];
  7922. /**
  7923. * Shortest CIDR limits that can be checked in any individual range check
  7924. * at Special:Contributions.
  7925. *
  7926. * @var array
  7927. * @since 1.30
  7928. */
  7929. $wgRangeContributionsCIDRLimit = [
  7930. 'IPv4' => 16,
  7931. 'IPv6' => 32,
  7932. ];
  7933. /**
  7934. * The following variables define 3 user experience levels:
  7935. *
  7936. * - newcomer: has not yet reached the 'learner' level
  7937. *
  7938. * - learner: has at least $wgLearnerEdits and has been
  7939. * a member for $wgLearnerMemberSince days
  7940. * but has not yet reached the 'experienced' level.
  7941. *
  7942. * - experienced: has at least $wgExperiencedUserEdits edits and
  7943. * has been a member for $wgExperiencedUserMemberSince days.
  7944. */
  7945. $wgLearnerEdits = 10;
  7946. $wgLearnerMemberSince = 4; # days
  7947. $wgExperiencedUserEdits = 500;
  7948. $wgExperiencedUserMemberSince = 30; # days
  7949. /**
  7950. * Mapping of interwiki index prefixes to descriptors that
  7951. * can be used to change the display of interwiki search results.
  7952. *
  7953. * Descriptors are appended to CSS classes of interwiki results
  7954. * which using InterwikiSearchResultWidget.
  7955. *
  7956. * Predefined descriptors include the following words:
  7957. * definition, textbook, news, quotation, book, travel, course
  7958. *
  7959. * @par Example:
  7960. * @code
  7961. * $wgInterwikiPrefixDisplayTypes = [
  7962. * 'iwprefix' => 'definition'
  7963. *];
  7964. * @endcode
  7965. */
  7966. $wgInterwikiPrefixDisplayTypes = [];
  7967. /**
  7968. * Comment table schema migration stage.
  7969. * @since 1.30
  7970. * @var int One of the MIGRATION_* constants
  7971. */
  7972. $wgCommentTableSchemaMigrationStage = MIGRATION_OLD;
  7973. /**
  7974. * Actor table schema migration stage.
  7975. * @since 1.31
  7976. * @var int One of the MIGRATION_* constants
  7977. */
  7978. $wgActorTableSchemaMigrationStage = MIGRATION_OLD;
  7979. /**
  7980. * For really cool vim folding this needs to be at the end:
  7981. * vim: foldmarker=@{,@} foldmethod=marker
  7982. * @}
  7983. */