Legacy Knowledge Base
公開されました Jun. 30, 2025

ゲスト表示権限でアップロードされたファイル - フォームアップロードフィールド

Written By

Tímea Bihari

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!

While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.

問題

  • フォームアップロードフィールドに文書が追加されると、「ゲスト表示」権限が付与されます。
  • ドキュメントがドキュメントとメディアライブラリに直接追加された場合、「ゲスト表示」権限はありません。
  • フォームからアップロードされたファイルの「ゲスト表示」権限を常に無効にする設定オプションはありますか?

環境

  • Liferay DXP 7.4
  • 四半期ごとのリリース

解像度



permissions.view.dynamic.inheritance=true

このプロパティが何をするかです:

# Set the following to true to automatically check the view permission on
# parent categories or folders when checking the permission on a specific
# item.
#
# For example, if set to true, to be able to have access to a document,
# a user must have the view permission on the document's folder and all its
# parent folders.

次のユースケースを考えてみよう:

  1. プロパティ:dl.show.hidden.mount.folders=trueを追加して、ドキュメントとメディア(後で必ず削除してください)
  2. アップロードフィールドを持つフォームを作成する
  3. 管理者として、フォームからファイルを送信する。
  4. Documents & Media > com.liferay.dynamic.data.mapping.form.web > Forms > test("test "はデフォルトの管理者ユーザーで、各ユーザーはフォームからアップロードされたファイル用の自分のフォルダを持ちます。)
  5. ファイルの情報を確認する > 最新バージョンのURL
  6. ゲストとしてURLを開く

結果

パーミッションを確認してください:このファイルは、Guest ユーザーの View アクセスが有効になっています。 親フォルダであるcom.liferay.dynamic.data.mapping.form.web、Forms 、test フォルダも同様です。

permissions.view.dynamic.inheritanceプロパティに基づき、File が Guest ビュー権限を持っていても、親フォルダのいずれかがビュー権限を持っていなければ、そのファイルはビュー権限を持っていないはずです。 com.liferay.dynamic.data.mapping.form.webフォルダからView権限を削除し、ゲストとして最新版のURLを再度呼び出してください。

結果:ゲストユーザーはファイルにアクセスできず、ログインプロンプトが表示されます。

Did this article resolve your issue ?

Legacy Knowledge Base