Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

Pascal is not a high-level language. -- Steven Feiner


devel / comp.lang.python / Re: Logging user activity

SubjectAuthor
* Logging user activityblessy carol
+- Re: Logging user activityPeter J. Holzer
+- Re: Logging user activityCameron Simpson
`- Re: Logging user activityJack Dangler

1
Logging user activity

<98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=16924&group=comp.lang.python#16924

  copy link   Newsgroups: comp.lang.python
X-Received: by 2002:a05:6214:1c8a:: with SMTP id ib10mr9622116qvb.63.1644219041991;
Sun, 06 Feb 2022 23:30:41 -0800 (PST)
X-Received: by 2002:a05:6214:194d:: with SMTP id q13mr9363067qvk.53.1644219041687;
Sun, 06 Feb 2022 23:30:41 -0800 (PST)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!news.uzoreto.com!feeder1.cambriumusenet.nl!feed.tweak.nl!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.python
Date: Sun, 6 Feb 2022 23:30:41 -0800 (PST)
Injection-Info: google-groups.googlegroups.com; posting-host=49.37.206.195; posting-account=4EgOVAoAAACveRc1QQlFBEwnKqL1eh5K
NNTP-Posting-Host: 49.37.206.195
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
Subject: Logging user activity
From: carolble...@gmail.com (blessy carol)
Injection-Date: Mon, 07 Feb 2022 07:30:41 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: blessy carol - Mon, 7 Feb 2022 07:30 UTC

Hi,

I have this task where I have to create log files to record user activity whenever they make an entry or view something. Also, I have to create Database log file whenever someone accessed or manipulated the data in the database. The code is written python and used django framework. I've connected django with oracle cloud database. So now I want to if the basic logging details can be used to store the record of these activities in the log file in the server. It would be of great help.

Thanks & Regards,
Blessy.

Re: Logging user activity

<mailman.43.1644272247.7010.python-list@python.org>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=16947&group=comp.lang.python#16947

  copy link   Newsgroups: comp.lang.python
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!not-for-mail
From: hjp-pyt...@hjp.at (Peter J. Holzer)
Newsgroups: comp.lang.python
Subject: Re: Logging user activity
Date: Mon, 7 Feb 2022 23:09:56 +0100
Lines: 65
Message-ID: <mailman.43.1644272247.7010.python-list@python.org>
References: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
<20220207220956.jaddrujdxuydk32k@hjp.at>
Mime-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha512;
protocol="application/pgp-signature"; boundary="zbp5ioughj52ptqf"
X-Trace: news.uni-berlin.de LDWL7uZhnH45yDLNCp4AVgj2PPe7Shj6buSDaQZ50zZw==
Return-Path: <hjp-python@hjp.at>
X-Original-To: python-list@python.org
Delivered-To: python-list@mail.python.org
Authentication-Results: mail.python.org; dkim=none reason="no signature";
dkim-adsp=none (unprotected policy); dkim-atps=neutral
X-Spam-Status: OK 0.002
X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; '(which': 0.04; 'content-
type:multipart/signed': 0.05; 'django': 0.07; 'content-
type:application/pgp-signature': 0.09; 'filename:fname piece:asc':
0.09; 'filename:fname piece:signature': 0.09;
'filename:fname:signature.asc': 0.09; 'log': 0.12; 'that.': 0.15;
'"creative': 0.16; '__/': 0.16; 'accessed': 0.16; 'app,': 0.16;
'challenge!"': 0.16; 'database.': 0.16; 'extracts': 0.16;
'framework.': 0.16; 'from:addr:hjp-python': 0.16;
'from:addr:hjp.at': 0.16; 'from:name:peter j. holzer': 0.16;
'hjp@hjp.at': 0.16; 'holzer': 0.16; 'layer.': 0.16; 'logs': 0.16;
'option.': 0.16; 'reality.': 0.16; 'something.': 0.16; 'stross,':
0.16; 'url-ip:212.17.106.137/32': 0.16; 'url-ip:212.17.106/24':
0.16; 'url-ip:212.17/16': 0.16; 'url:hjp': 0.16; '|_|_)': 0.16;
'wrote:': 0.16; 'python': 0.16; 'probably': 0.17; 'server.': 0.19;
'to:addr:python-list': 0.20; 'written': 0.22; "i've": 0.22;
'code': 0.23; 'views': 0.23; "i'd": 0.24; 'depends': 0.25; 'task':
0.26; 'sense': 0.28; 'extract': 0.32; 'structure': 0.32; 'but':
0.32; 'there': 0.33; 'server': 0.33; 'someone': 0.34; 'header:In-
Reply-To:1': 0.34; 'request': 0.35; 'also,': 0.36; 'files': 0.36;
'system,': 0.36; 'necessarily': 0.37; 'really': 0.37; "it's":
0.37; 'hard': 0.37; 'file': 0.38; 'could': 0.38; 'two': 0.39;
'otherwise': 0.39; 'level.': 0.40; 'whenever': 0.40; 'want': 0.40;
'try': 0.40; 'view': 0.60; 'point.': 0.62; 'received:212': 0.62;
'activity': 0.64; 'in.': 0.64; 'your': 0.64; 'activities': 0.65;
'received:userid': 0.66; 'interested': 0.68; 'manner': 0.69;
'oracle': 0.69; 'piece': 0.69; 'url-ip:212/8': 0.69; 'ability':
0.71; 'audit': 0.76; 'database': 0.80; 'queries': 0.81; 'carol':
0.84; 'itself.': 0.84; 'manipulated': 0.84; 'received:at': 0.84
Content-Disposition: inline
In-Reply-To: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
X-BeenThere: python-list@python.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: General discussion list for the Python programming language
<python-list.python.org>
List-Unsubscribe: <https://mail.python.org/mailman/options/python-list>,
<mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive: <https://mail.python.org/pipermail/python-list/>
List-Post: <mailto:python-list@python.org>
List-Help: <mailto:python-list-request@python.org?subject=help>
List-Subscribe: <https://mail.python.org/mailman/listinfo/python-list>,
<mailto:python-list-request@python.org?subject=subscribe>
X-Mailman-Original-Message-ID: <20220207220956.jaddrujdxuydk32k@hjp.at>
X-Mailman-Original-References: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
 by: Peter J. Holzer - Mon, 7 Feb 2022 22:09 UTC
Attachments: signature.asc (application/pgp-signature)

On 2022-02-06 23:30:41 -0800, blessy carol wrote:
> I have this task where I have to create log files to record user
> activity whenever they make an entry or view something. Also, I have
> to create Database log file whenever someone accessed or manipulated
> the data in the database. The code is written python and used django
> framework. I've connected django with oracle cloud database. So now I
> want to if the basic logging details can be used to store the record
> of these activities in the log file in the server.

There are three places where you can do that in a centralized manner:

1. In the database itself. AFAIK Oracle has an audit system, but I've
never used it.
2. At the Django ORM layer. Django has the ability to log all database
queries it makes
3. At the web request level. Your web server (probably) already logs
every request but not necessarily the information you are interested
in. But you could write a piece of middleware for your Django which
extracts log-worthy information and logs that.

The first two options are probably too low-level, and especially the
second is really hard to interpret in an automated manner (which is what
you probably want to do - otherwise why log in the first place?)

So I'd try the third option. But it really depends a lot on the
structure of your application on whether it's feasible to extract all
the data you need at that point. It's possible that you will have to go
through all the views in your app, see what data they are requesting and
altering and craft appropriate log messages for each.

hp

--
_ | Peter J. Holzer | Story must make more sense than reality.
|_|_) | |
| | | hjp@hjp.at | -- Charles Stross, "Creative writing
__/ | http://www.hjp.at/ | challenge!"

Attachments: signature.asc (application/pgp-signature)
Re: Logging user activity

<mailman.46.1644273646.7010.python-list@python.org>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=16950&group=comp.lang.python#16950

  copy link   Newsgroups: comp.lang.python
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!news.szaf.org!fu-berlin.de!uni-berlin.de!not-for-mail
From: cs...@cskk.id.au (Cameron Simpson)
Newsgroups: comp.lang.python
Subject: Re: Logging user activity
Date: Tue, 8 Feb 2022 09:40:40 +1100
Lines: 51
Message-ID: <mailman.46.1644273646.7010.python-list@python.org>
References: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
<YgGf6HRfYBcC3Ou2@cskk.homeip.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Trace: news.uni-berlin.de DeDRmNyGxSTNMAO6yboUjAgI15B9+PcTQY6JzbTefltA==
Return-Path: <cameron@cskk.id.au>
X-Original-To: python-list@python.org
Delivered-To: python-list@mail.python.org
Authentication-Results: mail.python.org; dkim=none reason="no signature";
dkim-adsp=none (unprotected policy); dkim-atps=neutral
X-Spam-Status: OK 0.001
X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; '(which': 0.04; 'bunch':
0.05; 'containing': 0.05; 'thread': 0.05; 'django': 0.07;
'parent': 0.07; 'ticket': 0.07; 'driven': 0.09; 'etc).': 0.09;
'fails': 0.09; 'instances': 0.09; 'json': 0.09; 'cheers,': 0.11;
'log': 0.12; '(because': 0.16; 'accessed': 0.16; 'an:': 0.16;
'cameron': 0.16; 'database.': 0.16; 'elsewhere': 0.16;
'from:addr:cs': 0.16; 'from:addr:cskk.id.au': 0.16;
'from:name:cameron simpson': 0.16; 'instance': 0.16; 'instance)':
0.16; 'message-id:@cskk.homeip.net': 0.16; 'received:13.237':
0.16; 'received:13.237.201': 0.16; 'received:13.237.201.189':
0.16; 'received:cskk.id.au': 0.16; 'received:id.au': 0.16;
'received:mail.cskk.id.au': 0.16; 'relevant,': 0.16; 'setup.':
0.16; 'simpson': 0.16; 'something.': 0.16; 'wrote:': 0.16;
'python': 0.16; 'probably': 0.17; 'calls': 0.19; 'server.': 0.19;
'to:addr:python-list': 0.20; 'written': 0.22; "i've": 0.22;
'code': 0.23; 'task': 0.26; 'requests': 0.28; 'error': 0.29;
'header:User-Agent:1': 0.30; 'fine.': 0.32; 'but': 0.32; 'there':
0.33; 'someone': 0.34; 'header:In-Reply-To:1': 0.34;
'received:au': 0.35; 'also,': 0.36; 'files': 0.36; 'couple': 0.37;
'this.': 0.37; 'file': 0.38; 'way': 0.38; 'use': 0.39; 'table':
0.39; 'hand': 0.40; 'whenever': 0.40; 'something': 0.40; 'want':
0.40; 'reference': 0.60; 'view': 0.60; 'here.': 0.61; "there's":
0.61; 'great': 0.63; 'received:13': 0.64; 'skip:g 30': 0.64;
'transaction': 0.64; 'your': 0.64; 'activities': 0.65; 'yours':
0.65; 'received:userid': 0.66; 'back': 0.67; 'outside': 0.67;
'away': 0.67; 'oracle': 0.69; 'tracking': 0.76; 'field': 0.78;
'database': 0.80; '(like': 0.84; 'carol': 0.84; 'catch': 0.84;
'manipulated': 0.84; 'massive': 0.84; 'rolls': 0.84;
'transaction.': 0.84; 'transactions': 0.84; 'us,': 0.89
Mail-Followup-To: python-list@python.org
Content-Disposition: inline
In-Reply-To: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
User-Agent: Mutt/2.1.5 (2021-12-30)
X-BeenThere: python-list@python.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: General discussion list for the Python programming language
<python-list.python.org>
List-Unsubscribe: <https://mail.python.org/mailman/options/python-list>,
<mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive: <https://mail.python.org/pipermail/python-list/>
List-Post: <mailto:python-list@python.org>
List-Help: <mailto:python-list-request@python.org?subject=help>
List-Subscribe: <https://mail.python.org/mailman/listinfo/python-list>,
<mailto:python-list-request@python.org?subject=subscribe>
X-Mailman-Original-Message-ID: <YgGf6HRfYBcC3Ou2@cskk.homeip.net>
X-Mailman-Original-References: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
 by: Cameron Simpson - Mon, 7 Feb 2022 22:40 UTC

On 06Feb2022 23:30, blessy carol <carolblessy15@gmail.com> wrote:
>I have this task where I have to create log files to record user
>activity whenever they make an entry or view something. Also, I have to
>create Database log file whenever someone accessed or manipulated the
>data in the database. The code is written python and used django
>framework. I've connected django with oracle cloud database. So now I
>want to if the basic logging details can be used to store the record of
>these activities in the log file in the server. It would be of great
>help.

For the file, you can do that directly in the logging configuration -
there's a FileHandler with a bunch of configuration options (like
rolling over to a new file etc). Hook that to your logging setup.

For the db side, make a Djanog Model for your log table and write your
own logging handler which makes new instance of the model containing log
information. There might even by a prebuilt Django logging thing
available for that - I haven't looked.

We had a "log everything!" requests for a project here.

I made a generic AuditLog Django model for this. It has a timestamp, a
description, a log_type PositiveIntegerField, a user field (because we
were tracking things by User, can be NULL for things not driven by a
User eg app internals), a parent (ForeignKey to the AuditLog model so
you can make hierarchical related log entries), and an:

entity = GenericForeignKey("entity_type", "entity_uuid")

which was a reference to some "primary" entity (Model instance)
elsewhere where that was relevant, and a couple of JSON fields for state
information.

This is massive overkill for your needs, but we only wanted to do this
once, so needs like yours also use this model here.

Then you can write simple log calls which make model instances with what
you need to log in them.

The only only real catch for us was transactions - if something fails
and rolls back the transaction it also throws away the log entries
because they're in the transaction. For your needs that is probably
fine.

For us, we want to use it for error tracking/diagnosis too, so I've got
a ticket to hand the logging to a distinct Thread (which magicly makes a
distinct db connection, outside the transaction). That way the logging
can survive a transaction rollback.

Cheers,
Cameron Simpson <cs@cskk.id.au>

Re: Logging user activity

<mailman.51.1644321849.7010.python-list@python.org>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=16959&group=comp.lang.python#16959

  copy link   Newsgroups: comp.lang.python
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!not-for-mail
From: tdl...@gmail.com (Jack Dangler)
Newsgroups: comp.lang.python
Subject: Re: Logging user activity
Date: Tue, 8 Feb 2022 07:04:04 -0500
Lines: 51
Message-ID: <mailman.51.1644321849.7010.python-list@python.org>
References: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
<20220207220956.jaddrujdxuydk32k@hjp.at>
<ae8ca18c-3b5c-f444-54c0-7f1dfd967842@gmail.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 7bit
X-Trace: news.uni-berlin.de bNtwgJx+VpTGUwjlJUAFyAWQPDDOUnQUL7qZWxeMRnRg==
Return-Path: <tdldev@gmail.com>
X-Original-To: python-list@python.org
Delivered-To: python-list@mail.python.org
Authentication-Results: mail.python.org; dkim=pass
reason="2048-bit key; unprotected key"
header.d=gmail.com header.i=@gmail.com header.b=RSIHNhfH;
dkim-adsp=pass; dkim-atps=neutral
X-Spam-Status: OK 0.072
X-Spam-Evidence: '*H*': 0.86; '*S*': 0.00; '(which': 0.04; 'django':
0.07; 'task.': 0.07; 'jack': 0.09; 'log': 0.12; 'that.': 0.15;
'accessed': 0.16; 'app,': 0.16; 'database.': 0.16; 'extracts':
0.16; 'framework.': 0.16; 'holzer': 0.16; 'layer.': 0.16;
'lesson': 0.16; 'logs': 0.16; 'option.': 0.16; 'something.': 0.16;
'wrote:': 0.16; 'python': 0.16; 'probably': 0.17; 'message-
id:@gmail.com': 0.18; 'pm,': 0.19; 'server.': 0.19; 'to:addr
:python-list': 0.20; 'written': 0.22; "i've": 0.22; 'code': 0.23;
'views': 0.23; "i'd": 0.24; 'depends': 0.25; 'do,': 0.26; 'task':
0.26; 'header:User-Agent:1': 0.30; 'url-ip:188/8': 0.31; 'think':
0.32; 'extract': 0.32; 'structure': 0.32; 'but': 0.32; "i'll":
0.33; 'there': 0.33; 'server': 0.33; 'someone': 0.34; 'package':
0.34; 'header:In-Reply-To:1': 0.34; 'received:google.com': 0.34;
'from:addr:gmail.com': 0.35; 'request': 0.35; 'also,': 0.36;
'files': 0.36; 'system,': 0.36; 'necessarily': 0.37; 'really':
0.37; "it's": 0.37; 'received:209.85': 0.37; 'hard': 0.37;
'this.': 0.37; 'file': 0.38; 'could': 0.38; 'put': 0.38; 'read':
0.38; 'received:209': 0.39; 'two': 0.39; 'otherwise': 0.39;
'developers': 0.39; 'received:209.85.222': 0.39; 'level.': 0.40;
'whenever': 0.40; 'something': 0.40; 'want': 0.40; 'try': 0.40;
'should': 0.40; 'view': 0.60; 'charset:windows-1252': 0.60;
'paid': 0.61; 'customers': 0.62; 'point.': 0.62; 'everything':
0.63; 'complete': 0.64; 'activity': 0.64; 'in.': 0.64; 'your':
0.64; 'activities': 0.65; 'look': 0.65; 'nearly': 0.67;
'interested': 0.68; 'manner': 0.69; 'oracle': 0.69; 'piece': 0.69;
'ability': 0.71; 'offer': 0.71; 'audit': 0.76; 'database': 0.80;
'queries': 0.81; 'position': 0.81; 'need.': 0.84; 'carol': 0.84;
'itself.': 0.84; 'manipulated': 0.84
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
h=subject:to:references:from:message-id:date:user-agent:mime-version
:in-reply-to:content-transfer-encoding:content-language;
bh=+Tpu3ID9wgSVkfyquQnNIePsLh62GHPTyG6mURMvkQg=;
b=RSIHNhfH1CaxPiaBHkEX96NWo9UR23R3Zx45IZY3xyTHB1e1mQMUWMYpFExjPZnyOr
A3tdmrw5d40GVy8GLsghSNz6cpSfTFdDUPHo+1sumxeuDwUSfT5b1AmUMkZ/Qajgp1/e
XQdWsGnZzJ1H483TDVKen+doqtlPqUJhU9/9L58OZHIIOee3yU/WmrHeyAsZ5t16QcLe
OrsBMxOeIpMlOBS06L8Vc/vzhJK1tkiFFPZUzcMKH05Sqds4c7+XcYVBcQESoe3aYCo7
4F51o8yUlvl/00txVVG41gTBbuUyItf8bICGlnyRV64dyw/hN3TINYtQbsNn9TiIYIks
vrJQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20210112;
h=x-gm-message-state:subject:to:references:from:message-id:date
:user-agent:mime-version:in-reply-to:content-transfer-encoding
:content-language;
bh=+Tpu3ID9wgSVkfyquQnNIePsLh62GHPTyG6mURMvkQg=;
b=zNFxcqJ3dzcz/DZLnYUhZ1wtRdhzCR4VHV9V97Sjf3rivp3jyNNE9QXB8Apj6nXh/r
ZszorJ2QFnAjgv0ZSuy2dDI0poqIr2O3vGghwUoauF5wBNUqN+5admBON//ttYVpJd8c
xWOo2t9peOVc4btJS8Ae7XhtL5jmq/SlkXPBQ93q8v404+dsQjOY1d4FmoXyCr3tQXg5
NvFrN6H2FRutaETAb3Eq9u9zdDkthSAvd0XHQt52staz7r4STzWY4RYGcF8GBB2hMhvw
3zPY0QUOTdrR4RfD8+HLPjTD0ptaeUCiV32LXLlkVqjyPso4scPLSAywzrmdMn32fNwr
li9w==
X-Gm-Message-State: AOAM5319X7j9L9M3rYyuDpOkREPd9J6KJBplgEx062gI37Z0qVqWGLHB
9GGQ1NZ4KLGEhjabBRWRXj+ChWBt/Z8=
X-Google-Smtp-Source: ABdhPJxlWNH1x9dJfCLhOo7sNkBwZASKMDBEil7XzyZtB6HeQDbIopf7AGoR5RGrWQjdZGWHxPpvIg==
X-Received: by 2002:a37:a707:: with SMTP id q7mr2316122qke.229.1644321846339;
Tue, 08 Feb 2022 04:04:06 -0800 (PST)
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101
Thunderbird/78.14.0
In-Reply-To: <20220207220956.jaddrujdxuydk32k@hjp.at>
Content-Language: en-US
X-BeenThere: python-list@python.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: General discussion list for the Python programming language
<python-list.python.org>
List-Unsubscribe: <https://mail.python.org/mailman/options/python-list>,
<mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive: <https://mail.python.org/pipermail/python-list/>
List-Post: <mailto:python-list@python.org>
List-Help: <mailto:python-list-request@python.org?subject=help>
List-Subscribe: <https://mail.python.org/mailman/listinfo/python-list>,
<mailto:python-list-request@python.org?subject=subscribe>
X-Mailman-Original-Message-ID: <ae8ca18c-3b5c-f444-54c0-7f1dfd967842@gmail.com>
X-Mailman-Original-References: <98256dd6-c4ef-413e-aa50-caa5e1841d4fn@googlegroups.com>
<20220207220956.jaddrujdxuydk32k@hjp.at>
 by: Jack Dangler - Tue, 8 Feb 2022 12:04 UTC

On 2/7/22 5:09 PM, Peter J. Holzer wrote:
> On 2022-02-06 23:30:41 -0800, blessy carol wrote:
>> I have this task where I have to create log files to record user
>> activity whenever they make an entry or view something. Also, I have
>> to create Database log file whenever someone accessed or manipulated
>> the data in the database. The code is written python and used django
>> framework. I've connected django with oracle cloud database. So now I
>> want to if the basic logging details can be used to store the record
>> of these activities in the log file in the server.
> There are three places where you can do that in a centralized manner:
>
> 1. In the database itself. AFAIK Oracle has an audit system, but I've
> never used it.
> 2. At the Django ORM layer. Django has the ability to log all database
> queries it makes
> 3. At the web request level. Your web server (probably) already logs
> every request but not necessarily the information you are interested
> in. But you could write a piece of middleware for your Django which
> extracts log-worthy information and logs that.
>
> The first two options are probably too low-level, and especially the
> second is really hard to interpret in an automated manner (which is what
> you probably want to do - otherwise why log in the first place?)
>
> So I'd try the third option. But it really depends a lot on the
> structure of your application on whether it's feasible to extract all
> the data you need at that point. It's possible that you will have to go
> through all the views in your app, see what data they are requesting and
> altering and craft appropriate log messages for each.
>
> hp
>
>
Short of a long lesson on why software developers should always think of
logging/monitoring components to everything they write, I'll just offer
this. It's worth the read and should put you in a good position to
complete your task.

https://www.askpython.com/django/django-logging

If you're after something that you're being paid to do, look into
Splunk! It's a robust package that offers logging and correlation of
data on nearly any level of complication/sophistication your customers need.

Hope this helps.

Regards

Jack

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor