Edit components list in trac - trac

How to add/edit components list in trac. Where's the 'trac.ini' file found?

If you have the appropriate admin permissions, you can use the Admin web interface to edit Components (URL .../admin/ticket/components).
trac.ini is in <projectenv>/conf/trac.ini.

The component list is not stored in the .ini, but in the database. Use the admin tab in the web interface (logged in as a user with TRAC_ADMIN or TICKET_ADMIN permissions) to manage your components. OR, you can use the trac-admin commandline utility to add and remove components.

Permissions to components are managed using the Trac Permissions (TICKET_VIEW, BROWSER_VIEW, etc ..).
However, components (and plug-ins) can be enabled and disabled via trac.ini. Take a look at the components section of the TracIni documentation.

Related

What directory should the frontend user login template be put into?

Since I want to keep the admin login separate from the user login on my Wagtail site, I'm trying to use the login page settings mentioned in this section of the documentation to direct people to a custom login page. I added the following settings to my base.py folder in the settings directory for my WT project under #Wagtail settings:
WAGTAIL_FRONTEND_LOGIN_URL = '/login/'
WAGTAIL_FRONTEND_LOGIN_TEMPLATE = 'base/login.html'
My project is structured similar to the bakerydemo, so there is a base app that manages a lot of the shared pieces of the site. I put my login.html in the templates directory for the base app. See link below for screenshot.
Screenshot of project directories
I am getting a 404 error whenever I try to navigate to the login URL I specified. Is there a setting I missed? Did I put the template in the wrong directory? Still getting used to how WT structures projects, so any pointers would be very much appreciated.
You should only set one of WAGTAIL_FRONTEND_LOGIN_URL and WAGTAIL_FRONTEND_LOGIN_TEMPLATE, not both.
WAGTAIL_FRONTEND_LOGIN_TEMPLATE is used if you want to use Wagtail's own login view (located at the URL /_util/login/), but want to customise its template. If you're going down this route, a path like 'base/login.html' is correct - Django will search within all template directories for a file matching this path.
WAGTAIL_FRONTEND_LOGIN_URL is used if you want to provide your own view code. To use this, you'll need to write the view function (most likely inheriting from Django's LoginView) and register it in the URL config, then point WAGTAIL_FRONTEND_LOGIN_URL at the resulting URL. In this case, your view function will be responsible for rendering an appropriate template, so WAGTAIL_FRONTEND_LOGIN_TEMPLATE will not come into play.

Anonymous access in Nextcloud

I use current stable version of Nextcloud (nextcloud docker image). I want to disable an authentication window when user enter the site. Is it possible? I found only anonymous upload feature in official doc.
Nextcloud is build around the concept that each user has it's personal (cloud) folder where he can upload, edit and share files. Therefore you cannot access the "normal" user interface without a log in.
However it is possible for any user to share files/folders via a link and allow editing of them without login:
https://docs.nextcloud.com/server/latest/user_manual/en/files/sharing.html#public-link-shares
https://docs.nextcloud.com/server/latest/admin_manual/configuration_files/file_sharing_configuration.html
But just in case you rally want to give all anonymous visitors of your Nextcloud instance the option to upload and edit files anonymously, here is a possible solution:
Create a folder anonymous with your admin account
Share it via link and allow editing
In your admin settings, go towards Theming: https://your-domain.com/settings/admin/theming
Set Anonymous Usage as Name and your shared link as Web link
Now if you log out and access your Nextcloud instance, you'll see a link at the very bottom called Anonymous Usage that you (and your clients) can follow to upload files/folders or edit existing ones. All files uploaded via that link will be stored inside the anonymous folder and will be owned by your admin account. So make sure to set the storage quota on that account high enough.
Be ware that
by visiting your Nextcloud instance anyone could delete all files inside anonymous as he doesn't need to authenticate himself.
the visitors are not fully anonymous, as there are probably some log files of Nextcloud and your Webserver with their IP addresses.

Use Liferay Authentification to restrict directory listing on Tomcat?

Is it possible to use Liferay Authentication in order to allow or deny access on a directory listing?
In my scenario Liferay is running under Tomcat. What I want is to restrict access on a specific directory and its content (lets say localhost:8080/pdf/). Currently each user is able to access the pdf-directory, which is not my intention.
May I use the current HTTP session?
-------- EDIT ---------
I will try to go more in detail: Under liferay tomcat I defined a new context as shown below.
<Context path="/pdfs" docBase="/Users/marco/Development/liferay/resources/pdfs/"
crossContext="false" debug="0" reloadable="true">
</Context>
The advantage of this is, I easly can access contents of "/pdfs". The disadvantage is, everybody can access "/pdfs".
The question is, how can I restrict access to "/pdfs"? My idea was to use Liferays authentication... but how? How can I restrict access to "/pdfs" to users currently logged into the Liferay application?
Thank you.
I think that the best option is to implement the restrictions in the standard servlet filter, because this functionality is Tomcat-standard feature.
What do you mean using HTTP session? I guess you want to use the Liferay permision-checker system to avoid listing directories, right?
Best regards,
Jorge
With setting the context you bypassed Liferay.
I would suggest another approach. Instead of defining docBase I would store dokument in Liferay Document Library. You have much better control over the content's permissions.
DLFileEntryServiceUtil.addFileEntry(...)

In IIS7, how can I require Authentication on specific directories?

I have a website on Win 2008 and IIS7. Some directories have admin specific pages and I don't want regular site users to be able to access them.
What I would like is, if the user tries to load a page from a specific directory, for the site to popup a windows authentication window if the user has not not already authenticated.
Can this be done? Preferably just by setting web.config keys?
Yes, use <location></location> tags to override the current IIS settings at that level and set new ones.
Reference: http://msdn.microsoft.com/en-us/library/b6x6shw7(v=vs.100).aspx

Joomla Authentication

Okay I'm a little confused on how to do this due to the fact that I'm new to Joomla.
I have a site where users need to be logged in to view certain articles. I want restricted articles to basically pick up weather or not the user is logged in, if so proceed as normal, else display a login/registration form.
I looked at the plugins section and found a "Joomla-Authentication" plugin. Now, how do I use that in an article in the same fashion I use other plugins in article? i.E {plugin_name}params{/plugin_name}
NO... You do not need plugin for this AT ALL.
In Joomla you have "Access Type" for modules/articles/pretty much everything.
Public - Visitors
Registered - logged in users
Special - back-end users
In Back-End go to Modules and create new Log-In module. In the access type selected "Public".
When you create articles select "Registered Access" this way only signed-in users will see the article.
This will help you. Log-In the admin Back-End (Administrator Screen), go to Help->Joomla Help. In the Alphabetical Index find following topics:
Module Manager (it explains access types)
Module - New
Article Manager (it explains access types)
Article Manager - New/Edit
I found a solution that works for me. I downloaded and installed JUMI. Jumi is a Joomla extension that allows you to include files such as php and then executes the code in those files. Through PHP I check user access and do redirects accordingly.
JUMI can be downloaded here