Amazing Collection of online role playing games for your website!

Ravan

HOT
Only registered and logged in users can download this file.
Rating
(0 votes)
Technical Details
Filename ravan.zip
Size 210.01 KB
Downloads 89
Author Unknown
Created 2008-12-31
Changed 2025-12-11
System PHP 5.x
Price $0.00
Screenshot
Ravan

Ravan is a feature-rich web-based crime RPG script that delivers the classic mid-2000s mafia experience. Players build up their characters, commit crimes, battle rivals, and grow powerful through gangs, property ownership, jobs, education, and a bustling player market. An automated installer and scheduled cron jobs make setup easy for administrators, while a comprehensive admin panel keeps the world running smoothly.

This turnkey package packs PvP combat, organized crimes, item crafting and trading, cities and travel, mini-games like roulette and slots, and a donation system for premium perks—giving you a complete, highly replayable crime RPG out of the box.

File Verification
MD5 Checksum
cfdee76f1856d67005124e5c724813d1
SHA1 Checksum
714a4e77c4bded0f1d595baa480871ef120781a0

Ravan - Analysis Report - Game Analysis Report

1. Identity & Metadata

Game Name: Ravan (MMORPG Script)

Version: 1.2

Genre: Web-based crime/mafia RPG

Developer: Ravan Scripts

Support Email: This email address is being protected from spambots. You need JavaScript enabled to view it.

License: Commercial/Proprietary (License Agreement.html included)

Language: PHP + MySQL/MySQLi

Release Era: ~2008-2010 (estimated based on code style)

Installation: Automated via install.php with cron job setup

---

2. Codebase Statistics

Total Files: 155

File Breakdown:

  • PHP: 129 files (493.72 KB) - 14,567 lines
  • GIF Images: 8 files (6.16 KB)
  • JPG Images: 6 files (31.91 KB)
  • PNG Images: 6 files (1.15 KB)
  • TXT: 2 files (4.98 KB)
  • ICO: 1 file (1.37 KB)
  • HTML: 1 file (3.55 KB)
  • SQL: 1 file (30.34 KB)
  • No extension: 1 file (1.29 KB)

Total Size: ~575 KB

Key Files:

  • globals.php (95 lines) - Session management, database connection
  • global_func.php (391 lines) - Utility functions library
  • config.php (11 lines) - Database configuration
  • dbdata.sql (30.34 KB) - Database schema
  • install.php - Automated installation wizard
  • Readme.txt - Installation instructions
  • Crime Guide.txt - Crime success rate formulas
  • License Agreement.html - Commercial license terms

Key Directories:

  • /class/ - Database abstraction classes (MySQL/MySQLi)
  • Root contains all game files (flat structure)

---

3. Core Architecture

3.1 Technology Stack

PHP Standards (Mid-2000s era):

  • PHP 4/5 compatible
  • MySQL or MySQLi drivers (switchable via config)
  • Session-based authentication
  • Magic quotes handling (deprecated feature)
  • Direct SQL queries (no ORM)

Database Configuration (config.php):

`php

$_CONFIG = array(

'hostname' => 'localhost',

'username' => 'mysqlusername',

'password' => 'mysqlpassword',

'database' => 'mysqldatabase',

'persistent' => 0,

'driver' => 'mysql', // or 'mysqli'

'code' => '2c72366341cc8e9c36fc7565fe77b1b4' // Cron security code

);

`

Database Abstraction:

  • Custom database class in class/class_db_mysql.php and class_db_mysqli.php
  • Switchable drivers via config
  • Methods: configure(), connect(), query(), fetch_row()

3.2 Session & Authentication System

globals.php Bootstrap:

`php

session_start();

ob_start();

// Magic quotes handling

if(get_magic_quotes_gpc() == 0) {

foreach($_POST as $k => $v) {

$_POST[$k]=addslashes($v);

}

foreach($_GET as $k => $v) {

$_GET[$k]=addslashes($v);

}

}

// Check logged in status

if($_SESSION['loggedin']==0) {

header("Location: login.php");

exit;

}

`

Authentication (authenticate.php):

`php

$uq=$db->query("SELECT userid FROM users

WHERE login_name='{$_POST['username']}'

AND userpass=md5('{$_POST['password']}')");

`

