Issues (2687)

Security Analysis    not enabled

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/Eccube/Service/OrderService.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
 * This file is part of EC-CUBE
4
 *
5
 * Copyright(c) 2000-2015 LOCKON CO.,LTD. All Rights Reserved.
6
 *
7
 * http://www.lockon.co.jp/
8
 *
9
 * This program is free software; you can redistribute it and/or
10
 * modify it under the terms of the GNU General Public License
11
 * as published by the Free Software Foundation; either version 2
12
 * of the License, or (at your option) any later version.
13
 *
14
 * This program is distributed in the hope that it will be useful,
15
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17
 * GNU General Public License for more details.
18
 *
19
 * You should have received a copy of the GNU General Public License
20
 * along with this program; if not, write to the Free Software
21
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22
 */
23
24
namespace Eccube\Service;
25
26
use Eccube\Application;
27
use Eccube\Entity\Cart;
28
use Eccube\Entity\Customer;
29
use Eccube\Entity\Order;
30
31
/**
32
 * @deprecated since 3.0.0, to be removed in 3.1
33
 */
34
class OrderService
35
{
36
    /** @var \Eccube\Application */
37
    public $app;
38
39
    public function __construct(Application $app)
0 ignored issues
show
Missing function doc comment
Loading history...
40
    {
41
        $this->app = $app;
42
    }
43
44
    /**
45
     * 合計数量を取得
46
     *
47
     * @param Order $Order
48
     * @return int
49
     * @deprecated since 3.0.0, to be removed in 3.1
50
     */
51
    public function getTotalQuantity(Order $Order)
52
    {
53
        return $Order->calculateTotalQuantity();
54
    }
55
56
    /**
57
     * 小計を取得
58
     *
59
     * @param Order $Order
60
     * @return int
61
     * @deprecated since 3.0.0, to be removed in 3.1
62
     */
63
    public function getSubTotal(Order $Order)
64
    {
65
        return $Order->calculateSubTotal();
66
    }
67
68
    /**
69
     * 消費税のみの小計を取得
70
     *
71
     * @param Order $Order
72
     * @return int
73
     * @deprecated since 3.0.0, to be removed in 3.1
74
     */
75
    public function getTotalTax(Order $Order)
76
    {
77
        return $Order->calculateTotalTax();
78
    }
79
80
    /**
81
     * 商品種別を取得
82
     *
83
     * @param Order $Order
84
     * @return array
85
     * @deprecated since 3.0.0, to be removed in 3.1
86
     */
87
    public function getProductTypes(Order $Order)
88
    {
89
        return $Order->getProductTypes();
90
    }
91
92
    /**
93
     * 下位互換用関数
94
     *
95
     * @return Order
96
     *
97
     * @see ShoppingService::newOrder()
98
     *
99
     * @deprecated since 3.0.0, to be removed in 3.1
100
     */
101
    public function newOrder()
102
    {
103
        return $this->app['eccube.service.shopping']->newOrder();
104
    }
105
106
    /**
107
     * 下位互換用関数
108
     *
109
     * @param $cartItems
110
     * @param Customer|null $Customer
111
     * @param $preOrderId
112
     * @return Order
113
     *
114
     * @see ShoppingService::createOrder()
115
     *
116
     * @deprecated since 3.0.0, to be removed in 3.1
117
     */
118
    public function registerPreOrderFromCartItems($cartItems, Customer $Customer = null, $preOrderId)
119
    {
120
        return $this->app['eccube.service.shopping']->createOrder($Customer);
121
    }
122
123
    /**
124
     * 下位互換用関数
125
     *
126
     * @param Order $Order
127
     * @param Cart $Cart
128
     * @return Order
129
     *
130
     * @see ShoppingService::getAmount()
131
     *
132
     * @deprecated since 3.0.0, to be removed in 3.1
133
     */
134
    public function getAmount(Order $Order, Cart $Cart)
135
    {
136
        return $this->app['eccube.service.shopping']->getAmount($Order);
137
    }
138
139
    /**
140
     * 下位互換用関数
141
     *
142
     * @param $em トランザクション制御されているEntityManager
143
     * @param Order $Order 受注情報
144
     * @return bool true : 成功、false : 失敗
145
     *
146
     * @see ShoppingService::isOrderProduct()
147
     *
148
     * @deprecated since 3.0.0, to be removed in 3.1
149
     */
150
    public function isOrderProduct($em, Order $Order)
151
    {
152
        return $this->app['eccube.service.shopping']->isOrderProduct($em, $Order);
153
    }
154
155
    /**
156
     * 下位互換用関数
157
     *
158
     * @param $em トランザクション制御されているEntityManager
159
     * @param Order $Order 受注情報
160
     * @param $formData フォームデータ
161
     *
162
     * @see ShoppingService::setOrderUpdate()
163
     *
164
     * @deprecated since 3.0.0, to be removed in 3.1
165
     */
166
    public function setOrderUpdate($em, Order $Order, $formData)
167
    {
168
        $this->app['eccube.service.shopping']->setOrderUpdate($Order, $formData);
169
    }
170
171
    /**
172
     * 下位互換用関数
173
     *
174
     * @param $em トランザクション制御されているEntityManager
175
     * @param Order $Order 受注情報
176
     *
177
     * @see ShoppingService::setStockUpdate()
178
     *
179
     * @deprecated since 3.0.0, to be removed in 3.1
180
     */
181
    public function setStockUpdate($em, Order $Order)
182
    {
183
        $this->app['eccube.service.shopping']->setStockUpdate($em, $Order);
184
    }
185
186
    /**
187
     * 下位互換用関数
188
     *
189
     * @param $em トランザクション制御されているEntityManager
190
     * @param Order $Order 受注情報
191
     * @param Customer $user ログインユーザ
192
     *
193
     * @see ShoppingService::setCustomerUpdate()
194
     *
195
     * @deprecated since 3.0.0, to be removed in 3.1
196
     */
197
    public function setCustomerUpdate($em, Order $Order, Customer $user)
198
    {
199
        $this->app['eccube.service.shopping']->setCustomerUpdate($Order, $user);
200
    }
201
202
203
}
204