---
title: "Error Meldung bei TYPO3 Install Tool / Call to undefined method com::GetRandom()"
url: "https://www.typo3.net/d/100633-error-meldung-bei-typo3-install-tool-call-to-undefined-method-comgetrandom"
source: "typo3.net"
tags: ["Hosting","Lokale Umgebung","Frage","PHP"]
created: "2010-08-15"
last_reply: "2010-09-04"
replies: 2
solved: false
page: 1
pages: 1
lang: "de"
---

# Error Meldung bei TYPO3 Install Tool / Call to undefined method com::GetRandom()

Hosting › Lokale Umgebung · 2 Antworten · gestartet 2010-08-15

## Eröffnungsbeitrag

**andreas1982** · 2010-08-15 · [Beitrag #1](https://www.typo3.net/d/100633-error-meldung-bei-typo3-install-tool-call-to-undefined-method-comgetrandom/1)

Hallo, ich möchte gerne TYPO3 4.4 mit dem TYPO3 Install Tool installieren. Wenn ich auf Continue drücke bekomme ich folgende Fehlermeldung:

Fatal error: Call to undefined method com::GetRandom() in C:\xampp\htdocs\typo3\t3lib\class.t3lib_div.php on line 1590

Ich hab das ganze local in xampp (Version 1.7.1) laufen.

Kann mir jemand weitehelfen warum ich diese Fehlermeldung bekomme?

Gruß

## Antworten

### [#2](https://www.typo3.net/d/100633-error-meldung-bei-typo3-install-tool-call-to-undefined-method-comgetrandom/2) · Zapper · 2010-08-16

Sry for the reply in english..

I can confirm the error upon install, and i found the same error when i try to run index.php in main dir.

```php
Fatal error: Call to undefined method com::GetRandom() in C:\Inetpub\wwwroot\typo3test\t3lib\class.t3lib_div.php on line 1590
```

From what i can see in the code, there is a call to CAPICOM if the system is windows, CAPICOM is not mandetory installation!! and should not be required from the code.

```php
	/**
	 * Returns a string of highly randomized bytes (over the full 8-bit range).
	 *
	 * @copyright	Drupal CMS
	 * @license		GNU General Public License version 2
	 * @param		integer  Number of characters (bytes) to return
	 * @return		string   Random Bytes
	 */
public static function generateRandomBytes($count) {
		$output = '';
			// /dev/urandom is available on many *nix systems and is considered
			// the best commonly available pseudo-random source.
		if (TYPO3_OS != 'WIN' && ($fh = @fopen('/dev/urandom', 'rb'))) {
			$output = fread($fh, $count);
			fclose($fh);
		} elseif (TYPO3_OS == 'WIN') {
			if (class_exists('COM')) {
				try {
					$com = new COM('CAPICOM.Utilities.1');
					$output = base64_decode($com->GetRandom($count, 0));
				} catch(Exception $e) {
					// CAPICOM not installed
				}
			}
			if ($output === '' && version_compare(PHP_VERSION, '5.3.0', '>=')) {
				if (function_exists('mcrypt_create_iv')) {
					$output = mcrypt_create_iv($count, MCRYPT_DEV_URANDOM);
				} elseif (function_exists('openssl_random_pseudo_bytes')) {
					$isStrong = null;
					$output = openssl_random_pseudo_bytes($count, $isStrong);
						// skip ssl since it wasn't using the strong algo
					if ($isStrong !== TRUE) {
						$output = '';
					}
				}
			}
		}
```

Is there a workaround CAPICOM?

thx
Zap

### [#3](https://www.typo3.net/d/100633-error-meldung-bei-typo3-install-tool-call-to-undefined-method-comgetrandom/3) · devx · 2010-09-04

Capicom mittels regsrv32 registrieren (Adminrechte notwendig)

Konsole:
**regsvr32 Pfad/zur/capicom.dll**

Falls noch nicht installiert, dann könnt ihr diese über das Microsoft SDK mit herunterladen / installieren: [Download Capicom](http://www.microsoft.com/downloads/details.aspx?FamilyId=860EE43A-A843-462F-ABB5-FF88EA5896F6&displaylang=de)

---

Quelle: „Error Meldung bei TYPO3 Install Tool / Call to undefined method com::GetRandom()“, typo3.net, https://www.typo3.net/d/100633-error-meldung-bei-typo3-install-tool-call-to-undefined-method-comgetrandom
Beiträge von Mitgliedern des Forums. Bitte mit Link auf die Diskussion zitieren.