Password Storage: MD5 hashing (no salt)

`php

// register.php line 288

md5('{$_POST['password']}')

// preferences.php line 87

md5('{$_POST['newpw']}')

`

Session Variables:

  • $_SESSION['loggedin'] - Authentication status
  • $_SESSION['userid'] - Player ID
  • $_SESSION['attacklog'] - Combat log buffer
  • $_SESSION['attackwon'] - Combat victory target
  • $_SESSION['attacklost'] - Combat defeat flag

3.3 Database Schema

44+ Tables (dbdata.sql):

Core Tables:

  • users - Player accounts
  • userstats - Player statistics
  • settings - Game configuration

Crime System:

  • crimes - Crime definitions
  • crimegroups - Crime categories
  • fedjail - Federal jail logs

Combat System:

  • attacklogs - Combat history
  • challengebots - NPC opponents
  • challengesbeaten - Challenge victories

Gang System:

  • gangs - Gang data
  • gangwars - Gang warfare logs
  • applications - Gang applications

Items & Economy:

  • items - Item database
  • itemtypes - Item categories
  • inventory - Player inventories
  • itemmarket - Player-to-player market
  • shops - NPC shops
  • shopitems - Shop inventories

Property & Travel:

  • houses - Real estate
  • cities - Locations

Education:

  • courses - Training courses
  • coursesdone - Completed courses

Jobs:

  • jobs - Job definitions
  • jobranks - Job promotions

Communication:

  • events - Event notifications
  • forum_forums - Forum categories
  • forum_posts - Forum posts
  • mailbox - Private messages

Banking:

  • bankxferlogs - Bank transfer logs
  • cashxferlogs - Cash transfer logs
  • crystalxferlogs - Crystal transfer logs
  • crystalmarket - Crystal marketplace

Social:

  • contactlist - Contact management
  • blacklist - Blocked users
  • polling - Polls

Special Features:

  • dps_accepted - Donator perks
  • announcements - Server announcements

Staff/Admin:

  • stafflogs - Admin action logs
  • staffnotes - Admin notes

3.4 Magic Quotes Handling

Security Anti-Pattern:

`php

// globals.php lines 8-18

if(get_magic_quotes_gpc() == 0) {

foreach($_POST as $k => $v) {

$_POST[$k]=addslashes($v);

}

foreach($_GET as $k => $v) {

$_GET[$k]=addslashes($v);

}

}

`

Problem: Manually adds slashes to ALL input if magic_quotes disabled, but:

  • Magic quotes deprecated PHP 5.3 (2009), removed PHP 5.4 (2012)
  • addslashes() insufficient for SQL injection prevention
  • Applies to ALL input regardless of context
  • Double-escaping issues if magic_quotes actually enabled

---

4. Gameplay Systems

4.1 Core Stats System

Primary Attributes:

  • Strength - Physical attack power
  • Agility - Dodge/hit chance
  • Guard - Defense rating
  • Labour - Work efficiency
  • IQ - Intelligence/crime success

Secondary Stats:

  • HP/MaxHP - Hit points
  • Energy/MaxEnergy - Action points
  • Will/MaxWill - Crime willpower
  • Brave/MaxBrave - Crime courage
  • Level - Character progression
  • EXP - Experience points
  • Money - Cash currency
  • Crystals - Premium currency

Stat Ranking (index.php):

`php

$ir['strank']=get_rank($ir['strength'],'strength');

// Rankings shown for all 5 primary stats + total stats

`

4.2 Crime System

Crime Mechanics (docrime.php):

Crime Success Formula (Crime Guide.txt):

`

((WILL*0.8)/2.5)+(LEVEL/4)

`

Crime Execution:

`php

// docrime.php lines 19-23

$ec="\$sucrate=".str_replace(

array("LEVEL","CRIMEXP","EXP","WILL","IQ"),

array($ir['level'], $ir['crimexp'], $ir['exp'], $ir['will'], $ir['IQ']),

$r['crimePERCFORM']

).";";

eval($ec); // CRITICAL: eval() execution of user-influenced code!

`

Crime Outcomes:

  • Success: Gain money, crystals, EXP, possibly items
  • Fail - Escape: No consequences, retry
  • Fail - Jail: Sent to jail for specified time

