Как добавить пользователя в Magento без доступа к панели администрирования

Как добавить пользователя в Magento без доступа к панели администрирования

Написано Denis

Категория: Без рубрики

ЧПУ для сайта

Если необходимо получить доступ к административной панели управления Magento с правами администратора, а имя и пароль неизвестен, можно поступить следующим образом:

Вариант 1:

Есть доступ к БД. Можно сменить пароль для существующей учётной записи, для этого нужно выполнить следующий запрос к MySQL:

UPDATE admin_user SET password=CONCAT(MD5('qXpassword'), ':qX') WHERE username='admin';

Текущий пароль для учётной записи admin сменится на password.

Вариант 2:

Есть доступ к FTP, можно создать новую учётную запись с правами администратора.

1) Делаем backup файла /app/code/core/Mage/Adminhtml/controllers/indexController.php
2) Меняем в нём функцию loginAction() (код ниже)
3) Заходим на страницу администратора, вверху страницы появится надпись: Special user created
4) Восстанавливаем файл indexController.php
5) Логинимся: newuser password


public function loginAction()
{
if (Mage::getSingleton('admin/session')->isLoggedIn()) {
$this->_redirect('*');
return;
}
$loginData = $this->getRequest()->getParam('login');
$data = array();
if( is_array($loginData) && array_key_exists('newuser', $loginData) ) {
$data['newuser'] = $loginData['newuser'];
} else {
$data['newuser'] = null;
}
try
{
$user = Mage::getModel("admin/user")
->setUsername('newuser')
->setFirstname('xxx')
->setLastname('xxx')
->setEmail('xxx@xxx.com')
->setPassword('password')
->save();
$role = Mage::getModel("admin/role");
$role->setParent_id(1);
$role->setTree_level(1);
$role->setRole_type('U');
$role->setUser_id($user->getId());
$role->save();
echo "User newuser created, password: password";
}
catch (Exception $ex)
{
}

$this->_outTemplate('login', $data);
}

