GithubHelp home page GithubHelp logo

zerodream-cn / sakurapanel Goto Github PK

View Code? Open in Web Editor NEW
791.0 791.0 308.0 15 MB

樱花内网穿透网站源代码,2020 重制版

Home Page: https://sakuracloud.cn/

License: Other

PHP 99.15% Hack 0.01% SCSS 0.68% Less 0.17%

sakurapanel's People

Contributors

daiyangcheng avatar kasuganosoras avatar skipm4 avatar znc15 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sakurapanel's Issues

关于面板Api请求Invalid Node ID的问题

问题如题
数据库,api配置都正常
后台也可以正确获取到服务器信息
但是Frpc客户端连接不上
Frps版本为樱花28.2定制版
Frpc是官方最新版
frps后台报错
client login info: ip [X.XX.XXX.XX:4411] version [0.29.0] hostname [] os [windows] arch [386]
2021/01/10 12:01:04 [W] [service.go:301] SakuraFrp API Error (Status: 403, Text: 403 Invalid Node ID)
2021/01/10 12:01:05 [D] [service.go:344] Accept new mux stream error: EOF

请问此程序支不支持STARTTLS 587

在放行了 465 587 之后
并为网站权限设置全目录下 www 755

465 587 没有被使用
在配置文件中尝试如下填写方式

/* 是否启用 */ 'enable'    => true,
	/* 主机地址 */ 'host'      => 'ssl://smtp.office365.com',
	/* 主机端口 */ 'port'      => 587,
	/* 发信账号 */ 'user'      => '[email protected]',
	/* 发信密码 */ 'pass'      => '**********',
	/* 发信邮箱 */ 'mail'      => '[email protected]'
),

/* 是否启用 */ 'enable'    => true,
	/* 主机地址 */ 'host'      => 'tls://smtp.office365.com',
	/* 主机端口 */ 'port'      => 465,
	/* 发信账号 */ 'user'      => '[email protected]',
	/* 发信密码 */ 'pass'      => '**********',
	/* 发信邮箱 */ 'mail'      => '[email protected]'
),
	/* 是否启用 */ 'enable'    => true,
	/* 主机地址 */ 'host'      => 'starttls//smtp.office365.com',
	/* 主机端口 */ 'port'      => 587,
	/* 发信账号 */ 'user'      => '[email protected]',
	/* 发信密码 */ 'pass'      => '**********',
	/* 发信邮箱 */ 'mail'      => '[email protected]'
),
/* 是否启用 */ 'enable'    => true,
	/* 主机地址 */ 'host'      => 'tls://smtp.office365.com',
	/* 主机端口 */ 'port'      => 587,
	/* 发信账号 */ 'user'      => '[email protected]',
	/* 发信密码 */ 'pass'      => '**********',
	/* 发信邮箱 */ 'mail'      => '[email protected]'
),
/* 是否启用 */ 'enable'    => true,
	/* 主机地址 */ 'host'      => 'ssl://smtp.office365.com',
	/* 主机端口 */ 'port'      => 465,
	/* 发信账号 */ 'user'      => '[email protected]',
	/* 发信密码 */ 'pass'      => '**********',
	/* 发信邮箱 */ 'mail'      => '[email protected]'
),

都无效 无法发送邮件 是什么问题 发件邮件DKIM SPF DMARC均有效 https://mail-tester.com/test-20paui22l 为满分

反馈关于节点服务器导致配置文件出现“Array”

在优化网站源码访问速度的时候,不经意添加后删除节点服务器,再次添加配置文件显示“Array” 如图报错

原因是数据库的“nodes”表id字段值是3(前面两次记录已删),将id 3更改为id 1配置文件就正常!

问题复现:删除nodes数据表里面的前几个记录,保留最后一个记录问题复现

关于本项目

由于 Sakura Frp 已经转让,本项目是将老 Sakura Frp 部分代码开源,算是为开源做一些贡献吧。因此本项目如果不是出现安全问题/漏洞基本上不会再更新了,如有需要可以自行二次开发。

对于一些想将本项目用于商业使用或者获得有偿技术支持的用户:请加 QQ 群 478112133 和我联系,只需要几餐饭钱,你就可以将本面板用于商业使用,并且我会提供额外的技术支持,解答各类问题。同时也可以看情况接二次开发定制需求,加群后建议在群里 @ 我,私聊有时候看不到。