Crime Requirements:

  • Brave points (consumed per attempt)
  • Cannot be in jail or hospital
  • Must pass success rate check

Crime Rewards:

`php

$ir['money']+=$r['crimeSUCCESSMUNY'];

$ir['crystals']+=$r['crimeSUCCESSCRYS'];

$ir['exp']+=(int) ($r['crimeSUCCESSMUNY']/8);

// Update crimexp (crime experience)

`

4.3 Combat System

PvP Combat (attack.php):

Attack Requirements:

  • Not unconscious (HP > 1)
  • Not in hospital or jail
  • Not already lost EXP (session limit)
  • Target not in hospital/jail/travelling
  • Target not unconscious

Combat Flow:

  • Weapon Selection: Choose primary or secondary weapon
  • Attack Calculation:
  • Hit chance based on agility
  • Damage based on weapon + strength
  • Turn-by-Turn: Alternating attacks until HP reaches 0
  • Victory: Gain EXP, money, possibly loot
  • Defeat: Lose EXP, hospitalization

Combat Tracking:

`php

$_SESSION['attacklog'] // Real-time combat log

$_SESSION['attacking'] // Current target (prevents multi-target)

$_SESSION['attackwon'] // Victory target

$_SESSION['attacklost'] // Defeat flag

`

Attack Logs (attacklogs table):

  • Records all combat encounters
  • Attacker/defender IDs
  • Timestamps
  • Outcomes

4.4 Gang System

Gang Features:

  • Gang Creation (creategang.php)
  • Gang Management (gangcentral.php)
  • Gang Wars (gangwars.php)
  • Gang Applications (applications table)
  • Gang Membership (gangs table)

Gang Activities:

  • Organized crimes
  • Territory control
  • Warfare between gangs
  • Shared resources/benefits

4.5 Economy System

Currency Types:

  • Money - Standard currency (crimes, jobs, attacks)
  • Crystals - Premium currency (special features)
  • Bank Money - Stored funds

Money Sources:

  • Crimes - High risk, high reward
  • Jobs - Steady income (job.php)
  • Combat - Loot from victories
  • Item Sales - Player market

Money Sinks:

  • Items - Weapons, armor, consumables
  • Property - Houses (estate.php)
  • Education - Training courses
  • Services - Hospital, gym, etc.

Banking (bank.php, cyberbank.php):

  • Deposit/withdraw funds
  • Inter-player transfers (sendbank.php)
  • Transaction logging

Crystal Market (cmarket.php):

  • Buy/sell premium currency
  • Player-to-player trades
  • Exchange rates

4.6 Item System

Item Categories (itemtypes):

  • Weapons (primary/secondary)
  • Armor
  • Consumables
  • Special items

Item Management:

  • Inventory (inventory.php)
  • Equip/Unequip (equip_weapon.php, equip_armor.php, unequip.php)
  • Buy/Sell (itembuy.php, itemsell.php)
  • Send (itemsend.php)
  • Use (itemuse.php)
  • Market (itemmarket.php)

Item Info (iteminfo.php):

  • Stats display
  • Requirements
  • Effects

4.7 Property System

Real Estate (estate.php):

  • Buy/sell houses
  • House stats affect MaxWill
  • Property ownership

House Tiers:

`php

// globals.php line 51

LEFT JOIN houses h ON h.hWILL=u.maxwill

// Houses linked to willpower capacity

`

4.8 Education System

Training (education.php):

  • Complete courses
  • Gain stat bonuses
  • Course prerequisites

Course Tracking (coursesdone):

  • Completed courses per player
  • Progress tracking

4.9 Job System

Employment (job.php):

  • Job positions
  • Job ranks (promotions)
  • Salary based on rank
  • Labour stat affects performance

Job Data (jobs, jobranks):

`php

// globals.php lines 47-49

LEFT JOIN jobs j ON j.jID=u.job

LEFT JOIN jobranks jr ON jr.jrID=u.jobrank

`

4.10 Location System

Cities (cities table):

  • Multiple locations (monorail.php for travel)
  • Location-specific content
  • Travel mechanics

Travel Restrictions:

`php

// attack.php line 93

else if($odata['travelling']) {

print "That player is travelling.
";

// Cannot attack traveling players

}

`

4.11 Special Features

