Bitcoin Forum

Bitcoin => Project Development => Topic started by: simplecoin on June 07, 2011, 09:03:26 PM



Title: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on June 07, 2011, 09:03:26 PM
Simplecoin web mining framework

(Initially a fork of Xenland's Mining Pool v1) (http://forum.bitcoin.org/index.php?topic=10617.0)

Features:
  • Proportional or PPLastNShares
  • Instant or Automatic cashout available with positive balance!
  • Worker monitor for less downtime
  • Current Round Payout estimation
  • JSON account/worker monitoring API
  • Dynamic stats/setting caching (more responsive/less overhead)
  • Live round stats.
  • Stats charting
  • Memcached support
  • Process locking
  • Handling large stats on replication server
  • Email notification
  • Used by several growing pools

Upcoming features in next version:
Multi-coin, Multi-Pool, Merged Mining, SMPPS

Forum (discussion & support):
forum.simplecoin.us (http://forum.simplecoin.us/) (will need a login from simplecoin.us first)

Demonstration:
Visit simplecoin.us (https://simplecoin.us) to try out the live implementation and see latest development.

Download latest stable release
Simplecoin v5.0 (https://github.com/simplecoin/simplecoin/tarball/master)

Download latest experimental version (possibly unstable)
Simplecoin Experimental (https://github.com/simplecoin/simplecoin/tarball/experimental)
Notes:
Not for the feint hearted, you will need to be very comfortable with php & mysql to use this. Often lacks new database changes/fields.

Source Repository
Github (https://github.com/simplecoin/simplecoin)

Requirements:
Simplecoin relies on an existing and working bitcoin and pushpool installation. Before attempting to run simplecoin, please setup the following.
PHP5
Mysql
Memcached
Bitcoin: http://bitcoin.org (http://bitcoin.org)
Pushpool: http://forum.bitcoin.org/index.php?topic=8707.0 (http://forum.bitcoin.org/index.php?topic=8707.0)

Installation:
1. Extract files into web root directory
2. Create simplecoin database in you mysql instance
3. Run simplecoin.sql in your simplecoin database (This will be used for pushpool & simplcoin)
4. Edit includes/requiredFunctions.php and set the bitcoin & database login info
5. Edit all files in the cronjob folder, set $includesDirectory to the correct server path.
6. setup cronjobs on a staggered schedule. I currently run cronjob every minute and the others every 10-30 minutes. I run payout and archive twice daily.

Current Focus:
Multi-pool/coin support

Donations:
Bitcoin Donations: 163Pv9cUDJTNUbadV4HMRQSSj3ipwLURRc
Hashrate donations at https://simplecoin.us (https://simplecoin.us) are always appreciated.

Affordable, Dependable Xen VPS & Dedicated hosting
PhotonVPS (http://www.photonvps.com/billing/aff.php?aff=2122)

Projects forked from simplecoin:
Ozco.in: https://github.com/Wayno/Ozcoin (https://github.com/Wayno/Ozcoin)
MMCFE  (Mainframe Mining Cooperative Front End) SVN: http://mmcfe.mfis.net (http://mmcfe.mfis.net)

Standard disclaimer
Code:
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.
I do not claim to be a PHP guru, I simply used PHP due to it's common availability.
Before using your implementation publicly, I recommend you run through a security audit.


Title: Re: [Pushpool Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 08, 2011, 08:33:01 PM
v1 active!


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 09, 2011, 12:48:16 AM
Automated payments added to source


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Coaster on June 09, 2011, 05:46:30 AM
truly awesome, thanks for contributing this.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: MyFarm on June 09, 2011, 08:43:57 PM
Thank you SO MUCH for this!  Great job.

When I try to access the adminpanel, I get this error:

Warning: Cannot modify header information - headers already sent by (output started at /home/username/public_html/includes/header.php:33) in /home/username/public_html/adminPanel.php on line 26

Any ideas?


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: warweed on June 09, 2011, 09:01:42 PM
Anyone willing to put together a package for us not so Linux friendly bastards ?

Debian preferably something that installs apache SQL and all the rest on a fresh install phpmyadmin you know a simple point and click ?

Or write up a step by step on a fresh debian install from start to finish after debian has been installed


Also to the developer great job keep up the excellent work :)
Might I suggest a db backup feature if not already included as well as a one click update or version checker in the admincp :)

Cheers

James


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: d3c0n808 on June 09, 2011, 09:33:24 PM
Anyone willing to put together a package for us not so Linux friendly bastards ?

Debian preferably something that installs apache SQL and all the rest on a fresh install phpmyadmin you know a simple point and click ?

Or write up a step by step on a fresh debian install from start to finish after debian has been installed


Also to the developer great job keep up the excellent work :)
Might I suggest a db backup feature if not already included as well as a one click update or version checker in the admincp :)

Cheers

James

You could install xamp on a windows machine.  It comes with mysql, phpadmin, php, and apache.   From there its pretty straight forward, open some ports install the tar.gz to your htdocs or index, import the sql document using phpadmin.   and you should be good to go.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 09, 2011, 09:34:14 PM
Thank you SO MUCH for this!  Great job.

When I try to access the adminpanel, I get this error:

Warning: Cannot modify header information - headers already sent by (output started at /home/username/public_html/includes/header.php:33) in /home/username/public_html/adminPanel.php on line 26

Any ideas?

The admin flag must be set in the db along with a valid cookie, or else you cannot access it.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: warweed on June 09, 2011, 09:36:20 PM
Anyone willing to put together a package for us not so Linux friendly bastards ?

Debian preferably something that installs apache SQL and all the rest on a fresh install phpmyadmin you know a simple point and click ?

Or write up a step by step on a fresh debian install from start to finish after debian has been installed


Also to the developer great job keep up the excellent work :)
Might I suggest a db backup feature if not already included as well as a one click update or version checker in the admincp :)

Cheers

James

You could install xamp on a windows machine.  It comes with mysql, phpadmin, php, and apache.   From there its pretty straight forward, open some ports install the tar.gz to your htdocs or index, import the sql document using phpadmin.   and you should be good to go.




Yeah though about that :) cheers but then what do I do about the cron jobs ?


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 09, 2011, 09:37:40 PM
Anyone willing to put together a package for us not so Linux friendly bastards ?

Debian preferably something that installs apache SQL and all the rest on a fresh install phpmyadmin you know a simple point and click ?

Or write up a step by step on a fresh debian install from start to finish after debian has been installed


Also to the developer great job keep up the excellent work :)
Might I suggest a db backup feature if not already included as well as a one click update or version checker in the admincp :)

Cheers

James

You could install xamp on a windows machine.  It comes with mysql, phpadmin, php, and apache.   From there its pretty straight forward, open some ports install the tar.gz to your htdocs or index, import the sql document using phpadmin.   and you should be good to go.




Yeah though about that :) cheers but then what do I do about the cron jobs ?

put together scheduled tasks that point to the web location ;)


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: warweed on June 09, 2011, 10:09:04 PM
Actually quick google shows a project called cronw for wind0ze cron jobs


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 09, 2011, 11:09:49 PM
Just FYI: On my setups I'm using a wget address outputting to /dev/null to initiate the cronjobs.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 10, 2011, 05:59:13 AM
Thank you for your continued support.  My pool is live at www.ecocoin.org -- we donate our fees to buy trees and rainforest land to offset all the electricity everyone is using to mine.  Anyway, someone replied to my thread with the following:

http://forum.bitcoin.org/index.php?topic=14343.msg194621#msg194621

Wow, such a simple idea, I love it.  If you did block payouts like Eligius, I'd totally switch.
Can you please explain how the block payouts differ and why it's better?  I'd be happy to refer your thoughts to the software developer if it is indeed a superior system.  Thank you.

Here's a block solved by the Eligius pool:

http://blockexplorer.com/block/000000000000026210a972387c00e6db801346b32a815a996d698211d71a197c

The software keeps a virtual tally of your unpaid balance.  Once this crosses 1btc, you're paid out on the next generated block, RIGHT there, in the generation block.  The money never sits in some intermediary account held by the pool-owner.  There's a lot less required trust, because while the pool owner can still shut down the pool before you get your "fair share" (aka virtual balance), HE doesn't get anything out of it.  It's a very subtle and clever system, so I suggest you (or the developer) spend some time thinking about it to understand why it truly works, and I won't use a pool without it.  Obviously, you can incorporate the 3% fees as just taking 3% off the top of the generation block to your own address.  Eligius itself has no fees, but since your fees would be going to an actual cause, I might not mind as much.

I don't know if that methodology of processing blocks/payments is of interest to you, but if it is indeed superior, it may be something for you to consider.  But again, I can't thank you enough for open sourcing this software and providing me the opportunity to hopefully help the environment via Bitcoin :)

To be honest, I'm not sure how this works, but I'd be more than willing to incorporate it. I've already added a threshold, so that part is done. If I could make that work with generated block that'd be great.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: MyFarm on June 10, 2011, 06:33:47 AM
To be honest, I'm not sure how this works, but I'd be more than willing to incorporate it. I've already added a threshold, so that part is done. If I could make that work with generated block that'd be great.
You're amazing :)  The person who suggested it said to PM him (http://forum.bitcoin.org/index.php?action=pm;sa=send;u=450) if you had any questions.  He's happy to help or point you in the right direction. 


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 10, 2011, 03:07:52 PM
Some questions and help:

1.  Out of curiosity, is it possible to tell WHO found a block with this software?  

2.  I noticed you extended cookie timeout to 7 days in your simplecoin.us thread.  How do I do that?

3.  My understanding is your software supports Long Polling.  How do I turn that on?  We're experiencing a LOT of invalid shares.

4.  We had a user (user id 19 below) join with a huge pool of miners for awhile.  He's currently showing a hash rate of 135363.  Thing is, here is the lifetime shares:

User Id   Shares
19   47
12   9396
3   3020
17   1761

He is ranked number 1 but only has 47 shares.  Any idea what may have happened?

Thank you so much.  I've sent a bitcoin your way out of appreciation for everything you're doing :)

1. shares_history upstream_result = 'Y'
2. login.php time
3. That is part of pushpool, it should be enabled.
4. I'm not sure about that.... I'd wait to see if it evened out.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: lemonginger on June 10, 2011, 03:49:14 PM
I would like to start a bounty for development of good documentation for this. On the one hand, I do not think running a pool will ever be point and click, and we should be wary about people with very little server admin experience running pools. On the other hand, I think that more pools is a great thing.

+ 1 BTC for good documentation. Encourage to add bitcoins for docs or for features.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 10, 2011, 06:58:27 PM
Just pushed some updates. One greatly improves performance of worker cronjob.

Also greatly improves estimate earnings.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: MyFarm on June 10, 2011, 07:29:47 PM
Just pushed some updates. One greatly improves performance of worker cronjob.
Thank you very much!  Updated, no problems here.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 11, 2011, 07:41:27 AM
I got it installed, mysql set up, i was able to log in, but i had two questions. Now, i'm going to be doing this for nearly no vigorish, only EC2 costs of the pool hardware.

1) How do i set admin flag for an account? do i have to do that from mysql? Would it be too much to ask what the command is for that?
2) maybe this was just a cookie issue on the server, but whenever i logged out, and reloaded index.php it always showed me as logged in. I set the cookie name and / as the directory and the FQDN of the ec2 instance as the domain with a . in front. Is this the right way to do that? i tried looking at the linked page but it just said i needed a dot if i had example.com and .www.example.com

I'm more of an administrator of infrastructure and security than a programmer or DB admin, as you may have guessed; so i shall be thankful for any responses!

also, and this isn't mentioned, pushpool has to be set up, i didn't realize that for about 30 minutes after i got simplecoin working  ;D


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Drefsab on June 11, 2011, 03:46:18 PM
You might want to install something like phpmyadmin, use it to have a look at the database there will be table called webUsers. All the users in are in there, in that table there is a field called admin, if this is set to 0 the user is not an admin if its set to 1 they are :)

Im having a play with it myself at the moment its quite good though im having an issue where when I goto the admin page look at the settings if I try to change them with my admin users auth pin it doesnt error out but it doesnt change the settings, I can simply change the settings in the database directly but I guess I did something wrong will have a look through though.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: ius on June 11, 2011, 04:26:15 PM
Unfortunately, a quick audit of the source code reveals that many secure coding practices were incorrectly and inconsistenly applied or neglected completely. Running this frontend in it's current state is not safe (to say the least - you could end up losing your users' data and bitcoins).


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Jine on June 11, 2011, 04:56:07 PM
I totally agree with ius on this matter.

--

Regards, Jim


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 11, 2011, 05:32:02 PM
Well, it's open source, rather than just saying it's unsafe, why not pm me with the issues you see.

I'm not a php dev, and this is the first php project I've done in about 8 years. I write enterprise .net apps for a living, and that's a whole different ballgame.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 11, 2011, 06:18:34 PM
i noticed that there wasn't much in the way of input sanitizing, but that was at a cursory glance and not being an expert on such things.
I will install phpmyadmin to edit the database so i don't have to use sql to do it. Thanks for the tip.

I'm hoping that pushpool will work on Natty, today. :-)

edit: please advise. Do i set the pushpool databasename to the same one simplecoin is using or are they seperate databases? IE i call my database simcoi for simplecoin, should i make another database called ppool for pushpool or point it at simcoi?

Ok i think i have to go talk to pushpool people now. Thanks for bearing with me :-)


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 11, 2011, 07:06:41 PM
i noticed that there wasn't much in the way of input sanitizing, but that was at a cursory glance and not being an expert on such things.
I will install phpmyadmin to edit the database so i don't have to use sql to do it. Thanks for the tip.

I'm hoping that pushpool will work on Natty, today. :-)

edit: please advise. Do i set the pushpool databasename to the same one simplecoin is using or are they seperate databases? IE i call my database simcoi for simplecoin, should i make another database called ppool for pushpool or point it at simcoi?

Ok i think i have to go talk to pushpool people now. Thanks for bearing with me :-)

np. The input should be somewhat sanitized by mysql_escape


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: ius on June 11, 2011, 07:10:18 PM
I'm not a php dev, and this is the first php project I've done in about 8 years.

I value the open source spirit and like what you're doing (the idea behind it), but if you're unsure about your capabilities of publishing/writing/maintaining safe PHP code, then add a disclaimer or find someone willing to maintain/audit your work. Besides, SQL injection and XSS aren't isolated to just PHP..

People could lose user data and/or bitcoins (and more), and will then blame you/simplecoin..

Check your PM for some details.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 11, 2011, 07:36:17 PM
The php pages aren't showing any worker stats even though a worker is connected to the pushpoold backend using the username and password set on the account details page. Did i screw a database step up?