转行做游戏了,此项目已经停止维护,想商用就直接用吧,不要用于违法用途就好,关于面板的安装和使用有不明白的可以加群 478112133 在群里问,但我平时比较忙不一定能看到,随缘解答。

邮箱发送不了

不仅邮箱,添加隧道后在添加节点界面无显示服务器(与用户组设置无关)

邮箱和验证码问题

1验证码问题
使用v3验证码会显示角标但是报错
用v2验证码显示角标除了v2隐藏版也是报错
2邮箱问题
使用smtp时候用ssl无法发送
25和465端口都无法使用
本人使用邮箱QQ和阿里云企业邮箱

后端节点和用户流量,带宽速率等问题

大佬,您好,我是V1.0.1版本,面板运行正常,可以正常穿透,但是无论节点带宽多大,用户带宽怎么调,还是只有100kb/s-500kb/s。还有就是,流量消耗统计始终为0,节点隐藏禁用后,用户还可以看到,使用和创建隧道。禁用用户后,用户还是能正常使用。不知是哪问题,我的环境配置为:Nginx 1.16.0,MySQL 5.6.44,PHP-7.3。

什么都设置好了 客户端和服务端都是28.2版本 但是连接时提示Invalid Node ID

root@aml:~# ./frpc1 -c ./frpc1.ini
2021/01/27 03:19:21 [E] [service.go:218] SakuraFrp API Error (Status: 403, Text: 403 Invalid Node ID)
2021/01/27 03:19:21 [W] [service.go:82] login to server failed: SakuraFrp API Error (Status: 403, Text: 403 Invalid Node ID)
SakuraFrp API Error (Status: 403, Text: 403 Invalid Node ID)
以上就是详细客户端输出
frps.log日志是
2021/01/27 11:30:04 [I] [service.go:359] client login info: ip [111.9.238.23:14565] version [0.28.2] hostname [] os [linux] arch [arm]
2021/01/27 11:30:04 [W] [service.go:301] SakuraFrp API Error (Status: 403, Text: 403 Invalid Node ID)
2021/01/27 11:30:04 [D] [service.go:344] Accept new mux stream error: EOF
2021/01/27 11:30:06 [I] [service.go:359] client login info: ip [111.9.238.23:14567] version [0.28.2] hostname [] os [linux] arch [arm]
2021/01/27 11:30:06 [W] [service.go:301] SakuraFrp API Error (Status: 403, Text: 403 Invalid Node ID)
2021/01/27 11:30:06 [D] [service.go:344] Accept new mux stream error: EOF
2021/01/27 11:30:09 [I] [service.go:359] client login info: ip [111.9.238.23:14569] version [0.28.2] hostname [] os [linux] arch [arm]
2021/01/27 11:30:09 [W] [service.go:301] SakuraFrp API Error (Status: 403, Text: 403 Invalid Node ID)
2021/01/27 11:30:09 [D] [service.go:344] Accept new mux stream error: EOF

感谢回复

Possible XSS vulnerability

Hello,

I would like to report for XSS vulnerability.

In file https://github.com/ZeroDream-CN/SakuraPanel/blob/master/core/PostHandler.php

line 87

$result = $pm->checkRules($_POST);

In function checkRules

public function checkRules($data)
{
                // ....
		if($this->isProxyNameExist($data['proxy_name'])) {
			return Array(false, "隧� {$data['proxy_name']} 已存在,请使用其他�字");
		}
               // ....
}

line 96

$msg = $result[1] ?? "未知错误";
exit($msg);

exit will terminate the script and print the message which have the value $data['proxy_name']. Then there is XSS vulnerability

STCP映射隧道 start error: SakuraFrp API Error (Status: 404, Text: 404 Proxy not found)

问题描述

启动STCP隧道后返回404错误

截图示列

QQ浏览器截图20201114212603.png
QQ浏览器截图20201114212457.png

配置文件(已经删去部分敏感内容)

frps

[common]
# Frp 绑定地址,默认 0.0.0.0 无需修改
bind_addr = 0.0.0.0