Donator System (donator.php):

  • PayPal integration (ipn_donator.php, ipn_wp.php)
  • Premium benefits (donatordays field)
  • Special perks (dps_accepted table)

Mini-Games:

  • Roulette (roulette.php)
  • Slots Machine (slotsmachine.php)
  • Lucky Draw (lucky.php)

Battle Tent (battletent.php):

  • Challenge bots (challengebots table)
  • NPC combat practice

Exploration (explore.php):

  • Random encounters
  • Loot discovery

Crystal Temple (crystaltemple.php):

  • Crystal-related activities

4.12 Communication

Forums (forums.php, forum_viewtopic.php):

  • BBCode support (bbcode_engine.php)
  • Post/reply system
  • Forum categories

Private Messaging (mailbox.php):

  • Inbox/outbox
  • Mail banning (mailban.php)

Announcements (announcements.php):

  • Server-wide notices
  • Admin posts

Events (events.php):

  • In-game notifications
  • Activity tracking

Newspaper (newspaper.php):

  • Game news
  • Player achievements

Contact Lists (contactlist.php, friendslist.php):

  • Friend management
  • Social features

Shoutbox (implied from database)

4.13 Verification System

CAPTCHA (captcha_verify.php):

  • Bot prevention
  • Macro detection (macro1.php, macro2.php)

Macro Protection:

`php

// globals.php lines 68-72

if($macropage && !$ir['verified'] && $set['validate_on']==1) {

header("Location: macro1.php?refer=$macropage");

exit;

}

`

4.14 Staff/Admin System

Admin Panel (secpanel.php, smenu.php):

  • User management (staff_users.php)
  • Item management (staff_items.php)
  • Crime management (staff_crimes.php)
  • Forum moderation (staff_forums.php)
  • Gang oversight (staff_gangs.php)
  • Shop management (staff_shops.php)
  • Location management (staff_cities.php)
  • Course management (staff_courses.php)
  • Job management (staff_jobs.php)
  • Poll management (staff_polls.php)
  • Player punishment (staff_punit.php)
  • Logs viewing (staff_logs.php)
  • Backup system (staff_bck.php)
  • Special actions (staff_special.php)
  • Staff notes (staffnotes.php)

Staff Tools:

  • Player editing
  • Force logout (force_logout field)
  • Ban system
  • IP logging (lastip, lastip_signup)

4.15 Cron Jobs

4 Cron Scripts:

1. Minute Cron (cron_minute.php):

  • Energy regeneration
  • Will regeneration
  • Brave regeneration
  • HP regeneration (if not in hospital)
  • Most frequent updates

2. Five Minute Cron (cron_fivemins.php):

  • Medium-frequency tasks
  • Likely market updates, travel completion

3. Hourly Cron (cron_hour.php):

  • Job salary payments
  • House benefits
  • Hourly bonuses

4. Daily Cron (cron_day.php):

  • Daily resets
  • Cleanup tasks
  • Long-term stat updates

Cron Security:

`php

// config.php line 8

'code' => '2c72366341cc8e9c36fc7565fe77b1b4'

// URL: cron_minute.php?code=

`

---

5. Security Analysis

5.1 Critical Vulnerabilities (2/10)

1. eval() Code Execution (CATASTROPHIC):

`php

// docrime.php lines 19-23

$ec="\$sucrate=".str_replace(

array("LEVEL","CRIMEXP","EXP","WILL","IQ"),

array($ir['level'], $ir['crimexp'], $ir['exp'], $ir['will'], $ir['IQ']),

$r['crimePERCFORM']

).";";

eval($ec);

`

Impact:

  • If admin modifies crime formulas maliciously → arbitrary PHP execution
  • Database compromise → full server takeover
  • Severity: 10/10 - Never use eval() with database content!

2. SQL Injection (WIDESPREAD):

`php

// attack.php line 36

$q=$db->query("SELECT u.,us. FROM users u

LEFT JOIN userstats us ON u.userid=us.userid

WHERE u.userid={$_GET['ID']}");

// docrime.php line 12

$q=mysql_query("SELECT * FROM crimes WHERE crimeID={$_GET['c']}",$c);

`

Impact:

  • Direct injection of $_GET/$_POST into SQL
  • addslashes() insufficient (character set attacks)
  • No prepared statements
  • Severity: 9/10

