Issues (2)

Security Analysis    no request data  

This project does not seem to handle request data directly as such no vulnerable execution paths were found.

  Cross-Site Scripting
Cross-Site Scripting enables an attacker to inject code into the response of a web-request that is viewed by other users. It can for example be used to bypass access controls, or even to take over other users' accounts.
  File Exposure
File Exposure allows an attacker to gain access to local files that he should not be able to access. These files can for example include database credentials, or other configuration files.
  File Manipulation
File Manipulation enables an attacker to write custom data to files. This potentially leads to injection of arbitrary code on the server.
  Object Injection
Object Injection enables an attacker to inject an object into PHP code, and can lead to arbitrary code execution, file exposure, or file manipulation attacks.
  Code Injection
Code Injection enables an attacker to execute arbitrary code on the server.
  Response Splitting
Response Splitting can be used to send arbitrary responses.
  File Inclusion
File Inclusion enables an attacker to inject custom files into PHP's file loading mechanism, either explicitly passed to include, or for example via PHP's auto-loading mechanism.
  Command Injection
Command Injection enables an attacker to inject a shell command that is execute with the privileges of the web-server. This can be used to expose sensitive data, or gain access of your server.
  SQL Injection
SQL Injection enables an attacker to execute arbitrary SQL code on your database server gaining access to user data, or manipulating user data.
  XPath Injection
XPath Injection enables an attacker to modify the parts of XML document that are read. If that XML document is for example used for authentication, this can lead to further vulnerabilities similar to SQL Injection.
  LDAP Injection
LDAP Injection enables an attacker to inject LDAP statements potentially granting permission to run unauthorized queries, or modify content inside the LDAP tree.
  Header Injection
  Other Vulnerability
This category comprises other attack vectors such as manipulating the PHP runtime, loading custom extensions, freezing the runtime, or similar.
  Regex Injection
Regex Injection enables an attacker to execute arbitrary code in your PHP process.
  XML Injection
XML Injection enables an attacker to read files on your local filesystem including configuration files, or can be abused to freeze your web-server process.
  Variable Injection
Variable Injection enables an attacker to overwrite program variables with custom data, and can lead to further vulnerabilities.
Unfortunately, the security analysis is currently not available for your project. If you are a non-commercial open-source project, please contact support to gain access.

