""

Cómo descifrar el CMS en SAP BusinessObjects R2 / R3. 1

Unlike previous versions of SAP BusinessObjects, the system database in the XI releases is encrypted and cannot be manually queried or modified by the system administrators. SAP BusinessObjects includes one tool called Query Builder, which can be used to perform some queries against the system database, but the power of these queries is very limited.

While working with SAP BusinessObjects XI, I have been in a couple of situations when access to the system database has been a must. After doing some internal research and web searches I found a way to query / delete some records of the CMS DB using an easy decryption algorithm. It is very important to say that querying / modifying directly in the system database is not supported by SAP BusinessObjects, but it can help us in some extreme situations.

In this blog post I will focus on the table CMS_INFOOBJECTS5 that stores the information of all the objects that we have in the system (each object is a row). In BusinessObjects XI R3.1 the table is called CMS_INFOOBJECTS6 but the structure and encryption algorithm are the same as in R2.

CMS_INFOOBJECTS5 Descripción de la tabla

When accessing the table CMS_INFOOBJECTS5 we see that it contains a lot of columns. However we will just focus on the following:

  • ObjectID: The identifier of the row (object) in the table

  • ParentID: The parent’s ObjectID of the object (We can make a self-join)

  • TypeID: Numerical code that describes the object type.

  • OwnerID: The ObjectID of the owner of the object (We can make a self-join)

  • LastModifyTime: Last time the object has been modified

  • CRC: The CRC Code

  • SI_CUID: Identificador único de clúster del objeto en el sistema

  • ObjName: nombre del objeto (cifrado)

  • Properties: Field that contains the properties of the object

ObjName Encryption

When we try to query the CMS_INFOOBJECTS5 table, this field is encrypted. The encryption code used is as follows:

Letters: Encoded and Decoded Characters
Números: caracteres codificados y decodificados
Dashes: Encoded and Decoded Characters
Brackets: Encoded and Decoded Characters

Esta lista no está completa, pero tenemos los caracteres más importantes que necesitamos para comprender lo que se almacena en el campo.

Note that after decrypting the fields we will see that the last three characters of the field are some sort of code (It appears that this code is related to the object type). We can ignore this.

TypeID Decode

Los códigos y descripciones más importantes para los diferentes tipos de objetos son:

TypeID and Descriptions

Sample Query

The following sample query for Oracle includes the information described above and shows us some useful information about our system. For SQL Server we should use the replace function for all the characters instead of using the Oracle’s translate function.

select objectid, parentid, LastModifyTime, REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( REPLACE( translate(objname,')+-/13579;=?ACEGIKMOQSUWY]','ABCDEFGHIJKLMNOPQRSTUVWXYZ'), '!`|<','0'), '!`|>','1'), '!`|@','2'), '!`|B','3'), '!`|D','4'), '!`|F','5'), '!`|H','6'), '!`|J','7'), '!`|L','8'), '!`|N','9'), '!M|N"','_'), '!M|N','_'), '!M|Z','-'), '!B|C','('), '!B|D',')'), '!@{',' '), '!.{','.') as Decoded, decode(typeid,1,'Folder',331,'WebI',295,'DeskI',337,'Universe',263,'Connection',342, 'Word',323,'PDF',336,'Text',285,'Excel',324,'PPT',20,'Group',16,'Service',24, 'License',typeid) objtype from BOREPO.CMS_INFOOBJECTS5 order by objectid

Example Situations / How to proceed

As I explained at the beginning of the post, I have been in two situations when I needed to modify the table to fix serious problems in the system:

  1. Impossible to access Performance Manager: We set up a connection for Performance Manager with a large number of tables. When we tried to access it again to change the connection, the system crashed.

  2. Licencias duplicadas: Estábamos agregando una nueva licencia para el sistema y accidentalmente hicimos clic en el botón "Agregar" dos veces. Como resultado, se agregaron dos licencias al sistema y no pudimos eliminar ninguna de ellas ni agregar otras nuevas. Además, seguimos recibiendo un error de "licencia duplicada".

Es muy importante decir que no podemos editar ningún campo de la fila o dañaremos el sistema; solo podemos eliminar filas. Si eliminamos una fila que el sistema espera tener (es decir, la configuración de Performance Manager), el sistema volverá a crear la fila con los valores predeterminados una vez que iniciemos el servicio CMS.

When making modifications to the system database, the process to follow is:

  1. Detener todos los servicios de BO

  2. Delete the desired row

  3. Reinicie todos los servicios de BO

Note that this restart will take some extra time.

If you have any feedback or questions about this method, I will be happy to read and answer your comments.

EspañolEnglish