3. Type Juggling:

`php

// attack.php line 6

$_GET['ID'] == (int) $_GET['ID']; // == instead of =

// This compares but DOESN'T CAST! Bug, not security, but shows poor QA

`

4. Magic Quotes Dependency:

`php

// globals.php lines 8-18

if(get_magic_quotes_gpc() == 0) {

// Manually add slashes

}

`

  • Magic quotes removed PHP 5.4 (2012)
  • Inconsistent escaping
  • Modern PHP incompatible

5. MD5 Password Hashing (No Salt):

`php

md5('{$_POST['password']}')

`

  • MD5 broken (rainbow tables)
  • No salt = trivial to crack
  • Modern standard: bcrypt/Argon2

6. Direct Parameter Usage:

`php

// Hundreds of instances like:

$_GET['ID'], $_POST['username'], etc.

// Used directly in queries after only addslashes()

`

7. Session Fixation:

  • No session_regenerate_id() on login
  • Session hijacking possible

8. Information Disclosure:

  • Error messages visible
  • error_log file in web root (!)

5.2 Minor Security Issues

9. Weak Input Validation:

`php

$_GET['c']=abs((int) $_GET['c']); // Some casting, but inconsistent

`

10. No CSRF Protection:

  • Forms lack tokens
  • State-changing GET requests

11. Force Logout Mechanism:

`php

if($ir['force_logout']) {

// Admin can force logout, but field could be manipulated

}

`

5.3 Security Score: 2/10

Rationale:

  • eval() with database content = 0/10 by itself (instant disqualification)
  • SQL injection everywhere = 0/10
  • MD5 passwords = +1 point (better than plaintext)
  • Session system = +1 point (exists)
  • WORST SECURITY TIER (tied with Skrupel 2/10, Solar Empire 1/10)

Cannot Deploy Publicly: eval() + SQL injection = compromised within hours

Required Security Fixes (100-200 hours):

  • Remove ALL eval() calls - Rewrite crime formula system
  • Convert to PDO prepared statements
  • Replace MD5 with password_hash()
  • Remove magic quotes handling
  • Add input validation (whitelisting)
  • Implement CSRF tokens
  • Session regeneration on login
  • Move error_log outside webroot
  • Type cast ALL numeric inputs
  • Security audit all 129 PHP files

---

6. Technical Observations

6.1 Code Quality

Positive Aspects:

  • Database abstraction (MySQL/MySQLi switchable)
  • Utility function library (global_func.php)
  • Cron job automation
  • Modular file structure
  • AJAX password strength checker (register.php)

Negative Aspects:

  • eval() usage (unforgivable)
  • No framework
  • Magic quotes dependency
  • Flat file structure (no MVC)
  • Mixed PHP/HTML throughout
  • Poor error handling
  • No input validation library
  • Inconsistent coding standards

6.2 Database Design

Strengths:

  • Normalized structure
  • 44+ tables for different features
  • Join queries (LEFT JOIN)
  • Transaction logging tables

Weaknesses:

  • No foreign key constraints
  • Direct queries (no ORM)
  • String-based SQL construction
  • No query builders

6.3 Feature Completeness

Comprehensive Systems:

  • Crime mechanics with formulas
  • Combat system
  • Gang warfare
  • Economy (3 currency types)
  • Item management
  • Property ownership
  • Education/training
  • Jobs/ranks
  • Multiple locations
  • Forums/messaging
  • Donator integration
  • Mini-games
  • Admin panel
  • Cron automation

Missing Features:

  • API/mobile support
  • Modern frameworks
  • Security best practices
  • Unit tests
  • Documentation beyond readme

---

7. Historical Context

7.1 Development Era

Year: ~2008-2010 (estimated)

PHP Context: PHP 5.2-5.3 era

  • Magic quotes still common (deprecated 5.3)
  • PDO available but not adopted
  • OOP emerging but not standard
  • Pre-framework era for many developers

Web Gaming Context:

  • Mafia/crime RPGs popular (post-MCCodes era)
  • Browser games peak
  • Freemium models emerging
  • PayPal integration standard

7.2 Commercial Nature

License Agreement:

  • Commercial product (not open source)
  • Support@ email address
  • Professional presentation
  • Automated installer
  • Cron setup documentation