edit: i ran all the cronjob/*.php stuff just to make sure.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 11, 2011, 07:36:55 PM
I'm not a php dev, and this is the first php project I've done in about 8 years.

I value the open source spirit and like what you're doing (the idea behind it), but if you're unsure about your capabilities of publishing/writing/maintaining safe PHP code, then add a disclaimer or find someone willing to maintain/audit your work. Besides, SQL injection and XSS aren't isolated to just PHP..

People could lose user data and/or bitcoins (and more), and will then blame you/simplecoin..

Check your PM for some details.

Got it, will definitely fix the holes you recommended and add a disclaimer, thank you for your input.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 11, 2011, 07:37:38 PM
The php pages aren't showing any worker stats even though a worker is connected to the pushpoold backend using the username and password set on the account details page. Did i screw a database step up?

sounds like the workers.php cronjob isn't running. this updates that stat.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 11, 2011, 09:16:12 PM
Update to source:
bug fix on adminPanel.
Some security fixes in place such as anti XSS injection and additional sql escaping.


Security fixes are untested, but I thought I should include them before calling it a day.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 11, 2011, 10:36:14 PM
The php pages aren't showing any worker stats even though a worker is connected to the pushpoold backend using the username and password set on the account details page. Did i screw a database step up?

sounds like the workers.php cronjob isn't running. this updates that stat.

Nah, it's like the database for pushpool can't see the database for simplecoin and vice versa, because my worker is connected and has done 800 shares, but neither the main hasrate nor my account details have any indication that any work has been done - IE no payment. Is there something i am missing? there's no documentation for any of this stuff!!!


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 11, 2011, 10:43:47 PM
The php pages aren't showing any worker stats even though a worker is connected to the pushpoold backend using the username and password set on the account details page. Did i screw a database step up?

sounds like the workers.php cronjob isn't running. this updates that stat.

Nah, it's like the database for pushpool can't see the database for simplecoin and vice versa, because my worker is connected and has done 800 shares, but neither the main hasrate nor my account details have any indication that any work has been done - IE no payment. Is there something i am missing? there's no documentation for any of this stuff!!!

Ah, pushpool & simplecoin should be using the same database.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 11, 2011, 10:47:25 PM
The php pages aren't showing any worker stats
sounds like the workers.php cronjob isn't running.
Nah, it's like the database for pushpool can't see the database for simplecoin and vice versa
Ah, pushpool & simplecoin should be using the same database.
they are, i called it sc and a user called pushpool was granted all permissions on it. Both simplecoin and pushpool use 'pushpool'@'localhost' as the database login, and i know pushpool can see the database because it allows my worker to login via -u genewitch.1 --pass=x.
what actually has the accounting, pushpool? Maybe i can dig through your PHP to see where the accounting database calls are and try the queries in a mysql prompt to see if there are the correct values in there. If you need any of my json or config files i can provide them.

Thanks for helping me, by the way. I'm setting this up for #xkcd on foonetic. :-)
Code:
mysql> show tables;
+----------------+
| Tables_in_sc   |
+----------------+
| accountBalance |
| networkBlocks  |
| pool_worker    |
| settings       |
| shares         |
| shares_history |
| webUsers       |
+----------------+
7 rows in set (0.00 sec)

mysql> select * from sc.accountBalance;
+----+--------+---------+------------------------------------+------+-----------+
| id | userId | balance | sendAddress                        | paid | threshold |
+----+--------+---------+------------------------------------+------+-----------+
|  1 |      1 | 0       | 1CfUcB7yKKWpco3BPjzHjveyrR1rBmvmEp | 0    |         0 |
+----+--------+---------+------------------------------------+------+-----------+
1 row in set (0.00 sec)

mysql> select * from sc.shares;
Empty set (0.00 sec)

mysql> select * from sc.shares_history;
Empty set (0.00 sec)

Edit: hey, am i supposed to add anything to pushpool to take care of accounting? like add sql commands somewhere or something? Or does simplecoin use logs to determine shares and activity and set the mysql stuff itself? I know all the frontend (for payments) is NOT handled by pushpool stock install, so maybe i missed a step where i move a config file from simplecoin to somewhere else. I did run mysql sc <simplecoin.sql


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 11, 2011, 11:03:38 PM
right, pushpool uses the shares & pool_worker tables and should share them with simplecoin.

If you want, you could in theory remove shares & pool_worker from the sc database


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 11, 2011, 11:36:59 PM
right, pushpool uses the shares & pool_worker tables and should share them with simplecoin.

If you want, you could in theory remove shares & pool_worker from the sc database

Right, sc.pool_worker is sort of working as intended, as my worker can log in with genewitch.1 and x as the password. But you see how the active and hashrate aren't set? What sets those? pushpool?
Do i have to code that logic myself?
Code:
mysql> select * from sc.pool_worker;
+----+------------------+-------------+----------+--------+----------+
| id | associatedUserId | username    | password | active | hashrate |
+----+------------------+-------------+----------+--------+----------+
|  1 |                1 | genewitch.1 | x        |      0 |        0 |
+----+------------------+-------------+----------+--------+----------+
1 row in set (0.00 sec)

and shares is empty, is pushpool supposed to populate this? the reason i ask is i can go pester the pushpool developers :-)
Code:
mysql> select * from sc.shares;
Empty set (0.00 sec)



Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 12, 2011, 12:36:57 AM
yes, pushpool fills shares, gets worker info from pool_worker.

sc fills the rest with cronjobs & user input.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 12, 2011, 03:32:43 AM
hey you updated the git repo while i was making a patch:

http://paste.ubuntu.com/624849/

or
Code:
55c55
< $authPin = (int) $_POST["authPin"];
---
> $authPin = (string) $_POST["authPin"];
89c89
< if(!is_int($authPin)){
---
> if(!is_numeric($authPin)){

in register.php

This makes it so your pin can start with zero. or 2 zeros. or 3. this affected 2 out of three people on my new pool already :-p


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: gigabytecoin on June 12, 2011, 06:37:04 AM
Is simplecoin.us being ddos'd? I can't access it and haven't been able to for the last 2 hours.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 12, 2011, 07:15:36 AM
Is simplecoin.us being ddos'd? I can't access it and haven't been able to for the last 2 hours.
most likely. and the owner is AFK (he mentioned this might happen and apologized)


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 12, 2011, 04:28:17 PM
Is simplecoin.us being ddos'd? I can't access it and haven't been able to for the last 2 hours.

It was being ddos'd, I took it down to fix ;) Now that it is down, I'm going to take a few extra days to lock my server down. The site will be up before the pool, and I'm thinking about creating a testnet site for demoing/testing the newer versions.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 12, 2011, 04:43:45 PM
hey you updated the git repo while i was making a patch:

http://paste.ubuntu.com/624849/

or
Code:
55c55
< $authPin = (int) $_POST["authPin"];
---
> $authPin = (string) $_POST["authPin"];
89c89
< if(!is_int($authPin)){
---
> if(!is_numeric($authPin)){

in register.php

This makes it so your pin can start with zero. or 2 zeros. or 3. this affected 2 out of three people on my new pool already :-p

Thanks for that, I'll make sure it gets in the repo ;)


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 12, 2011, 05:27:39 PM
Anyone know how to tag a specific commit? This is my 1st run using git for version control.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 13, 2011, 06:51:36 PM
So far with the latest code, I'm passing security audits with flying colors.

If anyone notices anything, please let me know in a PM or feel free to send your own commits to the source for me to review.

Version 2 is well under way with db changes that will hopefully reduce mysqls requirements.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 13, 2011, 08:32:57 PM
Big bugfix to the main cronjob!

was setting the counted enum by int.

to fix affected records:
stop cronjob
apply patch

get latest confirmed block
select blockNumber from networkBlocks where confirms > 119

update shares_history
update settings_history set counted='1' where counted=1 and blockNumber <= (above last blocknumber)
update settings_history set counted='0' where counted=0 and blockNumber > (above last blocknumber)

start cronjob


I don't think affected payouts, but it should have played hell with stats. However, to be sure, I'm disclosing the issue.

The entire shares_history workings are already very overhauled for v2. I'm implementing a condesed shares_counted table to keep shares_history much leaner.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 13, 2011, 09:48:53 PM
I tried to use the git version of adminPanel with my existing install (not latest git) - it doesn't show anything... the old adminPanel didn't do anything.

How do i reset a user's password?

Can i go into the sql database and add shares into a table to make up for the fact that i had to delete the user's duplicate entries?

Also
BUG: You can register the same username more than once.  :-\


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 13, 2011, 10:43:08 PM
I tried to use the git version of adminPanel with my existing install (not latest git) - it doesn't show anything... the old adminPanel didn't do anything.

How do i reset a user's password?

Can i go into the sql database and add shares into a table to make up for the fact that i had to delete the user's duplicate entries?

Also
BUG: You can register the same username more than once.  :-\

What is the php error from adminPanel? It should display if you have the admin flag.

I haven't implemented password reset, I'll add that to the adminPanel and a user option based on email.
If you want to do it manually, update the pass in webUsers to sha256 of pw+your salt.

your best bet for solving miner-related issues is to update shares or shares_history username to the new miner id, but dummy shares should work.

As for the bug, set your username in webUsers to unique. That should stop duplicates for now. I'll add a proper check in the next version.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 14, 2011, 04:23:17 AM
Just added some minor updates I wanted to roll in before v2 and the required sql changes.  :)

v2 is well under way. I may roll it out before I finish all the sql optimizations. However, the biggest optimization will be included (read: archiving shares_history once counted).


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: genewitch on June 14, 2011, 07:03:22 AM
I tried to use the git version of adminPanel with my existing install (not latest git) - it doesn't show anything... the old adminPanel didn't do anything.

How do i reset a user's password?

Can i go into the sql database and add shares into a table to make up for the fact that i had to delete the user's duplicate entries?

Also
BUG: You can register the same username more than once.  :-\

What is the php error from adminPanel? It should display if you have the admin flag.

Nothing, i get a blank area where the panel normally is, but the rest of the page loads fine (the template.) I have admin set on the account. the reason i updated is you said you fixed some things and security.

is v2 going to allow seamless upgrade from v1?


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: d3c0n808 on June 14, 2011, 07:05:59 AM
I updated from git repo and each time i try to register it says user already exists, even though the database is empty.  I don't think its a issue of php not talking to mysql because if that were the case it wouldnt show anything I imagine.  Is anyone else having this issue?


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 14, 2011, 02:28:11 PM
I tried to use the git version of adminPanel with my existing install (not latest git) - it doesn't show anything... the old adminPanel didn't do anything.

How do i reset a user's password?

Can i go into the sql database and add shares into a table to make up for the fact that i had to delete the user's duplicate entries?

Also
BUG: You can register the same username more than once.  :-\

What is the php error from adminPanel? It should display if you have the admin flag.

Nothing, i get a blank area where the panel normally is, but the rest of the page loads fine (the template.) I have admin set on the account. the reason i updated is you said you fixed some things and security.

is v2 going to allow seamless upgrade from v1?

You could downgrade the adminPanel to the previous version, the fixes to adminpanel were antiXSS related. If you are the only admin, cross-site scripting shouldn't be an issue on that page.

Can you momentarily turn on php display_errors to see what's hangning? or check the apache log?


For v2 it will not be seamless, it will require DB changes. I will create an upgrade sql script though.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Lightspeed on June 14, 2011, 07:39:45 PM
hey

wanted to take a look but site doesn't appear to be working

is ozco.in an implementation of your stuff?

cheers


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: AnnihilaT on June 14, 2011, 08:27:34 PM
Hey Mike,

I like where you are going with this but the cookie implementation appears to be broken and your register function is currently broken as well.   Is the latest master supposed to be a working checkout or are you in the middle or reworking things?  Some things i noticed:

- register.php simply doesnt work i had to make the following changes to get it to work:
Code:
                $testUserQ = mysql_query("SELECT id FROM webUsers WHERE username = '".$username."' LIMIT 1");
                        //If not, create new user
                        //if (!$testUserQ) {
                        if (($testUserQ == false) || (mysql_num_rows($testUserQ) == 0)) {

- logout.php simply doesnt work.  Once logged in its impossible to logout without the session either timing out (didnt try to wait for this) or manually updateding/removing the timestamp in the webUser table.  Also you use a meta refresh in logout and login but wouldnt a
         header("Location: /index.php");
be nicer? Or something alike ?

Im curious who is doing your security audit?  You mention that you are getting one done but no details about this.... this might be a good point to expand on since security with web apps are always difficult to get right.   Also you might want to look into the webmin running on your server...if its v1.54, its vulnerable to an XSS attack that can result in root user priveleges for a remote attacker.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 15, 2011, 04:33:50 AM
Hey Mike,

I like where you are going with this but the cookie implementation appears to be broken and your register function is currently broken as well.   Is the latest master supposed to be a working checkout or are you in the middle or reworking things?  Some things i noticed:

- register.php simply doesnt work i had to make the following changes to get it to work:
Code:
               $testUserQ = mysql_query("SELECT id FROM webUsers WHERE username = '".$username."' LIMIT 1");
                        //If not, create new user
                        //if (!$testUserQ) {
                        if (($testUserQ == false) || (mysql_num_rows($testUserQ) == 0)) {

- logout.php simply doesnt work.  Once logged in its impossible to logout without the session either timing out (didnt try to wait for this) or manually updateding/removing the timestamp in the webUser table.  Also you use a meta refresh in logout and login but wouldnt a
         header("Location: /index.php");
be nicer? Or something alike ?

Im curious who is doing your security audit?  You mention that you are getting one done but no details about this.... this might be a good point to expand on since security with web apps are always difficult to get right.   Also you might want to look into the webmin running on your server...if its v1.54, its vulnerable to an XSS attack that can result in root user priveleges for a remote attacker.

I think a few unintended things snuck into the last checkout. I'm about halfway through with the v2 code, and I'm trying to keep it out of master for now.

I had an outpatient spinal procedure done today, so nothing will be checked in tonight. Hopefully I can have a demo of the new work on the test-net soon for some real-world testing and viewing.

As for the security audit, I'm handling them. I'm using internal tools from my professional work, along with acunetix & nmap so far. The current v2(&1.1) code checks out clear so far. If you have any additional recommendations, I'd love to hear them.

I'm not using webmin 1.54 on my production machines. Once back in production, ssh should suffice for the live server. I like to keep production running as lean as possible.



In the future, I'll branch new code and keep the master at the latest 100% stable version.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 18, 2011, 03:15:44 AM
Hello forums peoples,

I have been using simple coin to run a site and well it isn't working as it should. for starts the shares system is off as i found out after some days of testing and manual calculation, when 2 blocks are found with in a time frame the confirms STOP working on the older block, the cronjob system is hectic as it is if the db is updating the shares and the account balance part the system can run 2 cronjobs and you can get double payouts on the same block.

we have spent the last 48 hrs fixing the code to run correct and make things smoother. just a warning on this if u are planing to use the this code to run ur own large pool.

i found out the hard way ;)

its a great front end but a lot of minor and large bugs to be found and isolated as well.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: dcconsulting on June 18, 2011, 06:25:47 AM
Hi Wayno,

It Would be great in the spirit of Open Source to publish the fixed code to us. I am also running a pool on the Simplecoin Frontend and this makes me worry. Have not solved a block yet so it would be greatly appreciated before that.

Regards


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Spirals on June 18, 2011, 10:46:39 AM
There seems to be a bug in accountsettings.php. Changing line 151:
Code:
}else if($inputAuthPin != $authPin && $act){

to:

Code:
}else if($inputAuthPin != $authPin && $act != "addWorker"){

fixes the warning about 'invalid authorization pin' when adding a worker.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 18, 2011, 05:12:51 PM
dcconsulting we have solved 5 so far in 10 days running, and oh boy wat a problem it was sorting everything out. the only big issue we had was that i am running bitcoind 3.22 and the backend needs to be changed to generate to immature on looking for blocks, we found 2 blocks on the same day 5 hours apart this is were all the fun started ;)

be warned my code has been changed ALOT

https://github.com/Wayno

i havent uploaded the new db changes yet i will do that later on tonight


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: dcconsulting on June 19, 2011, 08:21:44 AM
Thank You Wayno !

edit : HAHA writings of a mad man !


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 19, 2011, 10:33:33 AM
i have uploaded the db and new code.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: dcconsulting on June 19, 2011, 10:49:07 AM
Wayno,

Running the cronjob.php I get the following

PHP Fatal error:  Call to undefined function lock() in /var/www/cronjobs/cronjob.php on line 25

In Cronjob Line 25 = lock("cronjob.php");

Any ideas ?


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 19, 2011, 12:40:21 PM
requiredFunctions.php u need to have my copy theres a fucntion in there called lock

line 163


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: dcconsulting on June 19, 2011, 01:03:06 PM
Ah thanks

Now I am getting this error,

Output from command php /var/www/cronjobs/cronjob.php ..

PHP Notice:  Trying to get property of non-object in /var/www/cronjobs/cronjob.php on line 157
XML-RPC: xmlrpcmsg::parseResponseHeaders: HTTP error, got response: HTTP/1.1 500 Internal Server Error
PHP Fatal error:  Uncaught BitcoinClientException:
  • : Didn't receive 200 OK from remote server. (HTTP/1.1 500 Internal Server Error)

  thrown in  on line 0


Probably because I have not solved any block yet.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: dcconsulting on June 19, 2011, 01:04:04 PM
By the way Excellent work, the site just seems to be smoother.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 20, 2011, 04:41:04 PM
Nice, a fork!

I haven't been able to do much lately, but it looks like I'll probably get around to getting v2 up and running this week.

I'll definitely take a look at Wayno's code too, to see if it makes sense to bring anything over


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: BurningToad on June 20, 2011, 11:32:34 PM
i have uploaded the db and new code.

Thanks Wayno!


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 21, 2011, 04:10:07 AM
Updated db and code base, lotsa fixs and stuff.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: froggy on June 21, 2011, 12:34:17 PM
drrconsulting, regarding ozcoin's cronjob.php error, ozcoin seems to be using an amended version of bitcoin.inc.php  .  I was getting similar errors but replaced ozcoin's /includes/bitcoinController/bitcoin.inc.php with the bitcoin.inc.php from Xenland's current code and no more cronjob.php errors.

The /cronjobs/shares.php seems to hve an error.  I'm getting
Code:
PHP Warning:  implode(): Invalid arguments passed in [PATH-TO]/cronjobs/shares.php on line 69

Bit confused as to what's going on with 'id' in that script.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 21, 2011, 04:23:18 PM
oh yeah i forgot i changed the standard port 8332 to 8335

better change that in bitcoin.inc.php


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: frizzl on June 22, 2011, 06:46:00 AM
My stats seems off a bit,can any tell me what the "settings" table is used for ..its currently blank and I see it referenced quite a bit in the php code.  Do I need to add something?  So far everything else is working good but i have no server stats and some workers show wrong.  Cron jobs are setup and run fine, what times is anyone using?  Good job everyone btw.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: simplecoin on June 22, 2011, 07:20:18 PM
My stats seems off a bit,can any tell me what the "settings" table is used for ..its currently blank and I see it referenced quite a bit in the php code.  Do I need to add something?  So far everything else is working good but i have no server stats and some workers show wrong.  Cron jobs are setup and run fine, what times is anyone using?  Good job everyone btw.

yes, there is an insert line in the setup sql (try running just that line).


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: frizzl on June 23, 2011, 01:29:30 PM
Wayno i cannot get it to report online miners corretly.  I added the above fix from simplexoin and that claered up a bunch of the stat issues but still have miners online reporting incorrect.  Can u upload ur settings db config?  All time stats are not quite working right either it seems.  I am mining w 3 miners currentlyw2 different test accounts.  Thanks


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 24, 2011, 05:25:39 AM
go into admin panel and change cheating to proportional as i haven't removed it.

when u upload the database it will be cleaned u need to add all the settings in.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: frizzl on June 24, 2011, 08:14:33 PM
Wayno, what rows are included in settings same as in original simplecoin i have:

currenthashrate    
currentroundshares    
currentworkers    
mtgoxlast    
pagetitle
sitebalance    
sitepayoutaddress    
sitepercent    
siterewardtype    
slogan    
statstime    
websitename

thanks for all ur help


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: Wayno on June 25, 2011, 02:46:14 AM
currenthashrate    43379
currentroundshares    1215632
currentworkers    124
mtgoxlast    1
pagetitle    Ozco.in
sitebalance    0
sitepayoutaddress    1GG9HQZchCRxPSBV5SwZ9GoYEVq9vVLGqU
sitepercent    1
siterewardtype    1
slogan    Making Bitcoins Simple
statstime    1308969381
websitename    Ozco.in

thats wat it currently looks like

statstime    1308969381 is the only one i added


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL
Post by: frizzl on June 25, 2011, 03:00:28 AM
Ok thanks for verifying, i found statstime in the code making sure there wasn't any others.  Thanks for your help


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 25, 2011, 06:58:00 AM
Version 2 beta is available from github!

There are several sql changes and you will need to manually enter them if you choose to upgrade an existing install.
Note: counted in shares history is now an enum.
To convert update existing- UPDATE shares_history set counted='1' where counted=1; update shares_history set counted='0' where counted=0
ONLY RUN if your shares_history counted is not an enum after updating tables

There could be stats errors, and some unchanged terminology that needs updating. That said, payouts & balance figures should be correct!

Please note any issues you have (or an update sql script if you have the time!!! I hate writing those by hand).

Thanks, and more features coming :)


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: froggy on June 25, 2011, 05:53:41 PM
Yayy!  Thanks Simplecoin - trying it now.

A tip for testing....
Code:
I was getting errors when testing the crobjobs via command line ssh:
[code]
 PHP Notice:  Undefined index: REMOTE_ADDR

so I've password protected the cronjobs folder using htacess.

You should then be able to safely change the code in the cronjobs from :
Code:

//Check that script is run locally
$ip = $_SERVER['REMOTE_ADDR'];
if ($ip != "127.0.0.1") {
echo "cronjobs can only be run locally.";
exit;
}

to
Code:

if (isset( $_SERVER['REMOTE_ADDR']))
 {
$ip = $_SERVER['REMOTE_ADDR'];
if ($ip != "127.0.0.1")
      {
echo "cronjobs can only be run locally.";
exit;
      }
  }

...which will enable you to test the cronjobs via the command line.[/code]


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 25, 2011, 10:54:50 PM
Yayy!  Thanks Simplecoin - trying it now.

A tip for testing....
Code:
I was getting errors when testing the crobjobs via command line ssh:
[code]
 PHP Notice:  Undefined index: REMOTE_ADDR

so I've password protected the cronjobs folder using htacess.

You should then be able to safely change the code in the cronjobs from :
Code:

//Check that script is run locally
$ip = $_SERVER['REMOTE_ADDR'];
if ($ip != "127.0.0.1") {
echo "cronjobs can only be run locally.";
exit;
}

to
Code:

if (isset( $_SERVER['REMOTE_ADDR']))
 {
$ip = $_SERVER['REMOTE_ADDR'];
if ($ip != "127.0.0.1")
      {
echo "cronjobs can only be run locally.";
exit;
      }
  }

...which will enable you to test the cronjobs via the command line.[/code]

Thanks, I didn't have any problems running wget http://localhost/cronjobs/...., but I'm happy to implement that. Seems like a harmless addition.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: AnnihilaT on June 26, 2011, 09:22:21 AM
Hi Mike,

I've been hacking on your code a bit for the last day again and testing everything on a private testnet in a box setup with 2 nodes and there are some things puzzling me about how the cronjob.php code works.  Mainly in the logic.  Ill try and explain each on separately.

Checking if we found a block.
Here we query bitcoind with a listtransactions query with no extra arguments so we get a default count of the last 10 transactions.  We check if the category is "generate" and if so we assume we may have found a block and start doing some logic to make sure of that.  

This is where i already dont get it.   On my testnet setup,  when we find a new block its category is immature and remains that way until it receives 120 confirmations at which point it changes from "immature" to "generate".  see below:

Code:
   {
        "account" : "",
        "category" : "generate",
        "amount" : 50.00000000,
        "confirmations" : 120,
        "txid" : "47a833ba9e311a839988136a283d9e6a8d05f7c609cc5ec26de397f352472751",
        "time" : 1300079031
    },
    {
        "account" : "",
        "category" : "immature",
        "amount" : 50.00000000,
        "confirmations" : 119,
        "txid" : "c31c89383ec77234cc2c2cbeca87edbc2b6348edba9d0e6c343fc34f1ed730ff",
        "time" : 1300079115
    },

This means that by the time we have a transaction with the "generate" category it will have long ago fallen out of the data returned by the listtransactions query since that only shows the last 10 transactions.  I realize that works a bit different on an active live network but it still seems odd to me that at least the way im reading the code that you rely on the assumption that we wont find more than 10 blocks out of 120 (or something like this - maybe i made a math error).  If i leave it set like this on a private testnet the side effect is that no blocks are ever seen as found and the round never ends because by the time the block has changed from immature to generate it has fallen out of the list of the last 10 transactions because our pool is finding every single block.   Does this make sense?  

Updateing confirms
The next part also confuses me for a similar reason.  NExt we go through all the transactions and update their confirms.  Here again we check the category if its set to "receive" but from what i can see an immature or generated block will never have this category.  Its category is always either generate or immature (on testnet).  see below:

here is a closer look at a txid which has matured
Code:
# bitcoind -datadir=testnet/1 gettransaction 47a833ba9e311a839988136a283d9e6a8d05f7c609cc5ec26de397f352472751

{
    "amount" : 50.00000000,
    "confirmations" : 120,
    "txid" : "47a833ba9e311a839988136a283d9e6a8d05f7c609cc5ec26de397f352472751",
    "time" : 1300079031,
    "details" : [
        {
            "account" : "",
            "category" : "generate",
            "amount" : 50.00000000
        }
    ]
}

and a closer look at one right after it with only 119 confirms and will be maturing next round:
Code:
# bitcoind -datadir=testnet/1 gettransaction c31c89383ec77234cc2c2cbeca87edbc2b6348edba9d0e6c343fc34f1ed730ff

{
    "amount" : 0.00000000,
    "confirmations" : 119,
    "txid" : "c31c89383ec77234cc2c2cbeca87edbc2b6348edba9d0e6c343fc34f1ed730ff",
    "time" : 1300079115,
    "details" : [
        {
            "account" : "",
            "category" : "immature",
            "amount" : 50.00000000
        }
    ]
}

so the effect here is that nothing will ever get its confirms updated unless your check is changed to immature or generate.   Can you explain to me the "receive" category and why you are using this as a check?  

Calculating payouts and ending the round
This part seems to be pretty straightforward assuming that the previous 2 steps went right with the exception that it looks like in this part of the code is where we close out the round (am i wrong here).   It seems that the round doesnt get closed out properly if this part of the code doesnt run (for example because there are not yet enough confirms on any of the blocks.)   Is it true that this is where the round ends or at least some part of the logic for ending a round is in here?  Or is that completely all up top of the code where we move all old shares to shares_history.  

Other random questions
Wouldnt it be better to track 2 balance amounts - an unconfirmed and a confirmed amount and only allow payout of course on the confirmed balance?  It seems the way the code is written now that a user will have no idea they might have earned until all found blocks have at least 120 confirms.   So if you are just starting up a new pool, your new users will show a 0 balance until at least 120 or so blocks have been found on the network which would confuse them and maybe scare them off right from the start as it would look like they arent earning anything.   Am i correct about it working like this?  

I hope im explaining this well enough for you to get my point.  It;s late and i know i might not be making myself very clear.   Thanks for any clarification you can give!! Maybe im missing something very simple here. :)


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: drontus on June 26, 2011, 09:51:45 AM
workers wan't connect to pool =\ help plz


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 26, 2011, 04:07:56 PM
Hi Mike,

I've been hacking on your code a bit for the last day again and testing everything on a private testnet in a box setup with 2 nodes and there are some things puzzling me about how the cronjob.php code works.  Mainly in the logic.  Ill try and explain each on separately.

Checking if we found a block.
Here we query bitcoind with a listtransactions query with no extra arguments so we get a default count of the last 10 transactions.  We check if the category is "generate" and if so we assume we may have found a block and start doing some logic to make sure of that.  

This is where i already dont get it.   On my testnet setup,  when we find a new block its category is immature and remains that way until it receives 120 confirmations at which point it changes from "immature" to "generate".  see below:

Code:
   {
        "account" : "",
        "category" : "generate",
        "amount" : 50.00000000,
        "confirmations" : 120,
        "txid" : "47a833ba9e311a839988136a283d9e6a8d05f7c609cc5ec26de397f352472751",
        "time" : 1300079031
    },
    {
        "account" : "",
        "category" : "immature",
        "amount" : 50.00000000,
        "confirmations" : 119,
        "txid" : "c31c89383ec77234cc2c2cbeca87edbc2b6348edba9d0e6c343fc34f1ed730ff",
        "time" : 1300079115
    },

This means that by the time we have a transaction with the "generate" category it will have long ago fallen out of the data returned by the listtransactions query since that only shows the last 10 transactions.  I realize that works a bit different on an active live network but it still seems odd to me that at least the way im reading the code that you rely on the assumption that we wont find more than 10 blocks out of 120 (or something like this - maybe i made a math error).  If i leave it set like this on a private testnet the side effect is that no blocks are ever seen as found and the round never ends because by the time the block has changed from immature to generate it has fallen out of the list of the last 10 transactions because our pool is finding every single block.   Does this make sense?  

Updateing confirms
The next part also confuses me for a similar reason.  NExt we go through all the transactions and update their confirms.  Here again we check the category if its set to "receive" but from what i can see an immature or generated block will never have this category.  Its category is always either generate or immature (on testnet).  see below:

here is a closer look at a txid which has matured
Code:
# bitcoind -datadir=testnet/1 gettransaction 47a833ba9e311a839988136a283d9e6a8d05f7c609cc5ec26de397f352472751

{
    "amount" : 50.00000000,
    "confirmations" : 120,
    "txid" : "47a833ba9e311a839988136a283d9e6a8d05f7c609cc5ec26de397f352472751",
    "time" : 1300079031,
    "details" : [
        {
            "account" : "",
            "category" : "generate",
            "amount" : 50.00000000
        }
    ]
}

and a closer look at one right after it with only 119 confirms and will be maturing next round:
Code:
# bitcoind -datadir=testnet/1 gettransaction c31c89383ec77234cc2c2cbeca87edbc2b6348edba9d0e6c343fc34f1ed730ff

{
    "amount" : 0.00000000,
    "confirmations" : 119,
    "txid" : "c31c89383ec77234cc2c2cbeca87edbc2b6348edba9d0e6c343fc34f1ed730ff",
    "time" : 1300079115,
    "details" : [
        {
            "account" : "",
            "category" : "immature",
            "amount" : 50.00000000
        }
    ]
}

so the effect here is that nothing will ever get its confirms updated unless your check is changed to immature or generate.   Can you explain to me the "receive" category and why you are using this as a check?  

Calculating payouts and ending the round
This part seems to be pretty straightforward assuming that the previous 2 steps went right with the exception that it looks like in this part of the code is where we close out the round (am i wrong here).   It seems that the round doesnt get closed out properly if this part of the code doesnt run (for example because there are not yet enough confirms on any of the blocks.)   Is it true that this is where the round ends or at least some part of the logic for ending a round is in here?  Or is that completely all up top of the code where we move all old shares to shares_history.  

Other random questions
Wouldnt it be better to track 2 balance amounts - an unconfirmed and a confirmed amount and only allow payout of course on the confirmed balance?  It seems the way the code is written now that a user will have no idea they might have earned until all found blocks have at least 120 confirms.   So if you are just starting up a new pool, your new users will show a 0 balance until at least 120 or so blocks have been found on the network which would confuse them and maybe scare them off right from the start as it would look like they arent earning anything.   Am i correct about it working like this?  

I hope im explaining this well enough for you to get my point.  It;s late and i know i might not be making myself very clear.   Thanks for any clarification you can give!! Maybe im missing something very simple here. :)


Yes, that's on the agenda. The code was based around modifications to Xenlands original. After seeing it in action, I think there are better ways to implement it. Thanks for the input, I'll definitely put some weight to it.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: AnnihilaT on June 26, 2011, 09:48:26 PM
Hi Mike,

Maybe i didnt make it clear that im implementing these things also where i think they make sense so maybe we should talk about working together on the project?  Also,  i had alot of questions in there as well for you and wonder if you could maybe (if you have time) answer some of my questions and let me know if things are actually as i understand them to be or if im making some wrong assumptions.  While i am testing the changes im making,  i also want to be sure that im not making some false assumptions about how it all works.   

Particularly im interested to hear your thoughts about the whole cronjob logic because im planning on making some significant changes here and would be nice to hear another opinion from someone who has used the code live.  I can only test on testnet.   

Can you verify that under normal operation with the code you run that indeed shares just keep counting up until the first block we found has 120 confirms and that maybe some other things work kind of weird as well until we hit the first block with 120 confirms?   Perhaps with my changes ive intoduced some oddities and want to make sure that the problems im "fixing" arent self induced :)

Anni


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 26, 2011, 10:26:31 PM
Hi Mike,

Maybe i didnt make it clear that im implementing these things also where i think they make sense so maybe we should talk about working together on the project?  Also,  i had alot of questions in there as well for you and wonder if you could maybe (if you have time) answer some of my questions and let me know if things are actually as i understand them to be or if im making some wrong assumptions.  While i am testing the changes im making,  i also want to be sure that im not making some false assumptions about how it all works.  

Particularly im interested to hear your thoughts about the whole cronjob logic because im planning on making some significant changes here and would be nice to hear another opinion from someone who has used the code live.  I can only test on testnet.  

Can you verify that under normal operation with the code you run that indeed shares just keep counting up until the first block we found has 120 confirms and that maybe some other things work kind of weird as well until we hit the first block with 120 confirms?   Perhaps with my changes ive intoduced some oddities and want to make sure that the problems im "fixing" arent self induced :)

Anni

As far as working together, currently I want to personally check any code that comes through before it posts. That said, I tend to implement just about any pull request that is beneficial and benign.

I'm currently going through the cronjob logic myself. It works currently since blocks aren't generated very often, but it needed a heavy overhaul.

I'm changing the way it checks confirms & generations. The initial block now looks at generate and immature in the past 200 txs. The second block will look through networkblocks and not transactions. it will check bitcoind against txid to count confirms if less than 120 in networkblocks.

After that is all said and done, I intend to fork bitcoin & pushpool into one codebase to cut down on getwork traffic and expose new rpc commands to filter transactions based on category.

To answer your other questions:
calculating payouts: yes this ends the round. by setting counted='1' the shares are now invalid for the current round.
confirmed & unconfirmed balances: I think that would just add further confusion. Estimated balances alone have caused confusion that is a real pain. I'm tempted to even remove that from my own pool as it seems to anger people when they can't cashout a non-existent balance.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 26, 2011, 11:17:34 PM
Here is my proposed improved method...

Code:
//Get list of transactions
$transactions = $bitcoinController->query("listtransactions \"*\" 200");

//Go through all the transactions check if there is 50BTC inside
$numAccounts = count($transactions);

for($i = 0; $i < $numAccounts; $i++) {
//Check for 50BTC inside only if they are in the generate category
if($transactions[$i]["amount"] >= 50 && ($transactions[$i]["category"] == "generate" || $transactions[$i]["category"] == "immature")) {
//At this point we may or may not have found a block,
//Check to see if this account addres is already added to `networkBlocks`
$accountExistsQ = mysql_query("SELECT id FROM networkBlocks WHERE accountAddress = '".$transactions[$i]["txid"]."' ORDER BY blockNumber DESC LIMIT 0,1")or die(mysql_error());
$accountExists = mysql_num_rows($accountExistsQ);

    //Insert txid into latest network block
if (!$accountExists) {
//Get last winning block
$lastSuccessfullBlockQ = mysql_query("SELECT n.id FROM networkBlocks n, winning_shares w where n.blockNumber = w.blockNumber ORDER BY w.id DESC LIMIT 1");
$lastSuccessfullBlockR = mysql_fetch_object($lastSuccessfullBlockQ);
$lastEmptyBlock = $lastSuccessfullBlockR->id;

$insertBlockSuccess = mysql_query("UPDATE networkBlocks SET accountAddress = '".$transactions[$i]["txid"]."' WHERE id = $lastEmptyBlock")or die(mysql_error());

//Update site balance for tx fee
$poolReward = $transactions[$i]["amount"] - $bonusCoins;
mysql_query("UPDATE settings SET value = value + $poolReward WHERE setting='sitebalance'");
}
}
}

//Go through networkblocks and update confirms as needed
$winningAccountQ = mysql_query("SELECT id, accountAddress FROM networkBlocks WHERE accountAddress <> '' AND confirms < 120");
while ($winningAccountR = mysql_fetch_object($winningAccountQ)) {
$txInfo = $bitcoinController->gettransaction($winningAccountR->accountAddress);
if (count($txInfo["confirmations"]) > 0) {
mysql_query("UPDATE networkBlocks SET confirms = ".$txInfo["confirmations"]." WHERE id = $winningAccountR->id");
}
}

Also, I'm thinking of ways to remove shares_history, I hate having so many table joins slowing things down.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: AnnihilaT on June 27, 2011, 12:39:40 AM

As far as working together, currently I want to personally check any code that comes through before it posts. That said, I tend to implement just about any pull request that is beneficial and benign.

Makes sense.  Ill have to see if i can get up to speed on GIT.  I always use SVN myself. 

Quote
I'm currently going through the cronjob logic myself. It works currently since blocks aren't generated very often, but it needed a heavy overhaul.

I'm changing the way it checks confirms & generations. The initial block now looks at generate and immature in the past 200 txs. The second block will look through networkblocks and not transactions. it will check bitcoind against txid to count confirms if less than 120 in networkblocks.

Funny...ive been sitting here doing the exact same thing for the last couple hours and finally think i have it working quite nicely. I think 200 might be a bit excessive and have set mine for now to 60 i think.  This seems to catch everything.  Certainly alot better than 10 :)

Quote
After that is all said and done, I intend to fork bitcoin & pushpool into one codebase to cut down on getwork traffic and expose new rpc commands to filter transactions based on category.

Sounds good.

Quote
To answer your other questions:
calculating payouts: yes this ends the round. by setting counted='1' the shares are now invalid for the current round.
confirmed & unconfirmed balances: I think that would just add further confusion. Estimated balances alone have caused confusion that is a real pain. I'm tempted to even remove that from my own pool as it seems to anger people when they can't cashout a non-existent balance.

RE: ending the round... Yes this makes sense.  It only seems to make more sense to my brain at this very moment to end the round immediately when a block is found and we start counting confirms rather than wait until we have 120 confirms on our first block to end a round.  I just think its going to cause lots of confusion to users of someone who starts up a brand new pool.  It should work completely normally and intuitive once you get to your first 120 confirms on that first found block but before that.... yeah... weird.   Or do i misunderstand how it works?   For the rest of what you say i agree with! :)


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: AnnihilaT on June 27, 2011, 12:57:35 AM
Here is my proposed improved method...

Code:
//Get list of transactions
$transactions = $bitcoinController->query("listtransactions \"*\" 200");

//Go through all the transactions check if there is 50BTC inside
$numAccounts = count($transactions);

for($i = 0; $i < $numAccounts; $i++) {
//Check for 50BTC inside only if they are in the generate category
if($transactions[$i]["amount"] >= 50 && ($transactions[$i]["category"] == "generate" || $transactions[$i]["category"] == "immature")) {
//At this point we may or may not have found a block,
//Check to see if this account addres is already added to `networkBlocks`
$accountExistsQ = mysql_query("SELECT id FROM networkBlocks WHERE accountAddress = '".$transactions[$i]["txid"]."' ORDER BY blockNumber DESC LIMIT 0,1")or die(mysql_error());
$accountExists = mysql_num_rows($accountExistsQ);

    //Insert txid into latest network block
if (!$accountExists) {
//Get last winning block
$lastSuccessfullBlockQ = mysql_query("SELECT n.id FROM networkBlocks n, winning_shares w where n.blockNumber = w.blockNumber ORDER BY w.id DESC LIMIT 1");
$lastSuccessfullBlockR = mysql_fetch_object($lastSuccessfullBlockQ);
$lastEmptyBlock = $lastSuccessfullBlockR->id;

$insertBlockSuccess = mysql_query("UPDATE networkBlocks SET accountAddress = '".$transactions[$i]["txid"]."' WHERE id = $lastEmptyBlock")or die(mysql_error());

//Update site balance for tx fee
$poolReward = $transactions[$i]["amount"] - $bonusCoins;
mysql_query("UPDATE settings SET value = value + $poolReward WHERE setting='sitebalance'");
}
}
}

//Go through networkblocks and update confirms as needed
$winningAccountQ = mysql_query("SELECT id, accountAddress FROM networkBlocks WHERE accountAddress <> '' AND confirms < 120");
while ($winningAccountR = mysql_fetch_object($winningAccountQ)) {
$txInfo = $bitcoinController->gettransaction($winningAccountR->accountAddress);
if (count($txInfo["confirmations"]) > 0) {
mysql_query("UPDATE networkBlocks SET confirms = ".$txInfo["confirmations"]." WHERE id = $winningAccountR->id");
}
}

Also, I'm thinking of ways to remove shares_history, I hate having so many table joins slowing things down.

Funny!  I was just doing more or less the same.  My code looks almost identical.

Code:
//Query bitcoind for list of transactions
$transactions = $bitcoinController->query('listtransactions', '', '60');

//Go through all the transactions check if there is 50BTC inside
$numAccounts = count($transactions);

for($i = 0; $i < $numAccounts; $i++){
        //Check for 50BTC in each transaction (even when immature so we can start tracking confirms)
        if($transactions[$i]["amount"] >= 50 && ($transactions[$i]["category"] == "generate" || $transactions[$i]["category"] == "immature")) {



Also it look like the mtgox.php is broken.  Not sure why so i hacked this in real quick.  It depends on having curl installed at the command line:

Code:
// Update MtGox last price via curl, 3 second timeout on connection
$mtgox_ticker = exec("/usr/bin/curl -q -s --connect-timeout 3 'https://mtgox.com/code/data/ticker.php'");
if (!is_null($mtgox_ticker)) {
        $ticker_obj = json_decode($mtgox_ticker);
        if (intval($ticker_obj->ticker->last) > 0) {
                $settings->setsetting('mtgoxlast', $ticker_obj->ticker->last);
        }
}

Furthur:  logout.php is completely broken for me (or was).  It was impossible to logout. Im using this instead.  Does this look sane to you?
Code:
//Include site functions
include("includes/requiredFunctions.php");
include("includes/universalChecklogin.php");

$user = $userInfo->username;
$checkPassQ = mysql_query("SELECT id FROM webUsers WHERE username = '".$user."' LIMIT 0,1");
$checkPass = mysql_fetch_object($checkPassQ);
$userid = $checkPass->id;

setcookie($cookieName, false);
unset($cookieValid);
mysql_query("UPDATE `webUsers` SET `sessionTimeoutStamp` = '0' WHERE `id` = '" .$userid. "'");
header("Location: /index.php");



Some of the other things ive done so far are:
- added worker deletion and improved layout of account details a bit
- logout menu item
- rewritten the stats leftsidebar thing
- started working on some nicer admin features and stats
- improved layout of the stats page
- Fixed a security issue (maybe introduced 1 or 2 as well :D)
- gotten rid of the login.php refresh page and replace it with a 2 second sleep after each login attempt (plans to make this safer)
- prolly lots more...  anyway ive been busy :)



Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 27, 2011, 02:40:48 PM
New updates for v2 checked in.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 27, 2011, 03:04:53 PM
Some of the other things ive done so far are:
- added worker deletion and improved layout of account details a bit
did you merge the workers existing uncounted shares to another worker? Also, did you make sure that there is at least 1 worker (to keep from losing all shares)?

Quote
- Fixed a security issue (maybe introduced 1 or 2 as well :D)

Security is my biggest priority. If you could forward anything you see it is greatly appreciated.

Quote
- gotten rid of the login.php refresh page and replace it with a 2 second sleep after each login attempt (plans to make this safer)
Good idea, I was thinking a captcha after 2 unsuccessful logins by any 1 ip.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 27, 2011, 03:27:33 PM
More updates to v2.

Currently folding in parts of Ozco.in fork to the v2 code where it makes sense.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: AnnihilaT on June 27, 2011, 06:03:10 PM
Quote
did you merge the workers existing uncounted shares to another worker? Also, did you make sure that there is at least 1 worker (to keep from losing all shares)?

Oh! Good point! Ill have to have another look at how i did that :)

Quote
Security is my biggest priority. If you could forward anything you see it is greatly appreciated.

not sure if its a huge issue but this is one that pops to mind:
Code:
//Check if the cookie is set, if so check if the cookie is valid
if(isSet($_COOKIE[$cookieName])){
        $cookieValid = false;
        $ip = $_SERVER['REMOTE_ADDR']; //Get Ip address for cookie validation
        $validateCookie = new checkLogin();
        $cookieValid = $validateCookie->checkCookie(mysql_real_escape_string($_COOKIE[$cookieName]), $ip);
        $userId = $validateCookie->returnUserId($_COOKIE[$cookieName]);

        //ensure userId is integer to prevent sql injection attack
        if (!is_numeric($userId)) {
                $userId = 0;
                exit;
        }


Quote
Quote
- gotten rid of the login.php refresh page and replace it with a 2 second sleep after each login attempt (plans to make this safer)
Good idea, I was thinking a captcha after 2 unsuccessful logins by any 1 ip.

I hate captcha's.  Gonna try to think of something nicer... for now im just sleeping 2 secs and then header("Location:") back to index.php.



Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 27, 2011, 06:17:53 PM
Many Ozcoin improvements merged into main tree. Excellent work by Wayno & tom lightspeed!


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 beta out!)
Post by: simplecoin on June 27, 2011, 06:28:57 PM
Anni, that security fix is in the repo ;)

Also, worker update/delete is there from ozcoin code. (it doesn't roll in old workers yet though).

The login attempt ban is also now in place.


Title: Re: [Pushpool Web Frontend] Simplecoin Opensource PHP/MySQL (v2 out!)
Post by: simplecoin on June 28, 2011, 02:10:12 PM
Version 2 stable released, includes upgrade script from simplecoin 1.0 database.

All sql files are now in the sql/ directory.

Cheers!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: AnnihilaT on June 28, 2011, 05:52:14 PM
Mike,

I think ive decided to fork the codebase you have maintained into a new project as i see you heading in a different direction with v2 than what originally attracted me in the first place.  Ill be keeping a SVN repo up and open so that my changes will be also available.   I will still probably borrow from your project as you can do from mine where and when applicable.  

At this point i have more than 1390 lines of differences to the original v1 code that i checked out and so this just seems to make more sense to me.   Also if you are curious, my version is running at http://mining.mainframe.nl/

Let me know if you have any questions or concerns.

Anni


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on June 28, 2011, 07:11:05 PM
Mike,

I think ive decided to fork the codebase you have maintained into a new project as i see you heading in a different direction with v2 than what originally attracted me in the first place.  Ill be keeping a SVN repo up and open so that my changes will be also available.   I will still probably borrow from your project as you can do from mine where and when applicable.  

At this point i have more than 1390 lines of differences to the original v1 code that i checked out and so this just seems to make more sense to me.   Also if you are curious, my version is running at http://btc.mfis.net

Let me know if you have any questions or concerns.

Anni

Fork away :)

Let me know where your repo is and I'll put a link up on the OP.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on June 28, 2011, 11:09:12 PM
Experimental branch created in github. All new development will go here until it is merged into a new version.

That said, just added Server load stats to the experimental branch. Should be good and stable. No db changes required.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: AnnihilaT on June 29, 2011, 12:50:55 AM
Mike,

I think ive decided to fork the codebase you have maintained into a new project as i see you heading in a different direction with v2 than what originally attracted me in the first place.  Ill be keeping a SVN repo up and open so that my changes will be also available.   I will still probably borrow from your project as you can do from mine where and when applicable.  

At this point i have more than 1390 lines of differences to the original v1 code that i checked out and so this just seems to make more sense to me.   Also if you are curious, my version is running at http://btc.mfis.net

Let me know if you have any questions or concerns.

Anni

Fork away :)

Let me know where your repo is and I'll put a link up on the OP.


Should be up at:  svn://svn.mfis.net/btc/


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on June 29, 2011, 03:05:28 AM
oops, server load stat was was 100x too high, thanks jine for pointing that out.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Bullethead21 on June 29, 2011, 04:33:52 PM
Hi, building new forum server and was wondering which version of Pushpoold I should install that would work best with your fronttttt end latest release ver 2.0? Pushpoold has version 4.1 up to 5.1 available now?

Also, it looks like you got the stats page looking sweet now! I like the way it list the usernames and all the different data fields...awesome!

Cant wait to get your fron end installed. Have only bitcoind and pushpoold to install now as I have installed all dependencies....like jansson and the others....just wondering which version of pushpoold to compile and install?

Thanks!

Forgot to ask, how stable would your experimental version be on on a new install/build of a Ubuntu box version 11.04...there latest release? I mainly worry about the stats page displaying properly.....


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on June 29, 2011, 04:56:35 PM
pushpool v5, bitcoin v0.3.23 (or if you are comfortable compiling add the multi-thread diff from the 20btc bounty project page)


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Bullethead21 on June 30, 2011, 01:14:08 AM
Thanks, got everything up and running. Only problem is when I try and access the admin page I get a 500 error...I have set the flag to 1 in the database ....any idea why I get this error only when trying to access the admin panel?

Thanks!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on June 30, 2011, 07:07:38 AM
Thanks, got everything up and running. Only problem is when I try and access the admin page I get a 500 error...I have set the flag to 1 in the database ....any idea why I get this error only when trying to access the admin panel?

Thanks!

your best bet is to turn on display_errors in php.ini


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Bullethead21 on June 30, 2011, 11:05:59 AM
did that already.....got nothing. I dont get it...the file is there...the path is correct.

I also cant seem to get clients to connect .....is there anything else that needs to be done with the database to get clients to connect? Maybe you could clear up the pool workers username and password...what is with the "." ? When you setup rpc should you include the "."?
 
Example if my website username is bean and I want to create a pool worker called pea, why do I end up with a worker called "bean.pea"? And how should I set up my RPC config file to connect? With a username of bean.pea or just pea?

The way it is, is confusing.....please help


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on June 30, 2011, 07:05:10 PM
did that already.....got nothing. I dont get it...the file is there...the path is correct.

I also cant seem to get clients to connect .....is there anything else that needs to be done with the database to get clients to connect? Maybe you could clear up the pool workers username and password...what is with the "." ? When you setup rpc should you include the "."?
 
Example if my website username is bean and I want to create a pool worker called pea, why do I end up with a worker called "bean.pea"? And how should I set up my RPC config file to connect? With a username of bean.pea or just pea?

The way it is, is confusing.....please help

The workers contain "." so that worker logins are based on simplecoin usernames. This keep people from fighting over worker names and having to guess one that's not already taken.

the rpc user/pass only relates to bitcoin.conf, pushpool.conf, & requiredFunctions, not a simplecoin user. just pick a name/pass and make it match in all 3 places.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: AnnihilaT on July 01, 2011, 03:12:01 PM
Hi mike,

version 1 of my fork released:

MMCFE SVN - http://mmcfe.mfis.net  (Mainframe Mining Cooperative Front End)

Maybe you can update the original post with correct link and name of project?    

Anni


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 01, 2011, 06:06:36 PM
Hi mike,

version 1 of my fork released:

MMCFE SVN - http://mmcfe.mfis.net  (Mainframe Mining Cooperative Front End)

Maybe you can update the original post with correct link and name of project?    

Anni

Done! Too bad it's not a Git Fork.... it'd be too easy to move code back and forth. I'll peek around soon and see what to bring back from your fork.

Also: going to be adding bitcoin account locking, and email notifications.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: gnaget on July 02, 2011, 05:27:48 PM
I'm trying to get simplecoin setup for my private mining farm.  Following the instructions, I can get to the website now, but when I try to register a user, I get the following error in the log:

PHP Warning:  mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /home/gnaget/simplecoin/includes/settings.php on line 29

It says user was created, but the user does not exist in the webUsers table.

Any idea what I might have missed?


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: gnaget on July 02, 2011, 05:40:14 PM
my bad, forgot to grant access to mysql user


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: AnnihilaT on July 04, 2011, 08:56:32 PM
Hey Mike,

found a bit of a nasty one...at least from a stats perspective and could maybe even cause some mayhem with payouts:

------------------------------------------------------------------------
r18 | annihilat | 2011-07-04 22:54:36 +0200 (Mon, 04 Jul 2011) | 3 lines
Changed paths:
   M /trunk/www/accountdetails.php

- make sure the user cannot set a lower than 0% donation fee


------------------------------------------------------------------------

You might want to check into that.   :)

Ive fixed it simply by adding a less than 0 check and forcing it to 0 if true.  see below:

Code:
if($act == "updateDetails"){
                        //Update user's details
                        $newSendAddress = mysql_real_escape_string($_POST["paymentAddress"]);
                        $newDonatePercent = mysql_real_escape_string($_POST["donatePercent"]);
                        $newPayoutThreshold = mysql_real_escape_string($_POST["payoutThreshold"]);
                        if ($newPayoutThreshold > 25)
                                $newPayoutThreshold = 25;
                        if ($newPayoutThreshold < 1)
                                $newPayoutThreshold = 0;
                        if ($newDonatePercent < 0)
                                $newDonatePercent = 0;



Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Bullethead21 on July 04, 2011, 10:10:52 PM
Thanks! Got the clients to connect succesfully! Do you have an example of about how long or in how many minutes I should run each cronjob file? I know in the thread it states from 10 to 30 minutes but how about the workers.php one for example? I like the stats to update frequently but I do not want to create to much or uneeded database traffic either...

Thanks again for all your help!

Anyone else having issues accessing the admin page? I have my account flag set to 1 in the database? Cant seem to figure that one out.

Peace!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Bullethead21 on July 05, 2011, 06:35:37 AM
It seems also some of the cronjobs are failing with a exit code/status of 255?

Only 2 cronjobs I get these errors on is when payout.php is tried to be executed by cron and also cronjob.php gives me this error...the rest run without errors from cron....only those 2 php files cause this cron error with a exiting code/status of 255?

I looked at the directoryinclude and all the cronjob files are setup the same....why only those 2 error out?

Please help!

Thanks!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 05, 2011, 02:51:08 PM
Thanks! Got the clients to connect succesfully! Do you have an example of about how long or in how many minutes I should run each cronjob file? I know in the thread it states from 10 to 30 minutes but how about the workers.php one for example? I like the stats to update frequently but I do not want to create to much or uneeded database traffic either...

Thanks again for all your help!

Anyone else having issues accessing the admin page? I have my account flag set to 1 in the database? Cant seem to figure that one out.

Peace!

The key to the cron jobs is to space them out enough that it doesn't keep mysql bogged down. I've tried to space them out into separate files to help, but really I kept a watch on 'top' to try and keep the cpu/mem usage down.

as for the admin page not working, it could be a missing setting row in the settings table. turn errors on for a second and see if you can get an idea of the issue.

The 225 errors, never seen them, I'd check file owner/permissions.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 05, 2011, 03:30:48 PM
Hey Mike,

found a bit of a nasty one...at least from a stats perspective and could maybe even cause some mayhem with payouts:

------------------------------------------------------------------------
r18 | annihilat | 2011-07-04 22:54:36 +0200 (Mon, 04 Jul 2011) | 3 lines
Changed paths:
   M /trunk/www/accountdetails.php

- make sure the user cannot set a lower than 0% donation fee


------------------------------------------------------------------------

You might want to check into that.   :)

Ive fixed it simply by adding a less than 0 check and forcing it to 0 if true.  see below:

Code:
if($act == "updateDetails"){
                        //Update user's details
                        $newSendAddress = mysql_real_escape_string($_POST["paymentAddress"]);
                        $newDonatePercent = mysql_real_escape_string($_POST["donatePercent"]);
                        $newPayoutThreshold = mysql_real_escape_string($_POST["payoutThreshold"]);
                        if ($newPayoutThreshold > 25)
                                $newPayoutThreshold = 25;
                        if ($newPayoutThreshold < 1)
                                $newPayoutThreshold = 0;
                        if ($newDonatePercent < 0)
                                $newDonatePercent = 0;


Thanks, it's in the experimental branch now :)


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Bullethead21 on July 05, 2011, 05:07:43 PM
Will try that out again and see if I can get it to give me something other than internal server error 500 which is what I usually get.....is there a way I can check my tables for something missing maybe? I imported the .sql file included in the download with no errors. Was there any additional steps I needed to take maybe in creating any extra tables possibly?

Thanks again Mike! You can expect a donation for sure! Awseome stuff!

Peace!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 05, 2011, 05:23:54 PM
Will try that out again and see if I can get it to give me something other than internal server error 500 which is what I usually get.....is there a way I can check my tables for something missing maybe? I imported the .sql file included in the download with no errors. Was there any additional steps I needed to take maybe in creating any extra tables possibly?

Thanks again Mike! You can expect a donation for sure! Awseome stuff!

Peace!

There shouldn't be anything I missed in the v2 sql. That admin page loves to give errors though.... Since I usually change things in sql, sometimes little admin things slip through.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 06, 2011, 10:42:47 PM
Looks like BurningToad is going to share his MaxPPS code, so hopefully we'll have MaxPPS as a payout option soon.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Kris on July 06, 2011, 11:45:23 PM
Nice initiative, if I didn't have to pay so many damn bills Ill probably open-source mine as well.

Tell me if you need help with anything.

Kind regards
Kris


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Rob P. on July 07, 2011, 12:24:56 PM
Mike,

Been a lurker on the thread, and now trying to setup Simplecoin.

I have everything working, and in fact, my tests with one of my rigs appears to be working fine.

However, I cannot load the Admin Panel.  I have the link on my login, but when clicked it's a blank page and I get this error in the Apache error.log:

Code:
[Thu Jul 07 02:36:39 2011] [error] PHP Parse error:  syntax error, unexpected T_VARIABLE in /htdocs/adminPanel.php on line 43

Any thoughts, that line in my version of the code is:

Code:
        //Make sure an authPin is set and valid when $act is active^M
        if($_POST["act"] && $_$authPin == $inputAuthPin){

I'm thinking it doesn't think my account has a valid $authPin?  But it does...  Am I missing something?



Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: AnnihilaT on July 07, 2011, 12:54:58 PM
Mike,

Been a lurker on the thread, and now trying to setup Simplecoin.

I have everything working, and in fact, my tests with one of my rigs appears to be working fine.

However, I cannot load the Admin Panel.  I have the link on my login, but when clicked it's a blank page and I get this error in the Apache error.log:

Code:
[Thu Jul 07 02:36:39 2011] [error] PHP Parse error:  syntax error, unexpected T_VARIABLE in /htdocs/adminPanel.php on line 43

Any thoughts, that line in my version of the code is:

Code:
       //Make sure an authPin is set and valid when $act is active^M
        if($_POST["act"] && $_$authPin == $inputAuthPin){



typo in your code (or mikes).   Change $_$authPin to $authPin




Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Rob P. on July 07, 2011, 01:17:23 PM
Typo in your code (or mikes).   Change $_$authPin to $authPin
I'm thinking it doesn't think my account has a valid $authPin?  But it does...  Am I missing something?

I should have caught that.  Thank you, that fixed it.

That typo is in "simplecoin-simplecoin-v2.0-0-g361c13d.tar.gz", that's the rev I pulled.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 07, 2011, 01:37:21 PM
Nice catch. The salting in the OS version is slightly different than my sites implementation (hooray obscurity!). Fixing in repo now.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: sergio on July 08, 2011, 05:38:19 AM
Great job, for simplecoin.

One thing that is important to know is that security by obscurity is a very bad thing, most of the times there are problems with the design and even when the design of the algorithm is good, there are security holes that go undetected until the cracker finds out.

Open source security algorithms are the best, for example take a look at the security of the bitcoin network, it is very solid, and in the rare event that a security was found most likely it would be in the implementation and it would be fixed within hours.

There are a lot of commercial security closed source programs that use the vigenere cipher, of course that is a secret, the vigenere cipher is very easy to implement and it provides security against the average person, but by design it is insecure, it is used a lot due to its simplicity,  in closed source it is very hard to tell it uses the vigenere chipher, until someone does some reverse engineering, and after that the security completely colapses, any good cracker will crack the algorithm no very easy but doable. There are other algorithm that are also very simple and easy to implement used in closed source programs like rot13, or substitution cipher both very insecure and worse than vigenere.

Then there the famous one time pad very secure only algorithm proven to be unbreakable but also not very practical.

The there are the good ones, but more complex idea, rsa, blowfish, etc, these can only be broken by brute force attacks, extremely difficult specially is the keys are large.

I used to be a cryptographer in the mid 90, so I am not up to date with the latest algorithms, but one thing I learned is that most close source packages are very insecure, and there are packages that break the security of those closed source programs, there was a programmer I do not remember his name that wrote software to unlock the locks, he was arrested in las vegas by the fbi after he gave a conference in defcon, he would talk a lot about insecure close source software with mathematical proofs, he sold unlock software for most closed source commerical packages.

The lesson to be learned is that for the most security it is best to rely on a good algorithm, and not by security by obscurity, therefore most secure algorithms are usually open source. In theory if a person is a brilliant genius a close source security software could be secure, but for most of us, and most real world cases, open source is the way to go for security.

In many companies managers believe on closed source, the only reason for that is ignorance, they are usually not cryptographers, and know very little about programming, when working for a company like that vigenere cipher is great makes the manager happy and you are done quickly with the job, but for a job well done it is all in the algorithm and its implementation  and it takes more work when you have security in mind.





 


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 08, 2011, 06:45:03 AM
It's not really different for obscurity, but moreso that I used a different algorithm when I setup my initial site before open-sourcing it.

I just haven't gotten around to changing it ;)


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: ziomik on July 09, 2011, 01:03:13 PM
Hi,
my server error in /var/log/apache2/error.log
Statistics on the site are empty.
Thank's for help.

Code:
[Sat Jul 09 14:27:48 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/accountdetails.php
[Sat Jul 09 14:29:33 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/accountdetails.php
[Sat Jul 09 14:29:46 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/accountdetails.php
[Sat Jul 09 14:30:11 2011] [error] [client xx.xx.xx.xx] PHP Notice:  Undefined variable: cookieName in /var/www/includes/universalChecklogin.php on line 23, referer: http://xx.xx.xx.xx/includes/
[Sat Jul 09 14:35:51 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/accountdetails.php
[Sat Jul 09 14:35:59 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/my_stats.php
[Sat Jul 09 14:39:31 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/accountdetails.php
[Sat Jul 09 14:43:12 2011] [error] [client xx.xx.xx.xx] PHP Parse error:  syntax error, unexpected T_VARIABLE in /var/www/adminPanel.php on line 42, referer: http://xx.xx.xx.xx/index.php
[Sat Jul 09 14:43:39 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/index.php
[Sat Jul 09 14:43:42 2011] [error] [client xx.xx.xx.xx] PHP Warning:  mysql_data_seek(): Offset 0 is invalid for MySQL result index 28 (or the query data is unbuffered) in /var/www/stats.php on line 353, referer: http://xx.xx.xx.xx/index.php

and error cron log syslog:
Code:
Jul  9 15:50:01 bitcoinitalia CRON[11981]: (root) CMD (/var/www/cronjobs/cronjob.php)
Jul  9 15:50:01 bitcoinitalia CRON[11980]: (root) CMD (/var/www/cronjobs/archive.php)
Jul  9 15:50:01 bitcoinitalia CRON[11978]: (CRON) error (grandchild #11981 failed with exit status 126)
Jul  9 15:50:01 bitcoinitalia CRON[11979]: (CRON) error (grandchild #11980 failed with exit status 126)


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: openrune on July 10, 2011, 02:52:52 AM
hey everyone

when i cronjob any of the cronjob php files manualy trough command line i get this error:

Code:
Cannot load the ionCube PHP Loader - it was built with configuration 2.2.0, whereas running engine is API220090626,NTS

Deprecated: Directive 'register_long_arrays' is deprecated in PHP 5.3 and greater in Unknown on line 0

Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0

Deprecated: Directive 'magic_quotes_gpc' is deprecated in PHP 5.3 and greater in Unknown on line 0

There is an other bug in the Admin Page, its not possible to change any value since the pin nbr dnt gets accepted, but it works fine on the account details site
We have allso a bug since the first block was found on the stats.php:

Code:
Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in .../httpdocs/stats.php on line 298
where the blocks per week box was.

on news.php:
Code:
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in .../httpdocs/news.php on line 25
on users.php
Code:
Warning: include() [function.include]: Filename cannot be empty in .../httpdocs/users.php on line 82

Warning: include() [function.include]: Failed opening '' for inclusion (include_path='.:') in .../httpdocs/users.php on line 82

Since the block was found it isnt possible to see the personal stats page anymore, and the left sidebar keeps counting on the same block even when the block is allready shown as found






Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 10, 2011, 07:08:09 PM
Ok, btc account locking is now in the experimental repo. You will need to add an enum field to webUsers: btc_lock (0,1) and the locks table (fields - varchar: name, tinyint locked) if you wish to use it.


To answer the issues:

Statistics on the site are empty.

Without the cronjobs running, there will be no stats. Do you have pushpool/bitcoind up and running?

when i cronjob any of the cronjob php files manualy trough command line i get this error:

Code:
Cannot load the ionCube PHP Loader - it was built with configuration 2.2.0, whereas running engine is API220090626,NTS

Deprecated: Directive 'register_long_arrays' is deprecated in PHP 5.3 and greater in Unknown on line 0

Deprecated: Directive 'safe_mode' is deprecated in PHP 5.3 and greater in Unknown on line 0

Deprecated: Directive 'magic_quotes_gpc' is deprecated in PHP 5.3 and greater in Unknown on line 0
I'm not familiar with ionCube PHP. I recommend running the cronjobs using wget through your apache interface.

Quote
There is an other bug in the Admin Page, its not possible to change any value since the pin nbr dnt gets accepted, but it works fine on the account details site

This issue should be fixed in the experimental branch.

Quote
We have allso a bug since the first block was found on the stats.php:

Code:
Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in .../httpdocs/stats.php on line 298
where the blocks per week box was.

on news.php:
Code:
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in .../httpdocs/news.php on line 25
on users.php
Code:
Warning: include() [function.include]: Filename cannot be empty in .../httpdocs/users.php on line 82

Warning: include() [function.include]: Failed opening '' for inclusion (include_path='.:') in .../httpdocs/users.php on line 82

Since the block was found it isnt possible to see the personal stats page anymore, and the left sidebar keeps counting on the same block even when the block is allready shown as found


I'll look into this.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: openrune on July 10, 2011, 10:47:33 PM
Quote
There is an other bug in the Admin Page, its not possible to change any value since the pin nbr dnt gets accepted, but it works fine on the account details site

This issue should be fixed in the experimental branch.

This solved it perfectly thank you!

But i discovered an other problem when i run cronjob.php:
Code:
Fatal error: Uncaught BitcoinClientException: [0]: Didn't receive 200 OK from remote server. (HTTP/1.1 404 Not Found) thrown in on line 0

guess thats why the mine keeps counting on the same block!

I use pushpool 5 and bitcoin 0.3.23
The rpc values works with the requiredFunctions.php i can see on the stats page difficulty and blockcount etc.. just the cronjob.php gives me the 200 error


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 10, 2011, 11:31:33 PM
hmm, it should be getting 200 transactions from the server. you can take the other parameters out and just leave in the listtransactions call. The only downfall to this is if you get too many transactions it knocks it off the list.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: openrune on July 11, 2011, 12:38:02 AM
I deleted the additional parameters but that didnt solve the problem, i usualy had this error with the miningfarm from xenland, but in that case was a wrong rpc value the problem.

I cheched requiredFunctions.php if the values are correct what they indeed are. So there is probably just a small bug what doesnt allows the cronjob.php to communicate with bitcoind.

The right include path is set aswell in the cronjobs.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 11, 2011, 01:30:50 AM
I deleted the additional parameters but that didnt solve the problem, i usualy had this error with the miningfarm from xenland, but in that case was a wrong rpc value the problem.

I cheched requiredFunctions.php if the values are correct what they indeed are. So there is probably just a small bug what doesnt allows the cronjob.php to communicate with bitcoind.

The right include path is set aswell in the cronjobs.

It sounds like a possible server issue. Are you running this on a typical linux/apache/mysql setup?


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: openrune on July 11, 2011, 01:38:06 AM
yes - debian lenny apache2 php5.3,

I tested the cronjob.php from ivasilov's github if there is a btc comunication problem (200 OK ) and that one works with out any error but ofcourse i dnt get a result...




Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 11, 2011, 03:35:41 AM
yes - debian lenny apache2 php5.3,

I tested the cronjob.php from ivasilov's github if there is a btc comunication problem (200 OK ) and that one works with out any error but ofcourse i dnt get a result...




Sorry I haven't had the chance to chat, it's been a busy day.

What version of simplecoin are you using? 1,2,experimental? I'm looking at the experimental code personally.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: openrune on July 11, 2011, 08:45:36 AM
Im using the 2 version with some adjustments (for example Admin is taken from the experimental) but that has nothing in common with the problem since this problem was there before i did the update from the admin page to experimental


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: coingenuity on July 11, 2011, 10:59:29 AM
Very nice project! I'll keep an eye on this project's progress, and probably use it + donate if I ever start a pool. :)


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: somebadger on July 11, 2011, 02:31:17 PM
congrats on simplecoin, i'm running a varient of it on pool.betcoin.co with a bunch of wayno's modifications and a large mix of my own :)

I'll be donating to both you and wayno once we solve a block, keep up the good work.

If you want the code for my cacheable images, let me know.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 11, 2011, 04:51:09 PM
congrats on simplecoin, i'm running a varient of it on pool.betcoin.co with a bunch of wayno's modifications and a large mix of my own :)

I'll be donating to both you and wayno once we solve a block, keep up the good work.

If you want the code for my cacheable images, let me know.

Of course I want the code for cacheable images :) I plan on having everything cacheable, it's just a matter of available time.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: smoothie on July 15, 2011, 07:30:33 AM
Wish I could get pushpoold to work. I keep hitting every possible roadblock.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Rob P. on July 15, 2011, 12:28:55 PM
Wish I could get pushpoold to work. I keep hitting every possible roadblock.

Very helpful.  With the thorough amount of detail you've provided, I'm sure we'll have you up and running in no time!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: smoothie on July 15, 2011, 05:42:30 PM
Wish I could get pushpoold to work. I keep hitting every possible roadblock.

Very helpful.  With the thorough amount of detail you've provided, I'm sure we'll have you up and running in no time!

Hey jack-wagon, I've posted Here --> http://forum.bitcoin.org/index.php?topic=10321.0 multiple times.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Rob P. on July 15, 2011, 07:42:45 PM
Hey jack-wagon, I've posted Here --> http://forum.bitcoin.org/index.php?topic=10321.0 multiple times.

Huh, and you're not getting help?  How odd.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 16, 2011, 12:06:49 AM
Sorry for the delays in new code, just trying to implement a handful of new features.

I was going to call this next release 2.1, but since it affects so much it'll be 3.0.


Title: SIMPLECOIN AND MININGFARM COOPERATION
Post by: openrune on July 16, 2011, 07:03:33 PM
Hello all, after the last weeks expirience with both miningpools the miningfarm 5.0 and the simplcoin frontend, i realized that i would love to have both merged together; so here is my suggestion;

Why dnt use the miningfarm 5 database and cronjobs, the nice charts and combine it with the details that simplecoin provides on the stats page. The miningfarm 5 database is quite stable, of course everything can be more optimized.

At least for the Stats i see quite i nice result from the programming cooperation of this two projects


Tenobis
http://mine.tenobis.com/




The code is here
https://github.com/Xenland/MiningFarm/


Title: Re: SIMPLECOIN AND MININGFARM COOPERATION
Post by: simplecoin on July 17, 2011, 07:30:41 AM
Hello all, after the last weeks expirience with both miningpools the miningfarm 5.0 and the simplcoin frontend, i realized that i would love to have both merged together; so here is my suggestion;

Why dnt use the miningfarm 5 database and cronjobs, the nice charts and combine it with the details that simplecoin provides on the stats page. The miningfarm 5 database is quite stable, of course everything can be more optimized.

At least for the Stats i see quite i nice result from the programming cooperation of this two projects


Tenobis
http://mine.tenobis.com/




The code is here
https://github.com/Xenland/MiningFarm/

If you wish to merge them, you are more than welcome. Both codebases have moved in different directions and have slightly different licensing now.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: Paul4games on July 17, 2011, 10:24:01 AM
Simplecoin i'll wait until you release the version 3 and after that i will report some security bugs, i won\t report them now ebcause i have to talk with an friend to help me to exploit an possible SQLi.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 18, 2011, 03:00:38 PM
Simplecoin i'll wait until you release the version 3 and after that i will report some security bugs, i won\t report them now ebcause i have to talk with an friend to help me to exploit an possible SQLi.

Please pm me with any security concerns, so I can ensure they reach the codebase quickly.

As for sql injection, I've run quite a few products against the code with no injection vulnerabilities found.

Security is priority one, I will fix known exploits before implementing new features.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: froggy on July 18, 2011, 06:26:18 PM
Are there any good products you'd recommend to check for sql injection vulnerability?  I've seen the SQL Inject Me Firefox addon at https://addons.mozilla.org/en-US/firefox/addon/sql-inject-me/   - seems to be marked as Experimental though, so not quite confident about using that.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 18, 2011, 07:39:15 PM
Are there any good products you'd recommend to check for sql injection vulnerability?  I've seen the SQL Inject Me Firefox addon at https://addons.mozilla.org/en-US/firefox/addon/sql-inject-me/   - seems to be marked as Experimental though, so not quite confident about using that.

acunetix has a thorough security package.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: mich on July 19, 2011, 09:56:47 AM
"Past shares" and "Past invalid" takes values after finding block only? In table "Top 30 Lifetime Shares" column "Shares" is 0. It is correct, in case of Round shares already much more then 0?

Update Main Page Settings does not work in Admin Panel :(


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 19, 2011, 03:36:57 PM
"Past shares" and "Past invalid" takes values after finding block only? In table "Top 30 Lifetime Shares" column "Shares" is 0. It is correct, in case of Round shares already much more then 0?

Update Main Page Settings does not work in Admin Panel :(

Yes, past is relative to shares before current round. This avoids a nasty amount of sql overhead.
I'll have Admin Panel working again shortly.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: mich on July 19, 2011, 05:23:31 PM


Yes, past is relative to shares before current round. This avoids a nasty amount of sql overhead.
I'll have Admin Panel working again shortly.
[/quote]

I've change default value "NULL" in table 'webUsers' col's 'share_count' and 'stale_share_count' to 0 - now table shows current shares


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 19, 2011, 05:44:42 PM


Yes, past is relative to shares before current round. This avoids a nasty amount of sql overhead.
I'll have Admin Panel working again shortly.

I've change default value "NULL" in table 'webUsers' col's 'share_count' and 'stale_share_count' to 0 - now table shows current shares
[/quote]

Good to know. I had solved shares before this was implemented, so it never came up.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: mich on July 21, 2011, 04:57:55 PM
Button "Lost Password" is there just for anturage? I haven't found any code serves this event...


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 21, 2011, 05:38:08 PM
Button "Lost Password" is there just for anturage? I haven't found any code serves this event...

It's just a relic from mining pool v1.... Looks like it was a stub. I'll get to it in the next version.

Which reminds me....

v3 features not yet in repo:
Memcached support
No more shares_history (what a nightmare that was)
Improved block handling.
Dynamic stats/setting caching (more responsive/less overhead)
Process locking
Drastically improved cronjobs.
Live round stats.
Just to name a few improvements....


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: AnnihilaT on July 22, 2011, 08:53:48 AM
Button "Lost Password" is there just for anturage? I haven't found any code serves this event...

It's just a relic from mining pool v1.... Looks like it was a stub. I'll get to it in the next version.

Which reminds me....

v3 features not yet in repo:
Memcached support
No more shares_history (what a nightmare that was)
Improved block handling.
Dynamic stats/setting caching (more responsive/less overhead)
Process locking
Drastically improved cronjobs.
Live round stats.
Just to name a few improvements....


Looking forward to seeing how you have tackled this.... im in the midst of dealing with these same issues... especially the whole shares_history nightmare and the associated monster queries.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: simplecoin on July 22, 2011, 04:32:51 PM
Button "Lost Password" is there just for anturage? I haven't found any code serves this event...

It's just a relic from mining pool v1.... Looks like it was a stub. I'll get to it in the next version.

Which reminds me....

v3 features not yet in repo:
Memcached support
No more shares_history (what a nightmare that was)
Improved block handling.
Dynamic stats/setting caching (more responsive/less overhead)
Process locking
Drastically improved cronjobs.
Live round stats.
Just to name a few improvements....


Looking forward to seeing how you have tackled this.... im in the midst of dealing with these same issues... especially the whole shares_history nightmare and the associated monster queries.

Good news then.... I just pushed the initial v3 to the expiremental repo. This is no upgrade script, nor a simple upgrade path... yet. You'll need to merge these as appropriate.

As for moving shares history back into shares (AFTER adding new shares fields), I used this sql:
INSERT INTO shares (username, our_result, time, blockNumber, score) SELECT username, our_result, time, blockNumber, score FROM shares_history WHERE shares_history.counted = '0'

Also, I recommend using a separate instance of memcache than pushpool. Don't want your pool cache eaten by web data.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: oseido on July 26, 2011, 12:33:38 PM
Hi to all.
We are very impressive about Simplecoin Pushpool Web Frontend. We have start an italian minig pool with this amazing opensource software, and we are in testig. We are also meditating to enable ssl support, but because certificate was self-signed (we have a L.A.M.P system redyrected on dyndns.org) we are finding a way for make certificate not affected about the orrible browser ssl self-signed warning.
We hope tath people can test the server.
Tnx a lot for simplecoin again!!

oseido

Chemtrail Italia Cooperative Bitcoin Mining Pool

http://chemtrail.dyndns.org:8080/
Mining Port = 8332


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on July 26, 2011, 03:06:45 PM
Added a forum for discussion and support since I'm often afk in irc. Feel free to give your fellow admins help and share your solutions.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on July 27, 2011, 09:00:33 PM
More updates to v3 pushed to repo.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on July 28, 2011, 09:49:28 PM
Just added capability to offload heavy stats to replicated server (less stress on your pool sql server).


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: Paul4games on August 04, 2011, 02:12:34 PM
Siplecoin here is a feature request:
-add an api so that an application could create an new worker when he wants(for example you have 5 computers and you want to create an application that when it's run on that computer it will automatically create an new username+password from that computer+link it to you're account, for example that worker to be linked to my account or so)&retrive them from the server.Or if i'm mining with 2 pcs and using the same username+password is there any problem?or this would work to?


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on August 04, 2011, 07:58:34 PM
Siplecoin here is a feature request:
-add an api so that an application could create an new worker when he wants(for example you have 5 computers and you want to create an application that when it's run on that computer it will automatically create an new username+password from that computer+link it to you're account, for example that worker to be linked to my account or so)&retrive them from the server.Or if i'm mining with 2 pcs and using the same username+password is there any problem?or this would work to?

While the idea sounds great, it's also seems like it might add an exploit.

However, you can use the same miner name/pass on multiple workers.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: Paul4games on August 04, 2011, 09:35:27 PM
Siplecoin here is a feature request:
-add an api so that an application could create an new worker when he wants(for example you have 5 computers and you want to create an application that when it's run on that computer it will automatically create an new username+password from that computer+link it to you're account, for example that worker to be linked to my account or so)&retrive them from the server.Or if i'm mining with 2 pcs and using the same username+password is there any problem?or this would work to?

While the idea sounds great, it's also seems like it might add an exploit.

However, you can use the same miner name/pass on multiple workers.
Could you please explain futher what exploit it could add?and i see that you fixed the full path disclousure bugs, good job!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0 Opensource PHP/MySQL
Post by: phorensic on August 04, 2011, 10:32:51 PM
Button "Lost Password" is there just for anturage? I haven't found any code serves this event...

It's just a relic from mining pool v1.... Looks like it was a stub. I'll get to it in the next version.

Which reminds me....

v3 features not yet in repo:
Memcached support
No more shares_history (what a nightmare that was)
Improved block handling.
Dynamic stats/setting caching (more responsive/less overhead)
Process locking
Drastically improved cronjobs.
Live round stats.
Just to name a few improvements....


Looking forward to seeing how you have tackled this.... im in the midst of dealing with these same issues... especially the whole shares_history nightmare and the associated monster queries.

Good news then.... I just pushed the initial v3 to the expiremental repo. This is no upgrade script, nor a simple upgrade path... yet. You'll need to merge these as appropriate.

As for moving shares history back into shares (AFTER adding new shares fields), I used this sql:
INSERT INTO shares (username, our_result, time, blockNumber, score) SELECT username, our_result, time, blockNumber, score FROM shares_history WHERE shares_history.counted = '0'

Also, I recommend using a separate instance of memcache than pushpool. Don't want your pool cache eaten by web data.

This is interesting.  Can you explain further why you axed shares_history and what shares_counted is for?  Is it just a lighter version of shares_history?  How big does your original shares table get?  I mean, where are your old shares held?  I also noticed shares_counted is MyISAM instead of InnoDB, is that because it's a temporary table?


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on August 05, 2011, 04:32:57 AM
Shares history was essentially an extension of shares, but it required lots of additional joins and unions. It made queries painfully processor intensive when they didn't need to be.

Shares counted is the counted sum of valid/invalid shares per round.

As for MyIsam, that was an oversight, I'll fix that before the code is finalized.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: phorensic on August 05, 2011, 08:13:34 AM
How does your new setup query faster if "sahres" is larger than two tables - "shares" and "shares_history"...besides indexing.  Xenland and I have discussed and applied indexing to our setups, so I'm curious.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on August 05, 2011, 05:11:22 PM
shares is only as large as the current round. Why split that data into 2 tables, when you need to join or union them every time?

after the current round confirms I condense the shares into shares_counted to drastically lower the amount of data.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: phorensic on August 07, 2011, 04:37:20 PM
Hmm, you must have been using shares_history different that I am.  My "shares" is only as large as the current round, old round gets cut and pasted into history.  Never have to do joins or unions.

So you throw away the hash data for shares counted?  I haven't been brave enough to do that on my history.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on August 07, 2011, 06:35:15 PM
Hmm, you must have been using shares_history different that I am.  My "shares" is only as large as the current round, old round gets cut and pasted into history.  Never have to do joins or unions.

So you throw away the hash data for shares counted?  I haven't been brave enough to do that on my history.

I do, once it the round is paid out it's already been verified. I don't see much historical value in past blocks outside of share counts and block finder.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on August 10, 2011, 12:19:25 AM
Holy incoming updates!

I may have to deem this release 4.0 because the changes are that drastic!


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: Paul4games on August 10, 2011, 09:51:21 AM
Holy incoming updates!

I may have to deem this release 4.0 because the changes are that drastic!
Looking forward for this update.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: sareea on August 10, 2011, 06:18:34 PM
Hello,
When will you release the new updated version ? And will it have sql injection security ?
I really wanna use simplecoin , and if i install the current one is it upgradable to 4 ? I am looking up to open my pool today or tomorrow .
Please answer me :) Thanks !


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on August 10, 2011, 06:22:29 PM
Hello,
When will you release the new updated version ? And will it have sql injection security ?
I really wanna use simplecoin , and if i install the current one is it upgradable to 4 ? I am looking up to open my pool today or tomorrow .
Please answer me :) Thanks !

Currently there will not be an easy upgrade path from 2-4. The database changes are drastic.
Version 2 should have sql injection security as should the expirimental branch in the repository.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: sareea on August 10, 2011, 06:25:31 PM
Hello,
When will you release the new updated version ? And will it have sql injection security ?
I really wanna use simplecoin , and if i install the current one is it upgradable to 4 ? I am looking up to open my pool today or tomorrow .
Please answer me :) Thanks !

Currently there will not be an easy upgrade path from 2-4. The database changes are drastic.
Version 2 should have sql injection security as should the expirimental branch in the repository.
So what do you suggest ?
I wanna work with simplecoin !! :)


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: simplecoin on August 10, 2011, 06:44:57 PM
Hello,
When will you release the new updated version ? And will it have sql injection security ?
I really wanna use simplecoin , and if i install the current one is it upgradable to 4 ? I am looking up to open my pool today or tomorrow .
Please answer me :) Thanks !

Currently there will not be an easy upgrade path from 2-4. The database changes are drastic.
Version 2 should have sql injection security as should the expirimental branch in the repository.
So what do you suggest ?
I wanna work with simplecoin !! :)

I'm ironing out the last bits now. I'll have v4 in the repository soon enough.


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: sareea on August 10, 2011, 06:54:44 PM
Hello,
When will you release the new updated version ? And will it have sql injection security ?
I really wanna use simplecoin , and if i install the current one is it upgradable to 4 ? I am looking up to open my pool today or tomorrow .
Please answer me :) Thanks !

Currently there will not be an easy upgrade path from 2-4. The database changes are drastic.
Version 2 should have sql injection security as should the expirimental branch in the repository.
So what do you suggest ?
I wanna work with simplecoin !! :)

I'm ironing out the last bits now. I'll have v4 in the repository soon enough.
OOOO ok i will wait man :)


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: mich on August 11, 2011, 06:18:05 AM
Just testing new 3rd version, and got this mistakes:

Warning: array_key_exists() expects parameter 2 to be array, boolean given in /var/www/includes/stats.php on line 150

Warning: Division by zero in /var/www/includes/header.php on line 99

PS: It was until pool accept shares from worker.
PPS: When no one worker conected the same mistakes ((((


Title: Re: [Pushpool Web Frontend] Simplecoin v2.0(v3 experimental) Opensource PHP/MySQL
Post by: sareea on August 11, 2011, 05:14:45 PM
Any updates Simplecoin ? i am very curious about this :)
Thanks !


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 11, 2011, 07:24:40 PM
Version 4 is now in the master and experimental branches!

There is no clear upgrade path from 2.0-4.0, It would be faster to migrate the shares/user data over manually than to rely on a script that may take hours to run.

Additionally version 4 is not without a few bugs, but overall it is more stable and usable than version 2 or 3.

There is a known issue with the stats, share count doesn't seem to be going up. This doesn't affect payout, just a quirk with the stats page.


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on August 11, 2011, 09:12:19 PM
The other files of the script are not running, all i see is a white screen , all i see is the header and thats it . nothing else .

I am checking what is not installed , i am having everything being running fine .

Please help !
Code:
[Fri Aug 12 16:11:18 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62

[Fri Aug 12 16:11:19 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/register.php

[Fri Aug 12 16:11:21 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/stats.php

PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/gettingstarted.php

[error] [client 58.218.199.22
7] script '/var/www/proxyheader.php' not found or unable
 to stat

[Fri Aug 12 16:10:52 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/register.php

[Fri Aug 12 16:11:13 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/register.php

[Fri Aug 12 16:11:16 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/register.

] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/about.php

[Fri Aug 12 16:10:49 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/about.php

[Fri Aug 12 16:10:51 2011] [error] [client 109.66.112.62
] PHP Warning:  fopen(/var/www/api/pool/speed): failed t
o open stream: No such file or directory in /var/www/inc
ludes/stats.php on line 62, referer: http://78.47.162.16
4/stats.php

What are these ?


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on August 12, 2011, 01:28:19 PM
I checked in this file
https://github.com/simplecoin/simplecoin/blob/master/includes/stats.php

and i think the source of this is here : ( it is true that this file doesn't exist :S )
Code:
setCache("pool_hashrate", $currenthashrate, 300);
try {
$fileName = "/var/www/api/pool/speed";
$fileHandle = fopen($fileName, 'w') or die("can't open file");
fwrite($fileHandle, ($currenthashrate/1000));
fclose($fileHandle);
} catch (Exception $e) {
//echo $e->getMessage();
}

Sorry for the double post


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 12, 2011, 03:49:12 PM
it's a hashrate file used by stats sites.

make the missing directory.  ;)


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on August 12, 2011, 04:36:52 PM
speed is a file or a directory ?
Thanks
Can you take a look please?
http://78.47.162.164/

And should i uncomment this line ?
//echo $e->getMessage();


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 14, 2011, 05:01:28 AM
speed is a file or a directory ?
Thanks
Can you take a look please?
http://78.47.162.164/

And should i uncomment this line ?
//echo $e->getMessage();

Speed is a file, generated by stats, you can stop it's creation in incudes/stats.php if you wish.


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: DiamondPlus on August 15, 2011, 01:34:41 AM
Great job, for simplecoin.

One thing that is important to know is that security by obscurity is a very bad thing, most of the times there are problems with the design and even when the design of the algorithm is good, there are security holes that go undetected until the cracker finds out.

-DiamondPlus

Open source security algorithms are the best, for example take a look at the security of the bitcoin network, it is very solid, and in the rare event that a security was found most likely it would be in the implementation and it would be fixed within hours.

There are a lot of commercial security closed source programs that use the vigenere cipher, of course that is a secret, the vigenere cipher is very easy to implement and it provides security against the average person, but by design it is insecure, it is used a lot due to its simplicity,  in closed source it is very hard to tell it uses the vigenere chipher, until someone does some reverse engineering, and after that the security completely colapses, any good cracker will crack the algorithm no very easy but doable. There are other algorithm that are also very simple and easy to implement used in closed source programs like rot13, or substitution cipher both very insecure and worse than vigenere.

Then there the famous one time pad very secure only algorithm proven to be unbreakable but also not very practical.

-DiamondPlus

The there are the good ones, but more complex idea, rsa, blowfish, etc, these can only be broken by brute force attacks, extremely difficult specially is the keys are large.

I used to be a cryptographer in the mid 90, so I am not up to date with the latest algorithms, but one thing I learned is that most close source packages are very insecure, and there are packages that break the security of those closed source programs, there was a programmer I do not remember his name that wrote software to unlock the locks, he was arrested in las vegas by the fbi after he gave a conference in defcon, he would talk a lot about insecure close source software with mathematical proofs, he sold unlock software for most closed source commerical packages.

-DiamondPlus

The lesson to be learned is that for the most security it is best to rely on a good algorithm, and not by security by obscurity, therefore most secure algorithms are usually open source. In theory if a person is a brilliant genius a close source security software could be secure, but for most of us, and most real world cases, open source is the way to go for security.

In many companies managers believe on closed source, the only reason for that is ignorance, they are usually not cryptographers, and know very little about programming, when working for a company like that vigenere cipher is great makes the manager happy and you are done quickly with the job, but for a job well done it is all in the algorithm and its implementation  and it takes more work when you have security in mind.

-DiamondPlus


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Lolcust on August 18, 2011, 09:29:03 AM
Hey, just a quick question - are there "noob-friendly" instructions on how to set this baby up, and what are the approximate sys.reqirements (how big a VPS would I need to play around with this baby) ?


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 18, 2011, 02:06:04 PM
Hey, just a quick question - are there "noob-friendly" instructions on how to set this baby up, and what are the approximate sys.reqirements (how big a VPS would I need to play around with this baby) ?

No, there are currently no noob-friendly instructions. In fact, I don't recommend anyone trying to setup a public pool without significant development and network knowledge.

For a small pool a 1gb-2core vps might suffice.

I run my install on 4 servers. 1x8core sql, 1x8core pool, 2x2core web & replication


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Lolcust on August 18, 2011, 03:19:20 PM
Hey, just a quick question - are there "noob-friendly" instructions on how to set this baby up, and what are the approximate sys.reqirements (how big a VPS would I need to play around with this baby) ?

No, there are currently no noob-friendly instructions. In fact, I don't recommend anyone trying to setup a public pool without significant development and network knowledge.

For a small pool a 1gb-2core vps might suffice.

I run my install on 4 servers. 1x8core sql, 1x8core pool, 2x2core web & replication

Well, you see, I am contemplating  the creation of a somewhat audacious bitcoin fork, and the way it seems to be coming out, it would be best if it had a pool at "day zero". Thing is, I'm not very rich (otherwise I would have hired a decent coder instead of trying to recall the long foregone days when I tried to learn the mysterious art of making computers do my bidding ;) )

I might convince a close friend to start up a virtualbox vm with 1+ gb RAM on her box in the beginning, but she will likely eventually kill it so she can play Crysis and that other popular shooty thing with more comfort.
Thus, I am looking into possibility of renting a relatively frugal VM for the purpose of my experiment.


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Paul4games on August 19, 2011, 09:50:37 AM
Simplecoin i have some questions:
1.Am i allowed to mine from different ips(i mean if i'm running 4 rigs i don't want them to get banned because of different ips or so)?
2.If i'm not allowedt o mine form more ips, tell me what's the limit(i mean like 2 ips per worker or 1 ip per worker)?


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 19, 2011, 05:00:52 PM
Simplecoin i have some questions:
1.Am i allowed to mine from different ips(i mean if i'm running 4 rigs i don't want them to get banned because of different ips or so)?
2.If i'm not allowedt o mine form more ips, tell me what's the limit(i mean like 2 ips per worker or 1 ip per worker)?


That is based on the pool software you use. My frontend is only for the web. The only IP restriction is one ip logged into the web server at a time, none of this will cause a ban.


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on August 20, 2011, 09:15:46 AM
Hello,
I am getting these warnings

Code:
] PHP Warning:  Invalid argument supplied for foreach()
in /var/www/includes/stats.php on line 89

and
Code:
] PHP Warning:  Invalid argument supplied for foreach()
in /var/www/stats.php on line 75

[Sat Aug 13 11:47:01 2011] [error] [client 84.228.254.88
] PHP Fatal error:  Call to a member function fetch() on
 a non-object in /var/www/includes/stats.php on line 42,

Some one told me that

Quote
Probably this query is not returning a value, so it gives an error.
Code:
$sql = "SELECT count(id) FROM shares WHERE id > $lastwinningshare AND our_result='N'";
Most likely it will go away as soon as it returns something.
( from this article :
https://bitcointalk.org/index.php?topic=36672.0
)

Please help ! It is urgent
thanks !


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 25, 2011, 05:46:24 AM
Sorry for the delays. I'm trying to lock-down some things for 4.1.

Also, forum link has changed.


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on August 26, 2011, 06:21:52 AM
Any updates :) ?

And can you please provide me a solution for the php fatal error for the that member function ?
I have been stuck for 2 weeks on my pool just because of this .i really thank you for the help


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: AnnihilaT on August 26, 2011, 12:41:35 PM
Sareea,

I really suggest that you dont even bother trying to start a pool simply because if a problem like this gets you stuck for more than two weeks you dont have the technical ability to run a pool.  There will be much larger day to day problems than this one that arise while running a pool.  Its not install and forget software.  You need to be able to program and understand the code because there will be problems and you will need to fix them yourself.  I dont mean to be mean but you are clearly not qualified to run a pool.  Im just being honest and trying to save you alot more pain down the road.


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Keninishna on August 27, 2011, 08:57:41 AM
ok I almost have your pool up I have one sql issue thats causing the site to fail. I get
Code:
PHP Fatal error:  Call to a member function fetch() on a non-object in /var/www/simplecoin/includes/stats.php on line 276

So I google some and take a look at line 276, I see its under function usersharecount()
Code:
if ($currentSharesR = $currentSharesQ->fetch()) {

Apparently when the fetch fails it returns a false, and its expecting an object so the error causes more errors  ;D
I think my understanding fails at the SQL code above it here:

Code:
$sql = "SELECT count(id) as id FROM shares WHERE id > $lastwinningshare AND username in ('".implode("','",$workers)."')";

I have the database set up properly, it has all the tables, pushpoold is working away I can create a worker (if I comment out the above code) and login and submit shares. Thanks for any help.

edit:
nevermind I found out it was because there was no $lastwinningshare I manually set it to 1 now everything is good (untill i find a block lol)


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on August 27, 2011, 07:11:11 PM
ok I almost have your pool up I have one sql issue thats causing the site to fail. I get
Code:
PHP Fatal error:  Call to a member function fetch() on a non-object in /var/www/simplecoin/includes/stats.php on line 276

So I google some and take a look at line 276, I see its under function usersharecount()
Code:
if ($currentSharesR = $currentSharesQ->fetch()) {

Apparently when the fetch fails it returns a false, and its expecting an object so the error causes more errors  ;D
I think my understanding fails at the SQL code above it here:

Code:
$sql = "SELECT count(id) as id FROM shares WHERE id > $lastwinningshare AND username in ('".implode("','",$workers)."')";

I have the database set up properly, it has all the tables, pushpoold is working away I can create a worker (if I comment out the above code) and login and submit shares. Thanks for any help.

edit:
nevermind I found out it was because there was no $lastwinningshare I manually set it to 1 now everything is good (untill i find a block lol)

Can you please explain to me how you exactly fixed it ? I am still  a newbie learning the business :)

Edit : Solved it :D


Title: Re: [Pushpool Web Frontend] Simplecoin v4.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 30, 2011, 03:54:24 AM
Version 5 is released  8)

A lot of bug fixes, especially for new pools!
Even more optimization to sql (especially for multi-million share rounds )
Main cronjob can run every minute with very little impact.
Winning shares are much more easily handled.
Also unconfirmed shares are perfectly accurate.

Tested with lastnpps scoring, will be testing prop soon.

Now to get multi-pool/coin support into the base.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on August 31, 2011, 12:16:14 PM
Thanks for the effort.
How can i upgrade from v4 to v5?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on August 31, 2011, 04:37:21 PM
You'll need to add the new table (unrewarded_shares) and look for other sql changes.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on September 01, 2011, 10:24:40 AM
i tested it , it doesn't have the problems v4 had !
Thanks a lot !

I faced few things though :
- Resetting the password with lostpassword didn't work for me, i edited it to be http:// and not https:// as it is in lostpassword.php.
It even ruins the password, even the old password stops working. What should i do ?
I think it is because lostpassword.php uses sha256 encryption and the login.php uses the $salt thing ?

- in accountdetails.php , you added the field ( current password ) to change the password, but even though you put the password it says " you must put your current password" , it doesn't  recognize it .

Thanks a lot simplecoin ! you are awesome ! :)


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 01, 2011, 12:01:26 PM
- Resetting the password with lostpassword didn't work for me, i edited it to be http:// and not https:// as it is in lostpassword.php.
It even ruins the password, even the old password stops working. What should i do ?
I think it is because lostpassword.php uses sha256 encryption and the login.php uses the $salt thing ?

lostpassword.php, line 53 must be like:
$result = mysql_query("UPDATE webUsers SET pass='".hash("sha256", $pass.$salt)."', accountFailedAttempts = 0 WHERE  username='$resetUsername' AND emailAuthPin='$resetAuth' ");


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on September 01, 2011, 01:14:56 PM
- Resetting the password with lostpassword didn't work for me, i edited it to be http:// and not https:// as it is in lostpassword.php.
It even ruins the password, even the old password stops working. What should i do ?
I think it is because lostpassword.php uses sha256 encryption and the login.php uses the $salt thing ?

lostpassword.php, line 53 must be like:
$result = mysql_query("UPDATE webUsers SET pass='".hash("sha256", $pass.$salt)."', accountFailedAttempts = 0 WHERE  username='$resetUsername' AND emailAuthPin='$resetAuth' ");
Yeah it works now :) thanks .

The only problem left is in changing the password , any idea ? It doesn't recognize that i inserted my current password ...


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on September 02, 2011, 07:24:39 AM
I tried to do this to fix the changing password problem .

I changed this line
$oldPass = hash("sha256", mysql_real_escape_string($_POST["currentPassword"]));
to
$oldPass = hash("sha256", $oldPass.$salt, mysql_real_escape_string($_POST["currentPassword"]));

But it didn't work.

The update process starts with
if($oldPass == $hashedPass){

I tried to define $hashedPass and fetch the password from the DB to  it .
Still didn't work .

And says
"You must type in the correct current password before you can set a new password. "

Please help


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 02, 2011, 08:55:05 AM
I tried to do this to fix the changing password problem .

I changed this line
$oldPass = hash("sha256", mysql_real_escape_string($_POST["currentPassword"]));
to
$oldPass = hash("sha256", $oldPass.$salt, mysql_real_escape_string($_POST["currentPassword"]));

But it didn't work.

The update process starts with
if($oldPass == $hashedPass){

I tried to define $hashedPass and fetch the password from the DB to  it .
Still didn't work .

And says
"You must type in the correct current password before you can set a new password. "

Please help

$oldPass = hash("sha256", mysql_real_escape_string($_POST["currentPassword"]).$salt);


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: sareea on September 02, 2011, 09:25:36 AM
I tried to do this to fix the changing password problem .

I changed this line
$oldPass = hash("sha256", mysql_real_escape_string($_POST["currentPassword"]));
to
$oldPass = hash("sha256", $oldPass.$salt, mysql_real_escape_string($_POST["currentPassword"]));

But it didn't work.

The update process starts with
if($oldPass == $hashedPass){

I tried to define $hashedPass and fetch the password from the DB to  it .
Still didn't work .

And says
"You must type in the correct current password before you can set a new password. "

Please help

$oldPass = hash("sha256", mysql_real_escape_string($_POST["currentPassword"]).$salt);


It works now !! :) Thanks a lot man :)


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 03, 2011, 08:56:14 AM
Any body know, why MtGox rate don't shows correct about 5 last days? They changed a code?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Danilo on September 04, 2011, 11:08:59 AM
Hello everyone,

I set all the parameters of my previous scripts and everything works fine, but I want to move to this one because I prefer this script, but I get the following error:

Fatal error: Uncaught BitcoinClientException:
  • : Connect error: Connection refused (111) thrown in on line 0

bitcoind working on port 8332
Workers have a communication with a pushpoold on 8341 and 8344 port.

I entered all that is needed in requiredFunctions.php, and tried different ports but still get that error.

What could be the problem?

Thank you in advance for your reply,


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Keninishna on September 05, 2011, 07:16:04 PM
Does anyone know where simplecoin writes to the unconfirmed_rewards table in the database? I see a function that reads from it but where does it write to it?
edit: found it in rewards

mysql_query("INSERT INTO unconfirmed_rewards (userId, blockNumber, amount, shares) VALUES ($userid, $blockNumber, '$totalReward', $uncountedShares)");


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on September 13, 2011, 02:56:49 PM
Sorry I've been AWOL from this thread, but between developing the new version and my best friends marriage things have been hectic.

The new version is so close to stable. The current slowdown is the creation of a dynamic long-polling proxy to use with the new frontend.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on September 13, 2011, 02:58:23 PM
Hello everyone,

I set all the parameters of my previous scripts and everything works fine, but I want to move to this one because I prefer this script, but I get the following error:

Fatal error: Uncaught BitcoinClientException:
  • : Connect error: Connection refused (111) thrown in on line 0

bitcoind working on port 8332
Workers have a communication with a pushpoold on 8341 and 8344 port.

I entered all that is needed in requiredFunctions.php, and tried different ports but still get that error.

What could be the problem?

Thank you in advance for your reply,


You should have port 8332 set then. Also, make sure the calling machine has access in the bitcoin.conf file as well as the firewall.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 27, 2011, 04:05:24 AM
Got a problem. Pool has found 2 blocks, I can see in wallet about 100 btc, but pool stat does not show founded blocks :(
Need your urgent help!!!
Table "winning_shares" is empty.
Table "networkBlocks" is empty.

Simplecoin v.5
Mysql 5.1.54

cronjob.php returns "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1"


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on September 27, 2011, 04:39:27 AM
Got a problem. Pool has found 2 blocks, I can see in wallet about 100 btc, but pool stat does not show founded blocks :(
Need your urgent help!!!
Table "winning_shares" is empty.
Table "networkBlocks" is empty.

Simplecoin v.5
Mysql 5.1.54

cronjob.php returns "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1"


Ok, what line number is the error coming from (there are LOTS of sql calls from many classes in cronjob) ?

V5 was fairly solid out of the box, so hopefully this is a simple fix.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 27, 2011, 04:46:03 AM
/cronjobs/cronjob.php

Warning: mysql_fetch_row() expects parameter 1 to be resource, boolean given in /var/www/mpool/includes/block.php on line 6 Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in /var/www/mpool/includes/block.php on line 16 Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/mpool/includes/block.php on line 24 Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in /var/www/mpool/includes/block.php on line 54 Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/mpool/includes/block.php on line 59 Notice: Trying to get property of non-object in /var/www/mpool/includes/block.php on line 60 Notice: Trying to get property of non-object in /var/www/mpool/includes/block.php on line 61 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

My table networkBlocks is empty. Which script does update it? And can I get somewhere dump of this table?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on September 27, 2011, 05:09:26 AM
networkBlocks is updated by cronjob.php

try putting a networkBlock of 1 in the table, that should force it to start updating.

I'm currently running a wholly new version of the source (working the kinks out now, especially merged-mining), so I'm referencing the git repo for answers.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 27, 2011, 05:18:11 AM
What can I do now for make visible founded two blocks in stat and for paying out to users? I can see that shares in table shares, I see who found it, but which moves I have to do for correct stats and distribution of mined amount?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 27, 2011, 05:26:21 AM
networkBlocks is updated by cronjob.php

try putting a networkBlock of 1 in the table, that should force it to start updating.

I'm currently running a wholly new version of the source (working the kinks out now, especially merged-mining), so I'm referencing the git repo for answers.

I did but updating not started  :(


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on September 27, 2011, 05:45:59 PM
networkBlocks is updated by cronjob.php

try putting a networkBlock of 1 in the table, that should force it to start updating.

I'm currently running a wholly new version of the source (working the kinks out now, especially merged-mining), so I'm referencing the git repo for answers.

I did but updating not started  :(

Still the same error?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 27, 2011, 07:04:38 PM
No, fix by edited requiredFunctions.php (lock - unlock "shares")...
I hope that it was fixed...
Will see on next found block. Good sign - networkBlocks updates by every next block and part of last row in winningshares has been updated automatically.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on September 27, 2011, 07:17:38 PM
No, fix by edited requiredFunctions.php (lock - unlock "shares")...
I hope that it was fixed...
Will see on next found block. Good sign - networkBlocks updates by every next block and part of last row in winningshares has been updated automatically.

That's good news! The next version has better locking, but it takes a lot more database work to get it off the ground.

I'm going to need to build a serious manual or an install interface at this rate.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on September 29, 2011, 01:13:50 PM
I think you have to make name of pool as variable in some settings file and use it in files who send notifications and etc.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on September 29, 2011, 02:11:11 PM
I think you have to make name of pool as variable in some settings file and use it in files who send notifications and etc.

Thanks, I'll try to get that in the next version.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Keninishna on October 15, 2011, 11:21:56 AM
merged mining source code plz  ;D


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: worldinacoin on October 15, 2011, 12:11:33 PM
I am hoping to run it on Centos 6, will there be any issues?  Or is it more suited for Debian based distros only?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on October 16, 2011, 02:30:00 AM
merged mining source code plz  ;D

It's coming..... the real issue isn't the source, the source is good. The issue is making it usable for the masses. Right now, 90% of the setup is undocumented database tables and fields. I'm working on beefing up the admin panel so that it isn't nearly impossible to manage and install.

I am hoping to run it on Centos 6, will there be any issues?  Or is it more suited for Debian based distros only?

I'm not sure. In theory it should run on any PHP/Mysql setup. I personally use ubuntu with mysql 5.5, but I've heard of others even using windows.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Coinbuck @ BTCLot on October 17, 2011, 06:21:00 PM
Share counting and block update isn't working, what is wrong with my minipool ? I've setup cronjobs (of all files in cronjobs folder). Could you please show me a example of crontab -e ?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on October 18, 2011, 11:41:58 AM
Share counting and block update isn't working, what is wrong with my minipool ? I've setup cronjobs (of all files in cronjobs folder). Could you please show me a example of crontab -e ?

Yes, I would like to take a look this too. I need correct time interval for each of cronjobs file. When last my block was found frontend shown me balance >1000 except ~23... unknown mistake again :(


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Coinbuck @ BTCLot on October 18, 2011, 02:21:58 PM
Share counting and block update isn't working, what is wrong with my minipool ? I've setup cronjobs (of all files in cronjobs folder). Could you please show me a example of crontab -e ?

Yes, I would like to take a look this too. I need correct time interval for each of cronjobs file. When last my block was found frontend shown me balance >1000 except ~23... unknown mistake again :(

Could you please show yours ? it seems the block & earnings are updating in yours, in mine they aren't.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on October 21, 2011, 09:27:15 AM
Share counting and block update isn't working, what is wrong with my minipool ? I've setup cronjobs (of all files in cronjobs folder). Could you please show me a example of crontab -e ?

Yes, I would like to take a look this too. I need correct time interval for each of cronjobs file. When last my block was found frontend shown me balance >1000 except ~23... unknown mistake again :(

Could you please show yours ? it seems the block & earnings are updating in yours, in mine they aren't.
backupwallet.php - 1 per day
archive.php - every 5 minutes
hashrate.php - 30 minutes
payout.php - 10 minutes
shares.php - 2 minutes
cronjob.php - 3 minutes


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Korvalkov_V on October 27, 2011, 09:04:56 PM
No, fix by edited requiredFunctions.php (lock - unlock "shares")...
I hope that it was fixed...
Will see on next found block. Good sign - networkBlocks updates by every next block and part of last row in winningshares has been updated automatically.
Can you plz tell us what exactly did you change in lock/unlock functions?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on October 28, 2011, 06:23:31 AM
No, fix by edited requiredFunctions.php (lock - unlock "shares")...
I hope that it was fixed...
Will see on next found block. Good sign - networkBlocks updates by every next block and part of last row in winningshares has been updated automatically.
Can you plz tell us what exactly did you change in lock/unlock functions?
Actually I didnt understand, I've disabled functions lock/unlock, then run cronjob.php - it was done without errors, then enabled back lock/unlock and script still work correct.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: mich on October 28, 2011, 11:33:29 AM
I think its up to you. About "any changes" - when you type your own settings logins, passwords, email etc. in php files, it is changing a code or not?  ;)
P.S. If somebody needs my changes - feel free to ask :)


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on October 28, 2011, 01:56:48 PM
question about the license

any change that id done on the code needs to be make public and under same license true ?

That's the spirit of it. In theory, if anyone asks, the code must be made public if you change any existing files or include the code from existing files.

Although, only I think only 1 site is sharing their code base. BurningToad was kind enough to share his code as well upon request as well.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: shads on November 09, 2011, 09:56:52 AM
Hi Simplecoin,

Just thought I'd point out to you the new version of poolserver includes the capability to send coinbase donations.  I wrote it so pool ops can donate to any address so that other devs of other open source software that pools use can benefit as well.

It's explained in detail in this post: https://bitcointalk.org/index.php?topic=51226.0

To be able to receive donations you need to put up a page that returns json something like this:
http://poolserverj.org/meta/donations/

But obviously with your own addresses.  Then of course make it known what your donation URL is.  Suggest you fill in the testnets as well.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: cablepair on December 13, 2011, 11:31:40 PM
looking for some help

Not sure what I am doing wrong, I have setup plenty of pools before, this is my first time using simplecoin as a front end - I am sure it is something stupid that I missed

I have simple coin in the www root of the web server

but the pages arent loading

500 error in IE

firefox just shows a blank page

http://24.14.210.199/

I am racking my brains here, anyone have any ideas what I did wrong?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on December 14, 2011, 07:43:01 PM
looking for some help

Not sure what I am doing wrong, I have setup plenty of pools before, this is my first time using simplecoin as a front end - I am sure it is something stupid that I missed

I have simple coin in the www root of the web server

but the pages arent loading

500 error in IE

firefox just shows a blank page

http://24.14.210.199/

I am racking my brains here, anyone have any ideas what I did wrong?

I'm not sure, but I'm guessing you either have missing dependencies or a configuration error.

I would turn on site errors and php errors until you have everything up and running. Also check your site logs, they should lead you in the right direction.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: makomk on December 30, 2011, 01:13:00 PM
It's coming..... the real issue isn't the source, the source is good. The issue is making it usable for the masses. Right now, 90% of the setup is undocumented database tables and fields. I'm working on beefing up the admin panel so that it isn't nearly impossible to manage and install.
Ah, I was curious about that. (Was looking for a merged mining pool frontend to go with an experimental backend I was working on a couple of months ago. There didn't seem to be any open source ones out there.)


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: wndrbr3d on February 03, 2012, 04:34:45 PM
Is this project active?

I just downloaded it the other night and it has some obvious code issues that need to be fixed otherwise pages wouldn't display properly.

From what I can see though, this is the most common baseline people start with for their mining pools?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: simplecoin on February 03, 2012, 11:33:23 PM
Is this project active?

I just downloaded it the other night and it has some obvious code issues that need to be fixed otherwise pages wouldn't display properly.

From what I can see though, this is the most common baseline people start with for their mining pools?

Yes, it's active. Although the massive change from the current codebase has not yet been uploaded.

The changes would break existing installs and cause all kinds of headaches.

I will release it once I have a better way to upgrade or install a fresh base.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: idev on April 07, 2012, 04:13:32 PM
Is this still active ?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Wayno on April 11, 2012, 05:02:39 AM
there is a potential issue with the deletion of workers which will cause issue to the whole back end of simplecoin

i have done a quick fix

Code:
edit pool_worker mysql
disabled enum('yes','no') NOT NULL DEFAULT 'no'

//Check if username already exists
$usernameExistsQ = mysql_query("SELECT id,username FROM `pool_worker` WHERE `associatedUserId` = ".$userId." AND `username` = '".$inputUser."'");
$usernameExists = mysql_num_rows($usernameExistsQ);
$usernameExists1 = mysql_fetch_object($usernameExistsQ);
$workerId = $usernameExists1->username;


}else if($usernameExists == 1){
mysql_query("UPDATE `pool_worker` SET disabled = 'no' WHERE username = '".$workerId."' AND `associatedUserId` = '".$userId."'")or sqlerr(__FILE__,__LINE__);
returnError = "Reinstated Worker";
}

//Delete worker OH NOES!
mysql_query("UPDATE `pool_worker` SET `disabled` = 'yes' WHERE `id` = '".$workerId."' AND `associatedUserId` = '".$userId."'")or sqlerr(__FILE__,__LINE__);
}

$getWorkers = mysql_query("SELECT `id`, `username`, `password`, active, hashrate, monitor, disabled FROM `pool_worker` WHERE `associatedUserId` = '".$userId."' AND disabled = 'no'");


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: cablepair on April 11, 2012, 12:26:33 PM
there is a potential issue with the deletion of workers which will cause issue to the whole back end of simplecoin

i have done a quick fix

Code:
edit pool_worker mysql
disabled enum('yes','no') NOT NULL DEFAULT 'no'

//Check if username already exists
$usernameExistsQ = mysql_query("SELECT id,username FROM `pool_worker` WHERE `associatedUserId` = ".$userId." AND `username` = '".$inputUser."'");
$usernameExists = mysql_num_rows($usernameExistsQ);
$usernameExists1 = mysql_fetch_object($usernameExistsQ);
$workerId = $usernameExists1->username;


}else if($usernameExists == 1){
mysql_query("UPDATE `pool_worker` SET disabled = 'no' WHERE username = '".$workerId."' AND `associatedUserId` = '".$userId."'")or sqlerr(__FILE__,__LINE__);
returnError = "Reinstated Worker";
}

//Delete worker OH NOES!
mysql_query("UPDATE `pool_worker` SET `disabled` = 'yes' WHERE `id` = '".$workerId."' AND `associatedUserId` = '".$userId."'")or sqlerr(__FILE__,__LINE__);
}

$getWorkers = mysql_query("SELECT `id`, `username`, `password`, active, hashrate, monitor, disabled FROM `pool_worker` WHERE `associatedUserId` = '".$userId."' AND disabled = 'no'");
Thanks for the effort! Are you interested in fixing some of the other bugs that simplecoin has?

It would be really nice if someone updated / fixed this and released it - I love playing with pool software and for whatever reason it seems like no one ever follows through and continues to develop them after they are initially released.

People are too busy I guess....

I know I would certainly donate to a cause such as this though..


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: Wayno on April 14, 2012, 12:02:43 PM
Thanks for the effort! Are you interested in fixing some of the other bugs that simplecoin has?

It would be really nice if someone updated / fixed this and released it - I love playing with pool software and for whatever reason it seems like no one ever follows through and continues to develop them after they are initially released.

People are too busy I guess....

I know I would certainly donate to a cause such as this though..


i still help run a litecoin pool that uses simplecoin backend that is hevily modified for litecoin, it can be changed to btc with a few changes.

if u want it i can give it to u.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: kingkatari on May 12, 2012, 05:27:01 AM
Damn Wayno how come you never told me you had a backend for a server???


LoL just kidding i have something up and running now tho but no frontend yet


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: omegaaf on September 08, 2012, 08:35:28 PM
You Sir, are my hero. I will be sure to give feedback and ideas.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: gektek on March 23, 2013, 12:05:17 AM
This being worked on...active at all?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: flound1129 on April 06, 2013, 05:35:09 PM
$winningShareQ seems to be broken in current version of mysql, it's throwing error on the following:

$winningShareQ = mysql_query("SELECT `id`, `username` FROM `shares` where `upstream_result` = 'Y' AND `id` > $lastwinningid");

I can run this qurey fine at the mysql prompt so not sure what exactly the problem is.

When I run cronjob.php I get the following output:

$ php ./cronjob.php
PHP Warning:  mysql_fetch_row() expects parameter 1 to be resource, boolean given in /var/www/multipool.in/includes/block.php on line 6
PHP Warning:  mysql_num_rows() expects parameter 1 to be resource, boolean given in /var/www/multipool.in/includes/block.php on line 16
PHP Warning:  mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/multipool.in/includes/block.php on line 24
PHP Warning:  mysql_num_rows() expects parameter 1 to be resource, boolean given in /var/www/multipool.in/includes/block.php on line 54
PHP Warning:  mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /var/www/multipool.in/includes/block.php on line 59
PHP Notice:  Trying to get property of non-object in /var/www/multipool.in/includes/block.php on line 60
PHP Notice:  Trying to get property of non-object in /var/www/multipool.in/includes/block.php on line 61
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

Any help would be appreciated.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: gateway on April 18, 2013, 08:12:59 PM
Has anyone adopted this to work with Eloipool? I have bitcoind, eloipool up and running, trying simple coin (yes its old and outdated, I just want to see it work on my local test machines)

im seeing these errors in apache when viewing a page

Code:
[Thu Apr 18 13:13:05 2013] [error] [client 172.18.1.240] PHP Warning:  array_key_exists() expects parameter 2 to be array, boolean given in /var/www/includes/stats.php on line 268, referer: http://172.18.251.184/my_stats.php
[Thu Apr 18 13:13:05 2013] [error] [client 172.18.1.240] PHP Warning:  fopen(/var/www/api/pool/speed): failed to open stream: No such file or directory in /var/www/includes/stats.php on line 83, referer: http://172.18.251.184/my_stats.php
[Thu Apr 18 13:13:05 2013] [error] [client 172.18.1.240] PHP Warning:  fwrite() expects parameter 1 to be resource, boolean given in /var/www/includes/stats.php on line 84, referer: http://172.18.251.184/my_stats.php
[Thu Apr 18 13:13:05 2013] [error] [client 172.18.1.240] PHP Warning:  fclose() expects parameter 1 to be resource, boolean given in /var/www/includes/stats.php on line 85, referer: http://172.18.251.184/my_stats.php
[Thu Apr 18 13:13:05 2013] [error] [client 172.18.1.240] PHP Warning:  Invalid argument supplied for foreach() in /var/www/includes/stats.php on line 110, referer: http://172.18.251.184/my_stats.php
[Thu Apr 18 13:13:06 2013] [error] [client 172.18.1.240] PHP Warning:  array_key_exists() expects parameter 2 to be array, boolean given in /var/www/includes/stats.php on line 268, referer: http://172.18.251.184/my_stats.php
[Thu Apr 18 13:13:06 2013] [error] [client 172.18.1.240] PHP Warning:  Division by zero in /var/www/includes/header.php on line 98, referer: http://172.18.251.184/my_stats.php


Did I miss something or is this just incompatible?


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: KALRONG on April 26, 2013, 08:56:27 AM
Im seeing the same errors, I also found out that for example the block table was not being updated and I needed to add a COMMIT after the INSERT INTO call to make it work, Im gonna check the code and add COMMIT after all the INSERT INTO and check how it works.

Also Im working on modify the code to make it multilanguage using language templates so its easier to translate.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: gateway on April 29, 2013, 06:18:03 PM
Im seeing the same errors, I also found out that for example the block table was not being updated and I needed to add a COMMIT after the INSERT INTO call to make it work, Im gonna check the code and add COMMIT after all the INSERT INTO and check how it works.

Also Im working on modify the code to make it multilanguage using language templates so its easier to translate.

Let me know when you do, I put this aside temp since the thread seemed dead :/


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: KALRONG on April 30, 2013, 10:15:31 AM
Im seeing the same errors, I also found out that for example the block table was not being updated and I needed to add a COMMIT after the INSERT INTO call to make it work, Im gonna check the code and add COMMIT after all the INSERT INTO and check how it works.

Also Im working on modify the code to make it multilanguage using language templates so its easier to translate.

Let me know when you do, I put this aside temp since the thread seemed dead :/

Sure :) I like this frontend as its the only one I managed to get working without needing to do a lot of things, sad that is seems uncontinued and with a couple of bugs, I will try get some free time to review the full code but in the meantime Im gonna do those changes to get the DB working propertly and the start reading and modifying for the multilenguage version :)

If anyone wants to help everything is welcome hehe


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: gateway on April 30, 2013, 04:58:16 PM
Im seeing the same errors, I also found out that for example the block table was not being updated and I needed to add a COMMIT after the INSERT INTO call to make it work, Im gonna check the code and add COMMIT after all the INSERT INTO and check how it works.

Also Im working on modify the code to make it multilanguage using language templates so its easier to translate.

Let me know when you do, I put this aside temp since the thread seemed dead :/

Sure :) I like this frontend as its the only one I managed to get working without needing to do a lot of things, sad that is seems uncontinued and with a couple of bugs, I will try get some free time to review the full code but in the meantime Im gonna do those changes to get the DB working propertly and the start reading and modifying for the multilenguage version :)

If anyone wants to help everything is welcome hehe

My idea was to get it up and running see how it functions, then build all custom modules for a drupal 7 version.. aka custom modules that you can plug into drupal and display in the various blocks themeing layers and take advantage of drupals out of the box front end for users, permissions etc.

Would be willing to work with someone to translate the code into a more flexible system.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: KALRONG on May 01, 2013, 12:33:01 AM
Im seeing the same errors, I also found out that for example the block table was not being updated and I needed to add a COMMIT after the INSERT INTO call to make it work, Im gonna check the code and add COMMIT after all the INSERT INTO and check how it works.

Also Im working on modify the code to make it multilanguage using language templates so its easier to translate.

Let me know when you do, I put this aside temp since the thread seemed dead :/

Sure :) I like this frontend as its the only one I managed to get working without needing to do a lot of things, sad that is seems uncontinued and with a couple of bugs, I will try get some free time to review the full code but in the meantime Im gonna do those changes to get the DB working propertly and the start reading and modifying for the multilenguage version :)

If anyone wants to help everything is welcome hehe

My idea was to get it up and running see how it functions, then build all custom modules for a drupal 7 version.. aka custom modules that you can plug into drupal and display in the various blocks themeing layers and take advantage of drupals out of the box front end for users, permissions etc.

Would be willing to work with someone to translate the code into a more flexible system.


As far as I saw about the code its basically a bunch of operations with the pushpool DB and some more tables, then it just do some calculations and gather some info, you just need to know where to ask the DB hehe apart of that is basically a pretty website with graphs and everything (basically design) the operational part is quite simple, or at least is what it looks like, didn't have time to check the payout system.


Title: Re: [Pushpool Web Frontend] Simplecoin v5.0 Opensource PHP/MySQL - NEW RELEASE
Post by: CoinPopper on December 07, 2013, 10:32:33 PM
Hello,

[Sat Dec 07 23:29:48 2013] [error] [client y.y.y.y] PHP Fatal error:  Uncaught BitcoinClientException:
  • : Didn't receive 200 OK from remote server. (HTTP/1.1 404 Not Found)\n\n  thrown in  on line 0, referer: http://x.x.x.x/stats.php

What does this means ?