src/BankName.php (1 issue)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
3
4
namespace Sco\Bankcard;
5
6
class BankName
7
{
8
    protected static $bankLists = [
9
        // alipay
10
        'HDBANK'    => '邯郸银行',
11
        'BSB'       => '包商银行',
12
        'JSB'       => '晋商银行',
13
        'BOCD'      => '承德银行',
14
        'GSRCU'     => '甘肃省农村信用',
15
        'COMM'      => '交通银行',
16
        'SRCB'      => '深圳农村商业银行',
17
        'ZBCB'      => '齐商银行',
18
        'QLBANK'    => '齐鲁银行',
19
        'GDRCC'     => '广东省农村信用社联合社',
20
        'TCRCB'     => '江苏太仓农村商业银行',
21
        'HRXJB'     => '华融湘江银行',
22
        'CZRCB'     => '常州农村信用联社',
23
        'NCB'       => '南昌银行',
24
        'SHRCB'     => '上海农村商业银行',
25
        'ABC'       => '中国农业银行',
26
        'HSBANK'    => '徽商银行',
27
        'SPDB'      => '上海浦东发展银行',
28
        'DYCB'      => '德阳商业银行',
29
        'WRCB'      => '无锡农村商业银行',
30
        'JJBANK'    => '九江银行',
31
        'BJBANK'    => '北京银行',
32
        'CGNB'      => '南充市商业银行',
33
        'CITIC'     => '中信银行',
34
        'HBC'       => '湖北银行',
35
        'FDB'       => '富滇银行',
36
        'URMQCCB'   => '乌鲁木齐市商业银行',
37
        'CMB'       => '招商银行',
38
        'CCQTGB'    => '重庆三峡银行',
39
        'XYBANK'    => '信阳银行',
40
        'WZCB'      => '温州银行',
41
        'H3CB'      => '内蒙古银行',
42
        'CEB'       => '中国光大银行',
43
        'LYCB'      => '辽阳市商业银行',
44
        'CZCB'      => '浙江稠州商业银行',
45
        'NBBANK'    => '宁波银行',
46
        'NHQS'      => '农信银清算中心',
47
        'XABANK'    => '西安银行',
48
        'HZCB'      => '杭州银行',
49
        'BOQH'      => '青海银行',
50
        'DAQINGB'   => '龙江银行',
51
        'ZZBANK'    => '郑州银行',
52
        'KSRB'      => '昆山农村商业银行',
53
        'BANKWF'    => '潍坊银行',
54
        'HURCB'     => '湖北省农村信用社',
55
        'CCB'       => '中国建设银行',
56
        'YDRCB'     => '尧都农商行',
57
        'HSBK'      => '衡水银行',
58
        'BOD'       => '东莞银行',
59
        'BHB'       => '河北银行',
60
        'SXCB'      => '绍兴银行',
61
        'NHB'       => '南海农村信用联社',
62
        'JZBANK'    => '晋中市商业银行',
63
        'DYCCB'     => '东营市商业银行',
64
        'ORBANK'    => '鄂尔多斯银行',
65
        'BOHAIB'    => '渤海银行',
66
        'ZGCCB'     => '自贡市商业银行',
67
        'XCYH'      => '许昌银行',
68
        'ZJTLCB'    => '浙江泰隆商业银行',
69
        'YXCCB'     => '玉溪市商业银行',
70
        'WHRCB'     => '武汉农村商业银行',
71
        'JHBANK'    => '金华银行',
72
        'NYNB'      => '广东南粤银行',
73
        'SRBANK'    => '上饶银行',
74
        'NBYZ'      => '鄞州银行',
75
        'JRCB'      => '江苏江阴农村商业银行',
76
        'LYBANK'    => '洛阳银行',
77
        'XTB'       => '邢台银行',
78
        'CIB'       => '兴业银行',
79
        'XXBANK'    => '新乡银行',
80
        'TACCB'     => '泰安市商业银行',
81
        'CDB'       => '国家开发银行',
82
        'TZCB'      => '台州银行',
83
        'DRCBCL'    => '东莞农村商业银行',
84
        'JSBANK'    => '江苏银行',
85
        'BOZK'      => '周口银行',
86
        'CSRCB'     => '常熟农村商业银行',
87
        'CMBC'      => '中国民生银行',
88
        'YBCCB'     => '宜宾市商业银行',
89
        'YNRCC'     => '云南省农村信用社',
90
        'ICBC'      => '中国工商银行',
91
        'BOCY'      => '朝阳银行',
92
        'CDRCB'     => '成都农商银行',
93
        'HANABANK'  => '韩亚银行',
94
        'LSBC'      => '临商银行',
95
        'JXRCU'     => '江西省农村信用',
96
        'GRCB'      => '广州农商银行',
97
        'GLBANK'    => '桂林银行',
98
        'ZJNX'      => '浙江省农村信用社联合社',
99
        'TRCB'      => '天津农商银行',
100
        'HZCCB'     => '湖州市商业银行',
101
        'BZMD'      => '驻马店银行',
102
        'CQBANK'    => '重庆银行',
103
        'DZBANK'    => '德州银行',
104
        'BJRCB'     => '北京农村商业银行',
105
        'GXRCU'     => '广西省农村信用',
106
        'XLBANK'    => '中山小榄村镇银行',
107
        'WJRCB'     => '吴江农商银行',
108
        'ZJKCCB'    => '张家口市商业银行',
109
        'SPABANK'   => '平安银行',
110
        'WHCCB'     => '威海市商业银行',
111
        'BOYK'      => '营口银行',
112
        'SDEB'      => '顺德农商银行',
113
        'CDCB'      => '成都银行',
114
        'JNBANK'    => '济宁银行',
115
        'HBYCBANK'  => '湖北银行宜昌分行',
116
        'ZYCBANK'   => '遵义市商业银行',
117
        'TCCB'      => '天津银行',
118
        'MTBANK'    => '浙江民泰商业银行',
119
        'FXCB'      => '阜新银行',
120
        'FSCB'      => '抚顺银行',
121
        'SDRCU'     => '山东农信',
122
        'HNRCC'     => '湖南省农村信用社',
123
        'QDCCB'     => '青岛银行',
124
        'HKBEA'     => '东亚银行',
125
        'SHBANK'    => '上海银行',
126
        'CZBANK'    => '浙商银行',
127
        'LSCCB'     => '乐山市商业银行',
128
        'NXBANK'    => '宁夏银行',
129
        'GZRCU'     => '贵州省农村信用社',
130
        'GYCB'      => '贵阳市商业银行',
131
        'LZYH'      => '兰州银行',
132
        'SCRCU'     => '四川省农村信用',
133
        'CBKF'      => '开封市商业银行',
134
        'JINCHB'    => '晋城银行JCBANK',
135
        'LANGFB'    => '廊坊银行',
136
        'BOSZ'      => '苏州银行',
137
        'HKB'       => '汉口银行',
138
        'BOP'       => '平顶山银行',
139
        'AYCB'      => '安阳银行',
140
        'HNRCU'     => '河南省农村信用',
141
        'HXBANK'    => '华夏银行',
142
        'BOJZ'      => '锦州银行',
143
        'GCB'       => '广州银行',
144
        'GZB'       => '赣州银行',
145
        'ARCU'      => '安徽省农村信用社',
146
        'EGBANK'    => '恒丰银行',
147
        'CSCB'      => '长沙银行',
148
        'NJCB'      => '南京银行',
149
        'SJBANK'    => '盛京银行',
150
        'SXRCCU'    => '陕西信合',
151
        'JLRCU'     => '吉林农信',
152
        'HBRCU'     => '河北省农村信用社',
153
        'KLB'       => '昆仑银行',
154
        'SZSBK'     => '石嘴山银行',
155
        'DLB'       => '大连银行',
156
        'SCCB'      => '三门峡银行',
157
        'JSRCU'     => '江苏省农村信用联合社',
158
        'ZRCBANK'   => '张家港农村商业银行',
159
        'LSBANK'    => '莱商银行',
160
        'FJHXBC'    => '福建海峡银行',
161
        'NXRCU'     => '宁夏黄河农村商业银行',
162
        'CBBQS'     => '城市商业银行资金清算中心',
163
        'KORLABANK' => '库尔勒市商业银行',
164
        'GDB'       => '广东发展银行',
165
        'BOC'       => '中国银行',
166
        'ASCB'      => '鞍山银行',
167
        'BGB'       => '广西北部湾银行',
168
        'PSBC'      => '中国邮政储蓄银行',
169
        'BODD'      => '丹东银行',
170
        'CRCBANK'   => '重庆农村商业银行',
171
        'JXBANK'    => '嘉兴银行',
172
        'JLBANK'    => '吉林银行',
173
        'HBHSBANK'  => '湖北银行黄石分行',
174
        'YQCCB'     => '阳泉银行',
175
176
        // 补充
177
        'HSBC'      => '汇丰银行',
178
        'SCB'       => '渣打银行',
179
        'CITI'      => '花旗银行',
180
        'GHB'       => '广东华兴银行',
181
        'DSB'       => '大新银行',
182
        'WHB'       => '永亨银行',
183
        'DBS'       => '星展银行香港有限公司',
184
        'XMBANK'    => '厦门银行',
185
        'HRBANK'    => '哈尔滨银行',
186
        'QHDCCB'    => '秦皇岛市商业银行',
187
        'BOQZ'      => '泉州银行',
188
        'ZJQL'      => '浙江泰隆商业银行',
189
        'FJNX'      => '福建省农村信用社联合社',
190
        'SLH'       => '湖南农村信用社联合社',
191
        'JXNCX'     => '江西省农村信用社联合社',
192
        'SCBBANK'   => '商丘市商业银行',
193
        'CQNCSYCZ'  => '重庆南川石银村镇银行',
194
        'LPRDNCXYS' => '临汾市尧都区农村信用合作联社',
195
        'LZCCB'     => '柳州银行',
196
        'WHSYBANK'  => '威海市商业银行',
197
        'HZBANK'    => '湖州银行',
198
        'RZGWYBANK' => '日照银行',
199
        'QSBANK'    => '齐商银行',
200
        'RBOZ'      => '珠海华润银行',
201
        'HLDCCB'    => '葫芦岛市商业银行',
202
        'LYB'       => '洛阳银行',
203
        'JZCBANK'   => '焦作市商业银行',
204
        'ZJCCB'     => '镇江市商业银行',
205
        'FGXYBANK'  => '法国兴业银行',
206
        'DYBANK'    => '大华银行',
207
        'DIYEBANK'  => '企业银行',
208
        'HQBANK'    => '华侨银行',
209
        'HSB'       => '恒生银行',
210
        'LSB'       => '临沂商业银行',
211
        'YTCB'      => '烟台商业银行',
212
        'QLB'       => '齐鲁银行',
213
        'BCCC'      => 'BC卡公司',
214
        'CYB'       => '集友银行',
215
        'TFB'       => '大丰银行',
216
        'AEON'      => 'AEON信贷财务亚洲有限公司',
217
        'MABDA'     => '澳门BDA',
218
219
    ];
220
221 View Code Duplication
    public static function get($bankCode = null, $default = null)
0 ignored issues
show
This method seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
222
    {
223
        if (is_null($bankCode)) {
224
            return self::$bankLists;
225
        }
226
227
        return isset(self::$bankLists[$bankCode]) ? self::$bankLists[$bankCode] : $default;
228
    }
229
}
230