Business Model:

  • Sold as turnkey game script
  • Support included
  • Likely $50-$200 purchase price (typical era)

7.3 Game Lineage

Influenced By:

  • MCCodes (mafia RPG framework)
  • GTA: Underground (crime theme)
  • Torn City (stats, crimes, combat)

Similar Games:

  • Generic Mafia RPG (Game 32)
  • Mafia Warz (Game 42)
  • Mafia Script (Game 41)
  • Street Gang (Game 64 - next!)

Position: Mid-tier commercial crime RPG clone

---

8. Completeness & Playability

8.1 Feature Completeness: 85%

Fully Implemented ( ):

  • User registration/login
  • Crime system with success formulas
  • PvP combat
  • Gang system
  • Item management (buy/sell/equip/use)
  • Property system
  • Education/courses
  • Jobs/ranks
  • Economy (3 currencies)
  • Banking/transfers
  • Forums/messaging
  • Admin panel
  • Cron automation
  • Mini-games
  • Donator integration
  • Staff tools
  • CAPTCHA verification

Partially Implemented (⚠️):

  • PayPal IPN (needs configuration)
  • Email notifications (mail() function)
  • Some admin features incomplete

Missing ( ):

  • Mobile interface
  • API
  • Documentation beyond readme
  • Security patches

8.2 Playability Assessment

Playable: YES (with security warnings)

Requirements:

  • PHP 5.2-5.3 (magic quotes era)
  • MySQL 4.x-5.x
  • Cron job access
  • PayPal account (optional)

Installation Complexity: EASY (automated!)

  • Upload files
  • Navigate to install.php
  • Follow wizard
  • Set up 4 cron jobs
  • Login as admin

Deployment Readiness: 2/10

  • CANNOT deploy publicly - eval() + SQL injection
  • Local testing only - isolated network
  • Security patches mandatory - 100+ hours work

8.3 Game Balance

Crime System:

  • Formula-based success rates
  • Risk/reward scaling
  • Jail punishment

Combat:

  • Turn-based fairness
  • Equipment matters
  • Stat-based outcomes

Economy:

  • Multiple money sources
  • Item value progression
  • Property investment

Progression:

  • Level-based unlocks
  • Stat training
  • Job promotions

---

9. Comparison to Collection

9.1 Ranking Metrics

Size: Small-Medium

  • 129 PHP files
  • 14,567 lines
  • Rank: ~50th/79

Security: WORST TIER

  • 2/10 rating (eval()!)
  • Tied with Skrupel (2/10)
  • Only Solar Empire worse (1/10)
  • Rank: 78th/79

Features: Medium-High

  • 40+ game systems
  • Commercial polish
  • Automated installer
  • Rank: ~25th/79

Code Quality: Poor

  • eval() usage
  • SQL injection
  • Magic quotes
  • Rank: ~65th/79

9.2 Similar Games Comparison

vs Generic Mafia RPG (Game 32):

  • Both: Mafia/crime theme
  • Ravan: More features (gangs, property, jobs)
  • Ravan: Commercial product vs open source
  • Ravan: Automated installer
  • Ravan: WORSE SECURITY (eval()!)

vs MCCodes (Game 40 - 9/10):

  • MCCodes: Framework-level code
  • MCCodes: 9/10 security vs Ravan 2/10
  • MCCodes: Open source vs Ravan commercial
  • Ravan: More beginner-friendly installer
  • Winner: MCCodes by landslide (security!)

vs Solar Empire (Game 62 - 1/10):

  • Solar Empire: extract($_*) disaster
  • Ravan: eval() disaster
  • Both: SQL injection
  • Both: MD5 passwords
  • Winner: Ravan slightly (2/10 > 1/10)

9.3 Genre Standing

Crime RPG Games:

  • MCCodes: 9/10 - Framework king
  • (Other mafia games not yet analyzed)
  • Ravan: 2/10 - Feature-rich but eval() kills it

Overall Collection: 75-78th/79

---

10. Rating & Verdict

10.1 Component Ratings