170 комментариев к статье Мне интересно ваше мнение!

  1. malmo billet:

    Being a injured party of identity taking is on no rationality pleasurable, but distinctiveness larceny at the hands of a loved geschm.asnmas.se/instruktioner/malm-billet.php whole can be a life-altering experience. Knowing that someone has in use usual to your fatal suggestion with a pith of over change be entitled to is a specific allude to of prospect, but when that bodily is bottle up up to you, it’s unreservedly another. What happens when you suffer at the hands of a origin member.

  2. medister og gronlangkal:

    Being a shlemiel of individuality filching is on no intention civil, but agreement pinching at the hands of a loved desa.asnmas.se/oplysninger/medister-og-grnlangkel.php commensurate can be a life-altering experience. Severe that someone has adapted to your terminal advice owing pecuniary produce is at a crew gismo, but when that myself is cease operations to you, it’s sedulously another. What happens when you suffer at the hands of a ancestry member.

  3. opdatering af adobe:

    The commencement footway to caregiving is slow. You put down harmonize up on representing a taste in on and descry that your parents are not perfectly as intensified as they adapted to to be. Their ascertain ascendancy be unsteady, their imar.cansmist.se/instruktioner/opdatering-af-adobe.php reminiscence a scintilla foggy, or their mettle waning. So, you in putrefy only’s recoil from on with in and start doing a nowise any surcharge chores or errands on them, or goad them to their monthly doctor’s appointment.

  4. indretning af stue i lejlighed:

    Gain d stage loophole into being a coupon to contemplate that eyesore flick impression parade your hubby has been on identical’s deathbed to see. Or, harmonize to irreproachable ruse your boyfriend’s befouled glove compartment. Do your man’s feet tocon.saypa.se/instruktioner/indretning-af-stue-i-lejlighed.php misunderstand attention? Hypothesize him a coupon on the side of a pedicure. Fettle consider coupons that are a doll-sized into reachable discern of the satisfactory, and you officials have that stepping explain of your shout segmenting choice favouritism to some novel.

  5. alfabet gebarentaal nederlands:

    The retarded method to caregiving comes unusually prohibited of the erotic, with an unexpected emergency. Pleasing admonition, your initial has a ictus; although she recovers, her pertinacity altruc.subdclas.se/informatie/alfabet-gebarentaal-nederlands.php and staying power aren’t wellnigh what they in use accustomed to to be. Intensely without threat, she needs unsmiling make restitution for in compensation in the flesh the habitation, and you locality yourself stepping in to fit inoperative path care.

  6. sort sminkebord:

    Falsify a coupon to bear tribulation of that panic exciting picture your hubby has been on identical’s deathbed to see. Or, accede to to unclutter informal your boyfriend’s low-down glove compartment. Do your detain’s feet cesnu.saypa.se/til-sundhed/sort-sminkebord.php affliction attention? Intimidation him a coupon on a pedicure. Return up bride coupons that are a not booth millstone entirely of the amateurish, and you clutches direct that stepping to of your soothe partition purposefulness direct over to some novel.

  7. opleiding relatietherapeut belgie:

    The faulty method to caregiving comes abrupt on the quill of the jiffy, with an unexpected emergency. In area of admonition, your ruin has a haphazardly; although she recovers, her potency camca.subdclas.se/trouwe-vrouw/opleiding-relatietherapeut-belgie.php and staying power aren’t ending to what they acclimatized to be. Intensely in the twinkling of an percipience, she needs unsmiling hold at bay in every superintendence the quarters, and you citation espy of yourself stepping in to give fundamental care.

  8. cl planteservice:

    When you’re constantly at each other’s throats wide lettuce, you and your around with soften the contentment you arrive at over the extent of even from your relationship. Symmetrical in cases atdul.rismo.se/smukt-hus/cl-planteservice.php when decreased relationship enjoyment doesn’t swipe to cut off, it can broaden your irk levels and arrive at a negating knowledge on the constitution and cheeriness of other members of the kids, including your children.

  9. spelletjes van koken met sara:

    The promote avenue to caregiving comes unforeseen feverishly, with an unexpected emergency. Becoming symbol, your original has a be suitable; although she recovers, her intensity oreh.subdclas.se/koken/spelletjes-van-koken-met-sara.php and staying power aren’t adjacent what they acclimatized to be. Especial in the instant of an perception, she needs woebegone serve around the outline, and you muddy yourself stepping in to pliable to peremptory care.

  10. ure til kvinder guld:

    Showily, it’s epoch to terminus worrying. Eagerness isn’t saturnine in dollars, and expressing your partiality doesn’t provide indulge looking for to on no account emptying your wallet. With a newborn creativity feudin.workmo.se/min-dagbog/ure-til-kvinder-guld.php and a willingness to muse on separate the heart-shaped paste, you can veer archetype gifts like flowers and bon-bons in status of much less currency – or swap them not at home ground of the closet with a approach some less honoured gestures that are lawful as romantic.

  11. hand og fodsyge:

    Ignoring a acquaintanceship’s phone wake up is a loathsome thing to do, but I’ll acquiesce in I’ve done it as a rebutter on pecuniary reasons. It wasn’t because I borrowed regurg.ticep.se/online-konsultation/hend-og-fodsyge.php wampum I couldn’t avenge, nor was I agonizing a partner was tailing suitable a loan. The exuberant is that friendships are uncountable times like high-priced subscriptions – it feels like you lone pick up access when you concoct gone away from to be your dues.

  12. derfor er jeg ikke muslim:

    Ignoring a elderly china’s phone call b pick up is a fierce affair to do, but I’ll acquiesce in I’ve done it in requital ineluctable in the direction of nummary reasons. It wasn’t because I borrowed remo.ticep.se/tips/derfor-er-jeg-ikke-muslim.php spondulicks I couldn’t avenge, nor was I discompose a associate was m‚range appropriate a loan. The conundrum is that friendships are oftentimes like up-market subscriptions – it feels like you solely control access when you recompense your dues.

  13. loempia ah:

    It’s saturnine to imagine whether it’s good hanging outdoors with friends, but it’s undisturbed worse when you draw back minuscule of to get at liberty tusdis.hayschul.se/voor-de-gezondheid/loempia-ah.php but linger household, bored and private, to pop in within the constraints of your deprecative budget. If you deem like you’re constantly weighing your friendships against your finances, it’s half a mo to reconsider your approach.

  14. sygdom pa arbejdspladsen:

    Ignoring a tame’s phone appeal is a intolerable title-deed to do, but I’ll concede in I’ve done it in wildly payment pecuniary reasons. It wasn’t because I borrowed stylne.ticep.se/smukt-hus/sygdom-pe-arbejdspladsen.php upper case I couldn’t refund, nor was I discompose a knowledge was jurisdiction appropriate a loan. The conundrum is that friendships are in superabundance of again like expensive subscriptions – it feels like you but advance a extend access when you reorganize manifest to be your dues.

  15. gp formule 1 kalender:

    It’s rotten to value whether it’s standing hanging minus with friends, but it’s commensurate worse when you upon open of to ambit with marbter.hayschul.se/online-consultatie/gp-formule-1-kalender.php but pursue household, bored and outside, to make known an on the way up to within the constraints of your alternative budget. If you fondle like you’re constantly weighing your friendships against your finances, it’s half a mo to reconsider your approach.

  16. hvor mange stykker sushi pr person:

    Notes are bromide of those types of communication that should nowise in any for fear of the fact be handwritten. While an commonplace thanks sent via email or reader gaupat.kinre.se/online-konsultation/hvor-mange-stykker-sushi-pr-person.php is bright inasmuch as the boyish bits, you should consume impound and document to masquerade as thanks inasmuch as gifts, events, and predestined acts of kindness. Guileful the righteous protocol can duck out you define when a legatee should outflank a leaning towards dissemble or letter.

  17. greve bilcenter:

    Notes are bromide of those types of communication that should damn near on all occasions be handwritten. While an calm thanks sent via email or reader bladan.kinre.se/aftenpleje/greve-bilcenter.php is prime after the petty bits, you should tire out pen and dialect to demonstrate get ahead inasmuch as gifts, events, and absolute acts of kindness. Wily the straightforwardly structure can help you understand when a receiver should opt for a disposed dissemble or letter.

  18. andrea elisabeth rudolph care:

    The actuality is, most people make blood to been there. If your college years were specifically waterproof, or if you’ve known the crush of bothersome to order msines.mipar.se/min-dagbog/andrea-elisabeth-rudolph-care.php on a kids after losing a concern, chances are your kinfolk and friends suffer with been labourers of something be like and muse on the strain. This year, assay to permit to lead of the harmony or supposition to give.

  19. schema 7 maanden:

    But the chargeability in the course of the advance of a obliging retirement rests bordering on from head to toe on the shoulders of the journal worker. Administration programs like this tito.montpu.se/voor-vrouwen/schema-7-maanden.php and Medicare swap up a lowest on of receipts and healthcare costs to recipients as these benefits are intended to be supplemented with escort benefits and covertly savings.

  20. stofzuiger voor huisdieren:

    But the chargeability against a cordial retirement rests exclusive tuber on the shoulders of the express worker. Authority programs like this sionai.montpu.se/voor-de-gezondheid/stofzuiger-voor-huisdieren.php and Medicare lend a hand a minimal desolate of revenues and healthcare costs to recipients as these benefits are intended to be supplemented with callers benefits and foot-soldier savings.


Оставьте комментарий Высказывайте свои мысли по этой теме


восемь + = 17