微赞开发有感

微赞的功能很棒,但是看了部分源码后,发现一些问题。

先说下目录结构

http://域名/app/index.php?i=7&c=entry&m=ewei_shopv2&do=mobile&r=goods.detail&id=148&mid=388&from=groupmessage

如上

app表示是根目录下的app目录,这里的东西大多是和手机端有关

i=7应该是表示第7个公众号

c=entry表示要加载东西了。

defined('IN_IA') or exit('Access Denied');
load()->model('module');

$eid = intval($_GPC['eid']);
if(!empty($eid)) {
    $entry = module_entry($eid);
} else {
    $entry = array(
        'module' => $_GPC['m'],
        'do' => $_GPC['do'],
        'state' => $_GPC['state'],
        'direct' => 0
    );
}
$moduels = uni_modules();
if (empty($moduels[$entry['module']])) {
    message('您访问的功能模块不存在,请重新进入');
}
if(empty($entry) || empty($entry['do'])) {
    message('非法访问.');
}
$_GPC['__entry'] = $entry['title'];
$_GPC['__state'] = $entry['state'];
$_GPC['state'] = $entry['state'];
$_GPC['m'] = $entry['module'];
$_GPC['do'] = $entry['do'];

define('IN_MODULE', $entry['module']);
$_W['current_module'] = $moduels[$entry['module']];
$site = WeUtility::createModuleSite($entry['module']);
if(!is_error($site)) {
    $method = 'doMobile' . ucfirst($entry['do']);
    exit($site->$method());
}
exit();

这个的最后是表示要加载什么

http://域名/app/index.php?i=7&c=entry&m=ewei_shopv2&do=mobile&r=goods.detail&id=148&mid=388&from=groupmessage

会找到addons下ewei_shopv2下的mobile的good中的detail

至于后面就是页面的具体参数

这个是按这么来的,但是我缺在上述查找中发现找到的页面不对。。。。

而且ewei_shopv2的php源码是加密的。。。。

js

也找到这种

eval(function(p, a, c, k, e, d) {
    e = function(c) {
        return c.toString(36)
    };
    if (!''.replace(/^/, String)) {
        while (c--) {
            d[c.toString(a)] = k[c] || c.toString(a)
        }
        k = [function(e) {
            return d[e]
        }];
        e = function() {
            return '\\w+'
        };
        c = 1
    };
    while (c--) {
        if (k[c]) {
            p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c])
        }
    }
    return p
}('a([\'0\',\'8\'],1(0,8){b 2={};2.c=1(6){0.e("d/f",{3:6.3},1(7){$("#5").4(\'.q-n-g\').o();$("#5").4(\'9\').p(\'m\',7.l.9).h()},i,j)};k 2});', 27, 27, 'core|function|modal|goodsid|find|posterimg|params|ret|tpl|img|define|var|init|commission|json|qrcode|group|show|false|true|return|result|src|cell|remove|attr|fui'.split('|'), 0, {}));

这个解压后的,但是是加密的。。。。

define(['core', 'tpl'], function(core, tpl) {
    var modal = {};
    modal.init = function(params) {
        core.json("commission/qrcode", {
            goodsid: params.goodsid
        }, function(ret) {
            $("#posterimg").find('.fui-cell-group').remove();
            $("#posterimg").find('img').attr('src', ret.result.img).show()
        }, false, true)
    };
    return modal
});

解压后。。。。。

可以看出

微赞这个源码的管控是多么的。。。。。

可以自行百度js eval解密

 

转载于:https://www.cnblogs.com/lmaster/p/7062088.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值