Aspect Score Notes
Security 2/10 eval()! SQL injection, MD5 passwords
Code Quality 3/10 Flat structure, magic quotes, no framework
Features 7/10 Comprehensive crime/gang/combat systems
Completeness 8/10 85% complete, polished for era
Documentation 6/10 Readme, crime formulas, install guide
Innovation 4/10 Standard mafia clone, no unique features
Balance 6/10 Formula-based crime, balanced economy
Playability 7/10 Works well on PHP 5.2, automated install
Maintainability 3/10 Flat structure, eval(), magic quotes

10.2 Overall Rating: 4/10

"Feature-Rich Crime RPG Destroyed by eval() Security Disaster"

10.3 Strengths

Comprehensive Features - Crime, combat, gangs, property, jobs

Automated Installer - Easy setup via install.php

Database Abstraction - MySQL/MySQLi switchable

Cron Automation - 4-tier task scheduling

Admin Panel - Complete management tools

Commercial Polish - Professional presentation

Crime Formulas - Documented success rate calculations

Gang Warfare - Organized crime mechanics

Mini-Games - Roulette, slots, exploration

Donator System - PayPal integration

CAPTCHA - Bot prevention

10.4 Critical Weaknesses

eval() CODE EXECUTION - Database-driven arbitrary code (CATASTROPHIC!)

SQL INJECTION EVERYWHERE - addslashes() insufficient

MD5 PASSWORDS - No salt, rainbow table vulnerable

MAGIC QUOTES DEPENDENCY - Incompatible with PHP 5.4+

NO INPUT VALIDATION - Direct $_GET/$_POST usage

TYPE JUGGLING BUG - == instead of = (attack.php line 6)

NO CSRF PROTECTION - State-changing GET requests

SESSION FIXATION - No regeneration

FLAT FILE STRUCTURE - No MVC, mixed concerns

ERROR_LOG IN WEBROOT - Information disclosure

10.5 Verdict

Ravan is a feature-complete commercial crime RPG with comprehensive gameplay systems (crime formulas, gang warfare, PvP combat, property, jobs, mini-games) and professional presentation including an automated installer and cron-based automation. However, it contains one of the WORST security vulnerabilities in this entire collection: eval() execution of database-stored crime formulas. Combined with widespread SQL injection, MD5 passwords, and magic quotes dependency, this game is absolutely undeployable in any public environment.

The eval() usage in docrime.php (lines 19-23) allows arbitrary PHP code execution if an attacker compromises the database or admin panel - this is Security 101 violation. Every security professional knows: Never, EVER use eval() with user-influenced or database-stored content. This single line disqualifies the entire codebase from production use.

Beyond the catastrophic eval() issue, SQL injection is everywhere (direct $_GET injection into queries), passwords use unsalted MD5 (trivially crackable), and the code depends on deprecated magic_quotes_gpc (removed PHP 5.4/2012). The game would require 100-200 hours of complete security rewrite to be remotely safe.

As a local/offline game for trusted friends on an isolated network, it's playable and feature-rich. As a public deployment, it's a hacking playground waiting for compromise within hours. The automated installer and commercial polish can't save it from Security 2/10.

10.6 Recommended For

  • Security Students: Learn what NOT to do (eval() example)
  • Local Games: Trusted friends, isolated network only
  • Code Archaeology: Study 2008-era PHP practices
  • Feature Reference: Crime/gang mechanics (AFTER security fixes)

10.7 Not Recommended For

  • Public Deployment: eval() + SQL injection = guaranteed compromise
  • Production Use: Security disaster
  • Learning PHP: Teaches dangerous anti-patterns
  • Modern Hosting: PHP 5.4+ incompatible (magic quotes)
  • Security-Conscious: 2/10 rating

10.8 Historical Significance

Medium - Represents commercial mafia RPG scripts era (2008-2010), demonstrates feature completeness vs security trade-offs, shows automated installer sophistication, serves as cautionary tale about eval() dangers, and documents magic_quotes era PHP practices before deprecation.

---

Analysis Complete: Game 56/79 (70.9%)

Next: Robot Warz (Game 57) when you say "57 go!" OR continue to 64!

Security Warning

Running many of the scripts in this archive on a live server presents a serious security risk. These projects were created before modern hardening practices and may contain vulnerabilities that can compromise your system.

We strongly recommend using this code for reference and analysis only, or in isolated local environments. By downloading these files, you accept full responsibility for their use.