Re: How to monitor content updates or deletion in Django web applications

2023-10-04 Thread Timothy Myers
I am also not sure of the scope of your question.  If you're asking about a
file deleted from the system by a method other than Django.  I use a 
trusted database
of files required with a hash and have a process (Django script) that runs 
and checks
both the presence of a file and its hash code.   
This notifies me of not only deletions but also changes to core items that 
I want to monitor by any 
method outside my control updates that maintain the trusted database and 
log dates who made the change.   
This also helped me monitor for duplicate pictures and files so that if 
someone loads a second copy of the 
same picture for a different page even with a different name it is noted by 
the hashcode.  So if one image is being
updated other pages can be reviewed as well to see if they should be 
updated at the same time.  Do we need both 
or should we change both images and update both pages? 
There is also a file with pages and keys to external use static items on a 
page.  Many are done systematically with
code and databases this picture, this text, and this format so the 
programmed changes also maintain much of the database 
updates.  The more pages added the more complex the maintenance without the 
help from the system as pages are 
added and deleted or updated.
This ensures that an image is not removed if removing a page and it is not 
the only user of the image.  This
helps prevent broken links or you can scan logs for 404 but then a user 
gets the message instead of prevention.


The signals are great for triggering events done through Django code and 
database actions.  But I don't think
it can detect that an image was substituted or deleted outside of its code 
base but OS commands or rouge programs.
It would be much harder to both change the file and update the hashcode.  
Using signals and a trusted db might 
give you the best of both worlds
On Tuesday, October 3, 2023 at 9:59:00 PM UTC-6 David Nugent wrote:

> The may not be enough context in your question but I imagine that the 
> following link may take you to something that may work for you.
>
> https://docs.djangoproject.com/en/4.2/topics/signals/
>
>
> On 4 October 2023 at 14:42:45, Ram (ram.mu...@gmail.com) wrote:
>
>> Hi,
>>
>> We would like to add this feature in our Web application and capture the 
>> following events in log files:
>>
>> 1. If any image is deleted by any reason
>> 2. Any content is deleted by any reason
>>
>> Does Django have any libraries or functions to achieve this?
>>
>> Best regards,
>> ~Ram
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to django-users...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/CA%2BOi5F3GDxbL_3C20ygwE9yumUdLxDgZJRdLEuM9Wdm%2BeTyfEA%40mail.gmail.com
>>  
>> 
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/3cf742a1-9ca8-4209-9c7a-b925ad368244n%40googlegroups.com.


Django security releases issued: 4.2.6, 4.1.12, and 3.2.22

2023-10-04 Thread Natalia Bidart
Details are available on the Django project weblog:

https://www.djangoproject.com/weblog/2023/oct/04/security-releases/

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2BfOnFY6jjAeC8ftfXuGbPuEYQzw0GeVAnL7iENbvu%2BPU6v-Vw%40mail.gmail.com.


Re: How to monitor content updates or deletion in Django web applications

2023-10-04 Thread David Nugent
Yes, certainly worth mentioning. ContentTypes is the secret sauce in django
admin for sure and extremely useful for building generic functionality
without hard coding to specific models. It’s like a through table in a
relational db, where entities can be tracked. And it’s all automatic, built
into every django app.


On 4 October 2023 at 18:44:13, Ruby (dev.rubysh...@gmail.com) wrote:

> Hi there,
> I don't know if there's a library for that, but I believe you can build
> what you need using the built-in Django Content-Type
> 
> I have used it a few times and Django admin site also uses it under the
> hood.
>
> On Wed, Oct 4, 2023 at 4:58 AM David Nugent  wrote:
>
>> The may not be enough context in your question but I imagine that the
>> following link may take you to something that may work for you.
>>
>> https://docs.djangoproject.com/en/4.2/topics/signals/
>>
>> On 4 October 2023 at 14:42:45, Ram (ram.mullap...@gmail.com) wrote:
>>
>>> Hi,
>>>
>>> We would like to add this feature in our Web application and capture the
>>> following events in log files:
>>>
>>> 1. If any image is deleted by any reason
>>> 2. Any content is deleted by any reason
>>>
>>> Does Django have any libraries or functions to achieve this?
>>>
>>> Best regards,
>>> ~Ram
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to django-users+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CA%2BOi5F3GDxbL_3C20ygwE9yumUdLxDgZJRdLEuM9Wdm%2BeTyfEA%40mail.gmail.com
>>> 
>>> .
>>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CAE5VhgUYV_r5yA%3DSn3Q1Cyie8mG71W6w6E1N%3D6wcBdVSoLvQOQ%40mail.gmail.com
>> 
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAPUD46vdk9bV%3DjC6OZa_DMx8feBwWcdUJ23WhjE9O-0LfZQeDw%40mail.gmail.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAE5VhgXigaf85f0UTDJY_tqLaZGOT4sxYu37O6_ZF0vSH68AeA%40mail.gmail.com.


Re: How to monitor content updates or deletion in Django web applications

2023-10-04 Thread Ruby
Hi there,
I don't know if there's a library for that, but I believe you can build
what you need using the built-in Django Content-Type

I have used it a few times and Django admin site also uses it under the
hood.

On Wed, Oct 4, 2023 at 4:58 AM David Nugent  wrote:

> The may not be enough context in your question but I imagine that the
> following link may take you to something that may work for you.
>
> https://docs.djangoproject.com/en/4.2/topics/signals/
>
> On 4 October 2023 at 14:42:45, Ram (ram.mullap...@gmail.com) wrote:
>
>> Hi,
>>
>> We would like to add this feature in our Web application and capture the
>> following events in log files:
>>
>> 1. If any image is deleted by any reason
>> 2. Any content is deleted by any reason
>>
>> Does Django have any libraries or functions to achieve this?
>>
>> Best regards,
>> ~Ram
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CA%2BOi5F3GDxbL_3C20ygwE9yumUdLxDgZJRdLEuM9Wdm%2BeTyfEA%40mail.gmail.com
>> 
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAE5VhgUYV_r5yA%3DSn3Q1Cyie8mG71W6w6E1N%3D6wcBdVSoLvQOQ%40mail.gmail.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAPUD46vdk9bV%3DjC6OZa_DMx8feBwWcdUJ23WhjE9O-0LfZQeDw%40mail.gmail.com.