# Frp 运行端口
bind_port = 30003

# Kcp 模式运行端口,需要和上面的相同
kcp_bind_port = 30003

# 管理端口,默认 8233
dashboard_port = 

# 管理用户名,必须是 admin
dashboard_user = admin

# 管理密码
dashboard_pwd = 

# HTTP 映射端口
vhost_http_port = 80

# HTTPS 映射端口
vhost_https_port = 443

# Frp 服务器日志
# log_file = ./frps.log

# Frp Token 特权密码
token = 

# UDP 穿透端口
bind_udp_port = 7001

# 以下项目无需修改
max_pool_count = 50
tcp_mux = true
authentication_timeout = 0
log_level = debug
log_max_days = 3

# 是否启用 Api 功能
api_enable = true

# Api 服务器地址
api_baseurl = http://网址已经去除/api/

# Api 密码
api_token = 

frpc

[common]
server_addr = 
server_port = 30003
tcp_mux = true
protocol = tcp
user =
token = 
dns_server = 114.114.114.114
 
[AliyunRdp]
privilege_mode = true
type = tcp
local_ip = 127.0.0.1
local_port = 3389
remote_port = 
use_encryption = true
use_compression = true

[StcpAliyunMysql]
privilege_mode = true
type = stcp
local_ip = 127.0.0.1
local_port = 3306
sk = 
use_encryption = true
use_compression = true
 

由于这部分相关的内容在网上几乎找不到,所以我认为这是个bug将其提交上来

如果这是由于我的疏忽导致配置文件错误导致的,还麻烦请您指出错误,我对此深感抱歉

此外,普通的TCP映射的使用时一切正常的,所以应该可以排除大部分运行时的意外故障

如果需要服务器的相应日志,请回复我,我会尽快将其通过合适的方式发送给您

服务端启动报错“ invalid character '<' looking for beginning of value”

报错信息

2020/06/23 19:05:21 [I] [service.go:149] frps tcp listen on 0.0.0.0:2333
2020/06/23 19:05:21 [I] [service.go:191] http service listen on 0.0.0.0:8880
2020/06/23 19:05:21 [I] [service.go:212] https service listen on 0.0.0.0:8443
2020/06/23 19:05:21 [I] [service.go:242] Dashboard listen on 0.0.0.0:8233
2020/06/23 19:05:21 [I] [root.go:204] Start frps success
2020/06/23 19:05:26 [I] [service.go:359] client login info: ip [192.168.2.1:13083] version [0.28.2] hostname [] os [windows] arch [amd64]
2020/06/23 19:05:26 [W] [service.go:301] invalid character '<' looking for beginning of value
2020/06/23 19:05:26 [D] [service.go:344] Accept new mux stream error: EOF

客户端和服务端都重编译过,一样报错。
在ubuntu18.04和Windows10 部署frps均是一样报错
也排除因修改网站设置问题(原封不动的源码)。
客户端可以正常使用natfrp网站上的配置文件

403 Invalid API Token

login to server failed: SakuraFrp API Error (Status: 403, Text: 403 Invalid API Token)
SakuraFrp API Error (Status: 403, Text: 403 Invalid API Token)
请问怎么回事呢

你好 一种隧道穿透报错

在使用配套服务端的时候 使用xtcp(p2p)隧道 客户端在启动的时候会出现
CD23A5A4-FB7E-4992-BDA8-5C5F22A97A9C
这样 原版frp 和 sakurafrp 则是正常的
请求支持

启动内网穿透错误

主控被控都装好,但被控端无法根据面板设置开启穿透

感谢作者的开源共享,知道项目已经停止更新,但是还是想咨询一下。

被控端启动好,看日志运行全都是200 :

2022/01/16 00:21:13 [I] [dashboard_api.go:173] Http request: [/api/proxy/tcp]
2022/01/16 00:21:13 [I] [dashboard_api.go:167] Http response [/api/proxy/tcp]: code [200]

主控端也能检测到节点信息,没有报错。但是添加好穿透后,被控端无任何反映,依旧200。

意思是无论添加什么穿透,节点都没反应,无法实现穿透。

api疑问

有没有api可以实现像樱花一样有个key就可以获取隧道

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.