mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-17 22:14:26 +01:00
Allow browser to access LND config (#5128)
This commit is contained in:
@@ -29,6 +29,7 @@ using BTCPayServer.Storage.Services;
|
|||||||
using BTCPayServer.Storage.Services.Providers;
|
using BTCPayServer.Storage.Services.Providers;
|
||||||
using BTCPayServer.Validation;
|
using BTCPayServer.Validation;
|
||||||
using Microsoft.AspNetCore.Authorization;
|
using Microsoft.AspNetCore.Authorization;
|
||||||
|
using Microsoft.AspNetCore.Cors;
|
||||||
using Microsoft.AspNetCore.Identity;
|
using Microsoft.AspNetCore.Identity;
|
||||||
using Microsoft.AspNetCore.Mvc;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||||
@@ -664,6 +665,8 @@ namespace BTCPayServer.Controllers
|
|||||||
|
|
||||||
[Route("lnd-config/{configKey}/lnd.config")]
|
[Route("lnd-config/{configKey}/lnd.config")]
|
||||||
[AllowAnonymous]
|
[AllowAnonymous]
|
||||||
|
[EnableCors(CorsPolicies.All)]
|
||||||
|
[IgnoreAntiforgeryToken]
|
||||||
public IActionResult GetLNDConfig(ulong configKey)
|
public IActionResult GetLNDConfig(ulong configKey)
|
||||||
{
|
{
|
||||||
var conf = _LnConfigProvider.GetConfig(configKey);
|
var conf = _LnConfigProvider.GetConfig(configKey);
|
||||||
|
|||||||
Reference in New Issue
Block a user